summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2010-01-03 22:31:16 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2010-01-03 22:31:16 (GMT)
commit9fe9acb5db618af04b2a93617a9c4a16091d24be (patch)
treeb87b325170289cd785b7c9520098d983bb39d87c
parent1479982b699ffd35e7737b7a89fb08e043c0db5e (diff)
downloadtk-9fe9acb5db618af04b2a93617a9c4a16091d24be.zip
tk-9fe9acb5db618af04b2a93617a9c4a16091d24be.tar.gz
tk-9fe9acb5db618af04b2a93617a9c4a16091d24be.tar.bz2
[Tcl Bug 1636685]: Use the configuration for modern FreeBSD suggested by the
FreeBSD porter.
-rw-r--r--ChangeLog7
-rw-r--r--unix/tcl.m426
2 files changed, 31 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index b914406..14b3b18 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,11 @@
+2010-01-03 Donal K. Fellows <dkf@users.sf.net>
+
+ * unix/tcl.m4 (SC_CONFIG_CFLAGS): [Bug 1636685]: Use the configuration
+ for modern FreeBSD suggested by the FreeBSD porter.
+
2010-01-03 Pat Thoyts <patthoyts@users.sourceforge.net>
- * generic/tkMenu.h: [Patch 2848897] Support the system keyboard
+ * generic/tkMenu.h: [Patch 2848897]: Support the system keyboard
* win/tkWinMenu.c: cues option on Windows. This system parameter
hides the underlines on menu items unless the keyboard is used to
open the menu. (kovalenko, thoyts)
diff --git a/unix/tcl.m4 b/unix/tcl.m4
index 8bb395e..b799665 100644
--- a/unix/tcl.m4
+++ b/unix/tcl.m4
@@ -1552,7 +1552,7 @@ dnl AC_CHECK_TOOL(AR, ar)
UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
TCL_LIB_VERSIONS_OK=nodots
;;
- NetBSD-*|FreeBSD-*)
+ NetBSD-*|FreeBSD-[[3.4]].*)
# FreeBSD 3.* and greater have ELF.
# NetBSD 2.* has ELF and can use 'cc -shared' to build shared libs
SHLIB_CFLAGS="-fPIC"
@@ -1580,6 +1580,30 @@ dnl AC_CHECK_TOOL(AR, ar)
;;
esac
;;
+ FreeBSD-*)
+ # This configuration from FreeBSD Ports.
+ SHLIB_CFLAGS="-fPIC"
+ SHLIB_LD="${CC} -shared"
+ TCL_SHLIB_LD_EXTRAS="-soname \$[@]"
+ SHLIB_LD_LIBS='${LIBS}'
+ SHLIB_SUFFIX=".so"
+ DL_OBJS="tclLoadDl.o"
+ DL_LIBS=""
+ LDFLAGS=""
+ AS_IF([test $doRpath = yes], [
+ CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+ LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'])
+ AS_IF([test "${TCL_THREADS}" = "1"], [
+ # The -pthread needs to go in the LDFLAGS, not LIBS
+ LIBS=`echo $LIBS | sed s/-pthread//`
+ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+ LDFLAGS="$LDFLAGS $PTHREAD_LIBS"])
+ # Version numbers are dot-stripped by system policy.
+ TCL_TRIM_DOTS=`echo ${VERSION} | tr -d .`
+ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
+ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1'
+ TCL_LIB_VERSIONS_OK=nodots
+ ;;
Darwin-*)
CFLAGS_OPTIMIZE="-Os"
SHLIB_CFLAGS="-fno-common"