Skip to content

Commit

Permalink
tcl: update to 9.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
hadfl committed Jan 27, 2025
1 parent 8be04d9 commit 86f6887
Show file tree
Hide file tree
Showing 7 changed files with 74 additions and 30 deletions.
32 changes: 21 additions & 11 deletions build/tcl/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 2024 OmniOS Community Edition (OmniOSce) Association.
# Copyright 2025 OmniOS Community Edition (OmniOSce) Association.

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

PROG=tcl
VER=8.6.14
EXPECTVER=5.45.4
VER=9.0.1
EXPECTVER=5.45.4.1
PKG=ooce/runtime/tcl
SUMMARY="Tool Command Language"
DESC="A very powerful but easy to learn dynamic programming language"
Expand All @@ -28,16 +28,16 @@ MAJVER=${VER%.*}
OPREFIX=$PREFIX
PREFIX+=/$PROG

set_builddir $PROG$VER/unix
PATCHDIR+=-$PROG
set_builddir $PROG$VER
set_patchdir patches-$PROG

SKIP_LICENCES=BSD-style

# does not yet build with gcc 14
((GCCVER > 13)) && set_gccver 13

set_arch 64

# the build requires gnu find
PATH=$GNUBIN:$PATH

XFORM_ARGS="
-DPREFIX=${PREFIX#/}
-DOPREFIX=${OPREFIX#/}
Expand All @@ -53,6 +53,12 @@ CONFIGURE_OPTS[amd64]="
--enable-64bit
"

pre_build() {
append_builddir unix

unset -f pre_build
}

post_configure() {
pushd $TMPDIR/$BUILDDIR/../doc >/dev/null

Expand Down Expand Up @@ -91,8 +97,11 @@ DESC="A tool for automating interactive applications"
TCLDIR=$DESTDIR$PREFIX/lib
PREFIX="$OPREFIX/$PROG"

BUILDDIR=$PROG$VER
PATCHDIR=patches-$PROG
# does not yet build with gcc 14
((GCCVER > 13)) && set_gccver 13

set_builddir $PROG-$VER
set_patchdir patches-$PROG

SKIP_LICENCES=NIST

Expand All @@ -113,9 +122,10 @@ CONFIGURE_OPTS[amd64]="
"

init
download_source $PROG $PROG$VER
download_source $PROG $PROG $VER
patch_source
prep_build
run_autoconf -f
LD_LIBRARY_PATH=$TCLDIR build
make_package $PROG-local.mog
clean_up
Expand Down
5 changes: 5 additions & 0 deletions build/tcl/files/ctf.ignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,9 @@ exp_regexp.c
itclTestRegisterC.c
psGdbm.c
psLmdb.c
tclAlloc.c
tclEpollNotfy.c
tclKqueueNotfy.c
tclThreadJoin.c
threadNs.c
threadUnix.c
29 changes: 29 additions & 0 deletions build/tcl/patches-tcl/alloca.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
diff -wpruN --no-dereference '--exclude=*.orig' a~/pkgs/sqlite3.47.2/compat/sqlite3/sqlite3.c a/pkgs/sqlite3.47.2/compat/sqlite3/sqlite3.c
--- a~/pkgs/sqlite3.47.2/compat/sqlite3/sqlite3.c 1970-01-01 00:00:00
+++ a/pkgs/sqlite3.47.2/compat/sqlite3/sqlite3.c 1970-01-01 00:00:00
@@ -26,6 +26,11 @@
# define SQLITE_PRIVATE static
#endif
#define SQLITE_UDL_CAPABLE_PARSER 1
+
+#ifdef __illumos__
+#include <alloca.h>
+#endif
+
/************** Begin file sqliteInt.h ***************************************/
/*
** 2001 September 15
diff -wpruN --no-dereference '--exclude=*.orig' a~/pkgs/sqlite3.47.2/generic/tclsqlite3.c a/pkgs/sqlite3.47.2/generic/tclsqlite3.c
--- a~/pkgs/sqlite3.47.2/generic/tclsqlite3.c 1970-01-01 00:00:00
+++ a/pkgs/sqlite3.47.2/generic/tclsqlite3.c 1970-01-01 00:00:00
@@ -60,6 +60,10 @@
#include <errno.h>
#include "sqlite3Uuid.h"

+#ifdef __illumos__
+#include <alloca.h>
+#endif
+
/*
** Some additional include files are needed if this file is not
** appended to the amalgamation.
25 changes: 12 additions & 13 deletions build/tcl/patches-tcl/makefile.patch
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ man3 and mann).

This patch will not be sent upstream.

diff -wpruN --no-dereference '--exclude=*.orig' a~/Makefile.in a/Makefile.in
--- a~/Makefile.in 1970-01-01 00:00:00
+++ a/Makefile.in 1970-01-01 00:00:00
diff -wpruN --no-dereference '--exclude=*.orig' a~/unix/Makefile.in a/unix/Makefile.in
--- a~/unix/Makefile.in 1970-01-01 00:00:00
+++ a/unix/Makefile.in 1970-01-01 00:00:00
@@ -72,10 +72,10 @@ MAN_INSTALL_DIR = $(INSTALL_ROOT)$(mand
MAN1_INSTALL_DIR = $(MAN_INSTALL_DIR)/man1

Expand All @@ -19,16 +19,16 @@ diff -wpruN --no-dereference '--exclude=*.orig' a~/Makefile.in a/Makefile.in

# Path to the html documentation dir:
HTML_DIR = @HTML_DIR@
@@ -286,7 +286,7 @@ CC_SWITCHES = $(STUB_CC_SWITCHES) ${NO_D
@@ -285,7 +285,7 @@ CC_SWITCHES = $(STUB_CC_SWITCHES) -DBUIL

APP_CC_SWITCHES = $(CC_SWITCHES) @EXTRA_APP_CC_SWITCHES@
APP_CC_SWITCHES = $(STUB_CC_SWITCHES) @EXTRA_APP_CC_SWITCHES@

-LIBS = @TCL_LIBS@
+LIBS = @TCL_LIBS@ -lc

DEPEND_SWITCHES = ${CFLAGS} -I${UNIX_DIR} -I${GENERIC_DIR} \
${AC_FLAGS} ${EXTRA_CFLAGS} @EXTRA_CC_SWITCHES@
@@ -1028,7 +1028,7 @@ install-msgs:
@@ -1146,7 +1146,7 @@ install-msgs:
done

install-doc: doc
Expand All @@ -37,24 +37,23 @@ diff -wpruN --no-dereference '--exclude=*.orig' a~/Makefile.in a/Makefile.in
if [ ! -d "$$i" ] ; then \
echo "Making directory $$i"; \
$(INSTALL_DATA_DIR) "$$i"; \
@@ -1038,13 +1038,13 @@ install-doc: doc
@@ -1156,13 +1156,13 @@ install-doc: doc
@for i in $(TOP_DIR)/doc/*.1; do \
$(SHELL) $(UNIX_DIR)/installManPage $(MAN_FLAGS) $$i "$(MAN1_INSTALL_DIR)"; \
done
- @echo "Installing and cross-linking C API (.3) docs to $(MAN3_INSTALL_DIR)/"
- @for i in $(TOP_DIR)/doc/*.3; do \
- $(SHELL) $(UNIX_DIR)/installManPage $(MAN_FLAGS) $$i "$(MAN3_INSTALL_DIR)"; \
- done
- @echo "Installing and cross-linking command (.n) docs to $(MANN_INSTALL_DIR)/";
- @for i in $(TOP_DIR)/doc/*.n; do \
- $(SHELL) $(UNIX_DIR)/installManPage $(MAN_FLAGS) $$i "$(MANN_INSTALL_DIR)"; \
+ @echo "Installing and cross-linking C API (.3tcl) docs to $(MAN3TCL_INSTALL_DIR)/"
+ @for i in $(TOP_DIR)/doc/*.3tcl; do \
+ $(SHELL) $(UNIX_DIR)/installManPage $(MAN_FLAGS) $$i "$(MAN3TCL_INSTALL_DIR)"; \
+ done
done
- @echo "Installing and cross-linking command (.n) docs to $(MANN_INSTALL_DIR)/";
- @for i in $(TOP_DIR)/doc/*.n; do \
- $(SHELL) $(UNIX_DIR)/installManPage $(MAN_FLAGS) $$i "$(MANN_INSTALL_DIR)"; \
+ @echo "Installing and cross-linking command (.1t) docs to $(MAN1T_INSTALL_DIR)/";
+ @for i in $(TOP_DIR)/doc/*.1t; do \
+ $(SHELL) $(UNIX_DIR)/installManPage $(MAN_FLAGS) $$i "$(MAN1T_INSTALL_DIR)"; \
done

install-headers:
# Public headers that define Tcl's API
8 changes: 4 additions & 4 deletions build/tcl/patches-tcl/man.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
diff -wpruN --no-dereference '--exclude=*.orig' a~/installManPage a/installManPage
--- a~/installManPage 1970-01-01 00:00:00
+++ a/installManPage 1970-01-01 00:00:00
@@ -87,8 +87,8 @@ fi
diff -wpruN --no-dereference '--exclude=*.orig' a~/unix/installManPage a/unix/installManPage
--- a~/unix/installManPage 1970-01-01 00:00:00
+++ a/unix/installManPage 1970-01-01 00:00:00
@@ -102,8 +102,8 @@ fi

case $ManPage in
*.1) Section=1 ;;
Expand Down
1 change: 1 addition & 0 deletions build/tcl/patches-tcl/series
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
man.patch
makefile.patch
alloca.patch
4 changes: 2 additions & 2 deletions doc/packages.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@
| ooce/network/znc | 1.9.1 | https://znc.in/releases/ | [omniosorg](https://github.com/omniosorg)
| ooce/ooceapps | github-latest | https://github.com/omniosorg/ooceapps/releases | [omniosorg](https://github.com/omniosorg)
| ooce/print/cups | 2.4.11 | https://github.com/OpenPrinting/cups/releases | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/expect | 5.45.4 | https://sourceforge.net/projects/expect/files/Expect/ | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/expect | 5.45.4.1 | https://wiki.tcl-lang.org/page/Porting+extensions+to+Tcl+9 https://sourceforge.net/projects/expect/files/Expect/ | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/gnu-smalltalk | 3.2.5 | https://ftp.gnu.org/gnu/smalltalk/ | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/groovy-30 | 3.0.21 | https://groovy.apache.org/download.html | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/groovy-40 | 4.0.21 | https://groovy.apache.org/download.html | [omniosorg](https://github.com/omniosorg)
Expand All @@ -197,7 +197,7 @@
| ooce/runtime/ruby-32 | 3.2.6 | https://www.ruby-lang.org/en/downloads/ | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/ruby-33 | 3.3.7 | https://www.ruby-lang.org/en/downloads/ | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/ruby-34 | 3.4.1 | https://www.ruby-lang.org/en/downloads/ | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/tcl | 8.6.14 | https://sourceforge.net/projects/tcl/files/Tcl/ https://www.tcl.tk/software/tcltk/download.html | [omniosorg](https://github.com/omniosorg)
| ooce/runtime/tcl | 9.0.1 | https://sourceforge.net/projects/tcl/files/Tcl/ https://www.tcl.tk/software/tcltk/download.html | [omniosorg](https://github.com/omniosorg)
| ooce/security/gnupg | 2.4.7 | https://gnupg.org/download/ | [omniosorg](https://github.com/omniosorg)
| ooce/security/minisign | 0.12 | https://github.com/jedisct1/minisign/releases | [omniosorg](https://github.com/omniosorg)
| ooce/security/oath-toolkit | 2.6.12 | https://download.savannah.nongnu.org/releases/oath-toolkit/ | [omniosorg](https://github.com/omniosorg)
Expand Down

0 comments on commit 86f6887

Please sign in to comment.