Skip to content

Commit

Permalink
Merge pull request #1389 from hadfl/pkgupd
Browse files Browse the repository at this point in the history
package updates
  • Loading branch information
citrus-it authored Jan 12, 2024
2 parents a38c697 + 729eb08 commit 755326d
Show file tree
Hide file tree
Showing 14 changed files with 189 additions and 38 deletions.
4 changes: 2 additions & 2 deletions build/gh/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=gh
PKG=ooce/util/gh
VER=2.40.1
VER=2.41.0
SUMMARY="github-cli"
DESC="The GitHub CLI tool"

Expand Down
4 changes: 2 additions & 2 deletions build/go/build-120.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=go
PKG=ooce/developer/go-120
VER=1.20.12
VER=1.20.13
SUMMARY="The Go Programming Language"
DESC="An open source programming language that makes it easy to build simple, "
DESC+="reliable, and efficient software."
Expand Down
4 changes: 2 additions & 2 deletions build/go/build-121.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=go
PKG=ooce/developer/go-121
VER=1.21.5
VER=1.21.6
SUMMARY="The Go Programming Language"
DESC="An open source programming language that makes it easy to build simple, "
DESC+="reliable, and efficient software."
Expand Down
11 changes: 2 additions & 9 deletions build/htop/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,19 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=htop
PKG=ooce/system/htop
VER=3.2.2
VER=3.3.0
SUMMARY="htop"
DESC="An interactive process viewer for Unix"

set_arch 64
test_relver '>=' 151041 && set_clangver

# need stack_t, timestruc_t, label_t, ...
set_standard XPG6

# TODO: pending an illumos fix that defining _XOPEN_SOURCE_EXTENDED
# does not default to XPG4v2 even if a higher standard is set
CPPFLAGS+=" -D_XPG5"

XFORM_ARGS="-DPREFIX=${PREFIX#/}"

init
Expand Down
157 changes: 157 additions & 0 deletions build/htop/patches/illumos.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
PR created upstream:

https://github.com/htop-dev/htop/pull/1371

From 4b87af0663f83ed90f044f975e519409c92b8bd9 Mon Sep 17 00:00:00 2001
From: Dominik Hassler <[email protected]>
Date: Thu, 11 Jan 2024 17:44:34 +0000
Subject: [PATCH] fixes for illumos/Solaris platforms

---
solaris/Platform.c | 6 +++---
solaris/SolarisMachine.c | 6 +++++-
solaris/SolarisMachine.h | 1 +
solaris/SolarisProcess.c | 1 -
solaris/SolarisProcess.h | 1 +
solaris/SolarisProcessTable.c | 11 ++++++-----
6 files changed, 16 insertions(+), 10 deletions(-)

diff --git a/solaris/Platform.c b/solaris/Platform.c
index 5faa91ae7..3934f7896 100644
--- a/solaris/Platform.c
+++ b/solaris/Platform.c
@@ -220,7 +220,7 @@ double Platform_setCPUValues(Meter* this, unsigned int cpu) {

v[CPU_METER_NICE] = cpuData->nicePercent;
v[CPU_METER_NORMAL] = cpuData->userPercent;
- if (super->settings->detailedCPUTime) {
+ if (host->settings->detailedCPUTime) {
v[CPU_METER_KERNEL] = cpuData->systemPercent;
v[CPU_METER_IRQ] = cpuData->irqPercent;
this->curItems = 4;
@@ -258,13 +258,13 @@ void Platform_setSwapValues(Meter* this) {
}

void Platform_setZfsArcValues(Meter* this) {
- const SolarisMachine* shost = (SolarisMachine*) this->host;
+ const SolarisMachine* shost = (const SolarisMachine*) this->host;

ZfsArcMeter_readStats(this, &shost->zfs);
}

void Platform_setZfsCompressedArcValues(Meter* this) {
- const SolarisMachine* shost = (SolarisMachine*) this->host;
+ const SolarisMachine* shost = (const SolarisMachine*) this->host;

ZfsCompressedArcMeter_readStats(this, &shost->zfs);
}
diff --git a/solaris/SolarisMachine.c b/solaris/SolarisMachine.c
index 4f740d321..5b2bdcd46 100644
--- a/solaris/SolarisMachine.c
+++ b/solaris/SolarisMachine.c
@@ -57,7 +57,7 @@ static void SolarisMachine_updateCPUcount(SolarisMachine* this) {

if (s != super->activeCPUs) {
change = true;
- hsuper->activeCPUs = s;
+ super->activeCPUs = s;
}

if (change) {
@@ -310,6 +310,10 @@ Machine* Machine_new(UsersTable* usersTable, uid_t userId) {
CRT_fatalError("Cannot get pagesize by sysconf(_SC_PAGESIZE)");
this->pageSizeKB = this->pageSize / 1024;

+ this->kd = kstat_open();
+ if (!this->kd)
+ CRT_fatalError("Cannot open kstat handle");
+
SolarisMachine_updateCPUcount(this);

return super;
diff --git a/solaris/SolarisMachine.h b/solaris/SolarisMachine.h
index 2208a888e..b350e9196 100644
--- a/solaris/SolarisMachine.h
+++ b/solaris/SolarisMachine.h
@@ -19,6 +19,7 @@ in the source distribution for its full text.
#include <sys/uio.h>

#include "Hashtable.h"
+#include "Machine.h"
#include "UsersTable.h"

#include "zfs/ZfsArcStats.h"
diff --git a/solaris/SolarisProcess.c b/solaris/SolarisProcess.c
index 449861b25..56acc7e5a 100644
--- a/solaris/SolarisProcess.c
+++ b/solaris/SolarisProcess.c
@@ -15,7 +15,6 @@ in the source distribution for its full text.
#include <unistd.h>
#include <sys/syscall.h>

-#include "Process.h"
#include "ProcessTable.h"
#include "CRT.h"

diff --git a/solaris/SolarisProcess.h b/solaris/SolarisProcess.h
index 1a8d18c76..292a05f2d 100644
--- a/solaris/SolarisProcess.h
+++ b/solaris/SolarisProcess.h
@@ -20,6 +20,7 @@ in the source distribution for its full text.
#define ERR (-1)

#include "Machine.h"
+#include "Process.h"


typedef struct SolarisProcess_ {
diff --git a/solaris/SolarisProcessTable.c b/solaris/SolarisProcessTable.c
index 549c753cd..29c5d938f 100644
--- a/solaris/SolarisProcessTable.c
+++ b/solaris/SolarisProcessTable.c
@@ -24,6 +24,7 @@ in the source distribution for its full text.

#include "CRT.h"
#include "solaris/Platform.h"
+#include "solaris/SolarisMachine.h"
#include "solaris/SolarisProcess.h"


@@ -112,8 +113,8 @@ static int SolarisProcessTable_walkproc(psinfo_t* _psinfo, lwpsinfo_t* _lwpsinfo

// Setup process list
ProcessTable* pt = (ProcessTable*) listptr;
- SolarisProcessTable* spt = (SolarisProcessTable*) listptr;
- Machine* host = pt->host;
+ const Machine* host = pt->super.host;
+ const SolarisMachine* shost = (const SolarisMachine*) host;

id_t lwpid_real = _lwpsinfo->pr_lwpid;
if (lwpid_real > 1023) {
@@ -133,7 +134,7 @@ static int SolarisProcessTable_walkproc(psinfo_t* _psinfo, lwpsinfo_t* _lwpsinfo
const Settings* settings = host->settings;

// Common code pass 1
- proc->show = false;
+ proc->super.show = false;
sproc->taskid = _psinfo->pr_taskid;
sproc->projid = _psinfo->pr_projid;
sproc->poolid = _psinfo->pr_poolid;
@@ -171,7 +172,7 @@ static int SolarisProcessTable_walkproc(psinfo_t* _psinfo, lwpsinfo_t* _lwpsinfo
sproc->realpid = _psinfo->pr_pid;
sproc->lwpid = lwpid_real;
sproc->zoneid = _psinfo->pr_zoneid;
- sproc->zname = SolarisProcessTable_readZoneName(spt->kd, sproc);
+ sproc->zname = SolarisProcessTable_readZoneName(shost->kd, sproc);
SolarisProcessTable_updateExe(_psinfo->pr_pid, proc);

Process_updateComm(proc, _psinfo->pr_fname);
@@ -218,7 +219,7 @@ static int SolarisProcessTable_walkproc(psinfo_t* _psinfo, lwpsinfo_t* _lwpsinfo
pt->totalTasks += proc->nlwp + 1;
}
}
- proc->show = !(settings->hideKernelThreads && proc->isKernelThread);
+ proc->super.show = !(settings->hideKernelThreads && proc->isKernelThread);
} else { // We are not in the master LWP, so jump to the LWP handling code
proc->percent_cpu = ((uint16_t)_lwpsinfo->pr_pctcpu / (double)32768) * (double)100.0;
Process_updateCPUFieldWidths(proc->percent_cpu);
1 change: 1 addition & 0 deletions build/htop/patches/series
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
illumos.patch
4 changes: 2 additions & 2 deletions build/mattermost/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=mattermost
VER=8.1.7
VER=8.1.8
# check for the current morph version/commit hash and create a patched branch in
# https://github.com/omniosorg/morph; then point to that branch
MORPHBRANCH=il_1.0.5
Expand Down
2 changes: 1 addition & 1 deletion build/mbuffer/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
. ../../lib/build.sh

PROG=mbuffer
VER=20231216
VER=20240107
PKG=ooce/system/mbuffer
SUMMARY="$PROG - measuring buffer"
DESC="$PROG is a tool for buffering data streams"
Expand Down
4 changes: 2 additions & 2 deletions build/protobuf/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=protobuf
VER=25.1
VER=25.2
PKG=ooce/developer/protobuf
SUMMARY="protobuf"
DESC="Google's language-neutral, platform-neutral, extensible mechanism "
Expand Down
2 changes: 1 addition & 1 deletion build/rav1e/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
. ../../lib/build.sh

PROG=rav1e
VER=0.7.0
VER=0.7.1
PKG=ooce/multimedia/rav1e
SUMMARY="$PROG - AV1 encoder"
DESC="AV1 video encoder"
Expand Down
4 changes: 2 additions & 2 deletions build/rclone/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=rclone
PKG=ooce/network/rclone
VER=1.65.0
VER=1.65.1
SUMMARY="rsync for cloud storage"
DESC="A command line program to sync files and directories to and from "
DESC+="different cloud storage providers"
Expand Down
4 changes: 2 additions & 2 deletions build/ripgrep/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=ripgrep
VER=14.0.3
VER=14.1.0
PKG=ooce/text/ripgrep
SUMMARY="Fast line-oriented search tool"
DESC="A fast line-oriented search tool that recursively searches your current "
Expand Down
4 changes: 2 additions & 2 deletions build/u-boot/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
# http://www.illumos.org/license/CDDL.
# }}}

# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2024 OmniOS Community Edition (OmniOSce) Association.

. ../../lib/build.sh

PROG=u-boot
PKG=ooce/util/u-boot
VER=2023.10
VER=2024.01
SUMMARY="Das U-Boot"
DESC="$SUMMARY: Universal Bootloader"

Expand Down
Loading

0 comments on commit 755326d

Please sign in to comment.