Check-in [349896fca7]
Overview
Comment:Updated to be pluggable
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | pluggable
Files: files | file ages | folders
SHA1:349896fca7b1e43967fc2f69c6475a87f687063e
User & Date: rkeene on 2011-05-31 02:03:03
Other Links: manifest | tags
Context
2011-06-03
05:37
Merged in pluggable branch check-in: 78b96b6e9c user: rkeene tags: trunk
2011-05-31
02:03
Updated to be pluggable Closed-Leaf check-in: 349896fca7 user: rkeene tags: pluggable
2011-05-28
23:59
Merged trunk changes into branch check-in: ddf9f18c93 user: rkeene tags: pluggable
Changes

Modified kitsh/buildsrc/kitsh-0.0/Makefile.common.in from [537f4f602e] to [89e8fa6548].

    48     48   	rm -f $(OBJS) $(EXTRA_OBJS) $(EXTRA_VFS_OBJS)
    49     49   	rm -f cvfs_data_tcl.c cvfs_data_tcl.o
    50     50   	rm -f cvfs.tcl.h
    51     51   	rm -f tclsh.o tclsh tclsh.exe
    52     52   	rm -f wish.o wish wish.exe
    53     53   
    54     54   distclean: clean
           55  +	rm -f kitInit-libs.h
    55     56   	rm -f Makefile Makefile.in Makefile.common
    56     57   	rm -f config.status config.log
    57     58   	rm -f *~
    58     59   	rm -rf starpack.vfs
    59     60   	rm -rf autom4te.cache
    60     61   
    61     62   mrproper: distclean
    62     63   	rm -f configure config.h boot.tcl.h zipvfs.tcl.h
    63     64   
    64     65   .PHONY: all clean distclean mrproper

Modified kitsh/buildsrc/kitsh-0.0/aclocal.m4 from [370c9cd778] to [d398d3b4ba].

   155    155   ])
   156    156   
   157    157   AC_DEFUN(DC_FIND_TCLKIT_LIBS, [
   158    158   	DC_SETUP_TCL_PLAT_DEFS
   159    159   
   160    160   	dnl We will need this for the Tcl project, which we will always have
   161    161   	DC_CHECK_FOR_WHOLE_ARCHIVE
          162  +
          163  +	echo '/* Dynamically generated. */' > kitInit-libs.h
          164  +	libs_init_funcs=""
   162    165   
   163    166   	for projdir in ../../../*/; do
   164    167   		proj="`basename "${projdir}"`"
   165    168   
   166         -		if test "${proj}" = "zlib"; then
          169  +		if test "${proj}" = "build"; then
          170  +			continue
          171  +		fi
          172  +
          173  +		if test "${proj}" = "kitsh"; then
   167    174   			continue
   168    175   		fi
   169    176   
   170    177   		projlibdir="../../../${proj}/inst"
   171    178   
   172    179   		if test -d "${projlibdir}"; then
   173    180   			true
................................................................................
   179    186   
   180    187   		projlibfiles="`find "${projlibdir}" -name '*.a' 2>/dev/null | tr "\n" ' '`"
   181    188   		projlibfilesnostub="`find "${projlibdir}" -name '*.a' 2>/dev/null | grep -v 'stub' | tr "\n" ' '`"
   182    189   
   183    190   		AC_MSG_RESULT([${projlibfilesnostub}])
   184    191   
   185    192   		hide_symbols="1"
          193  +		initialize="1"
   186    194   
   187    195   		if test "${proj}" = "tcl"; then
   188    196   			DC_TEST_WHOLE_ARCHIVE_SHARED_LIB([$ARCHS $projlibfilesnostub], [
   189    197   				projlibfiles="${projlibfilesnostub}"
   190    198   			], [
   191    199   				DC_TEST_WHOLE_ARCHIVE_SHARED_LIB([$ARCHS $projlibfiles], [
   192    200   					projlibfiles="${projlibfiles}"
   193    201   				])
   194    202   			])
   195    203   
   196    204   			hide_symbols="0"
          205  +			initialize="0"
   197    206   		fi
   198    207   
   199    208   		if test "${proj}" = "mk4tcl"; then
   200    209   			if test -n "${projlibfiles}"; then
   201    210   				AC_DEFINE(KIT_INCLUDES_MK4TCL, [1], [Specify this if you link against mkt4tcl])
   202    211   
   203    212   				kc_cv_feature_kit_includes_mk4tcl='1'
   204    213   
   205    214   				DC_DO_STATIC_LINK_LIBCXX
   206    215   			fi
          216  +
          217  +			initialize="0"
   207    218   		fi
   208    219   
   209    220   		if test "${proj}" = "tk"; then
   210    221   			if test "${projlibfilesnostub}" != ""; then
   211    222   				DC_DO_TK
   212    223   				AC_DEFINE(KIT_INCLUDES_TK, [1], [Specify this if we link statically to Tk])
   213    224   				if test -n "${TK_VERSION}"; then
................................................................................
   225    236   					DC_TEST_WHOLE_ARCHIVE_SHARED_LIB([$ARCHS $projlibfiles], [
   226    237   						projlibfiles="${projlibfiles}"
   227    238   					])
   228    239   				])
   229    240   
   230    241   				hide_symbols="0"
   231    242   			fi
          243  +
          244  +			initialize="0"
          245  +		fi
          246  +
          247  +		if test "${proj}" = "thread"; then
          248  +			initialize="0"
          249  +		fi
          250  +
          251  +		if test "${proj}" = "tclvfs"; then
          252  +			initialize="0"
   232    253   		fi
   233    254   
   234    255   		if test "${hide_symbols}" = "1"; then
   235    256   			STRIPLIBS="${STRIPLIBS} ${projlibfiles}"
   236    257   		fi
   237    258   
   238    259   		dnl Do not explicitly link to Zlib, that will happen elsewhere
   239    260   		if test "${proj}" = "zlib"; then
   240    261   			continue
   241    262   		fi
          263  +
          264  +		if test "${initialize}" = "1"; then
          265  +			if test -n "${projlibfilesnostub}"; then
          266  +				projucase="`echo ${proj} | dd conv=ucase 2>/dev/null`"
          267  +				projtcase="`echo ${projucase} | cut -c 1``echo ${proj} | cut -c 2-`"
          268  +				lib_init_func="${projtcase}_Init"
          269  +
          270  +				echo "#define KIT_INCLUDES_${projucase}" >> kitInit-libs.h
          271  +				echo "Tcl_AppInitProc ${lib_init_func};" >> kitInit-libs.h
          272  +
          273  +				libs_init_funcs="${libs_init_funcs} ${lib_init_func}"
          274  +			fi
          275  +		fi
   242    276   
   243    277   		ARCHS="${ARCHS} ${projlibfiles}"
   244    278   	done
   245    279   
          280  +	echo '' >> kitInit-libs.h
          281  +	echo 'static void _Tclkit_GenericLib_Init(void) {' >> kitInit-libs.h
          282  +	for lib_init_func in ${libs_init_funcs}; do
          283  +		proj="`echo ${lib_init_func} | sed 's@_Init$$@@@' | dd conv=lcase 2>/dev/null`"
          284  +		echo "	Tcl_StaticPackage(0, \"${proj}\", ${lib_init_func}, NULL);" >> kitInit-libs.h
          285  +	done
          286  +	echo '	return;' >> kitInit-libs.h
          287  +	echo '}' >> kitInit-libs.h
          288  +
   246    289   	AC_SUBST(ARCHS)
   247    290   	AC_SUBST(STRIPLIBS)
   248    291   ])
   249    292   
   250    293   AC_DEFUN(DC_SETUP_TCL_PLAT_DEFS, [
   251    294   	AC_CANONICAL_BUILD
   252    295   	AC_CANONICAL_HOST

Modified kitsh/buildsrc/kitsh-0.0/kitInit.c from [50169ff8c3] to [0cfdc14cf7].

    57     57   #if 10 * TCL_MAJOR_VERSION + TCL_MINOR_VERSION < 85
    58     58   #  define KIT_INCLUDES_PWB 1
    59     59   #endif
    60     60   #if 10 * TCL_MAJOR_VERSION + TCL_MINOR_VERSION < 86
    61     61   #  define KIT_INCLUDES_ZLIB 1
    62     62   #endif
    63     63   
    64         -#ifdef KIT_INCLUDES_ITCL
    65         -Tcl_AppInitProc	Itcl_Init;
    66         -#endif
           64  +#include "kitInit-libs.h"
           65  +
    67     66   #ifdef KIT_INCLUDES_MK4TCL
    68     67   Tcl_AppInitProc	Mk4tcl_Init;
    69     68   #endif
    70     69   Tcl_AppInitProc Vfs_Init, Rechan_Init;
    71     70   #ifdef KIT_INCLUDES_PWB
    72     71   Tcl_AppInitProc	Pwb_Init;
    73     72   #endif
................................................................................
   337    336   		return;
   338    337   	}
   339    338   
   340    339   	return;
   341    340   }
   342    341   
   343    342   static void _Tclkit_Generic_Init(void) {
   344         -#ifdef KIT_INCLUDES_ITCL
   345         -	Tcl_StaticPackage(0, "Itcl", Itcl_Init, NULL);
   346         -#endif 
   347    343   #ifdef KIT_INCLUDES_MK4TCL
   348    344   	Tcl_StaticPackage(0, "Mk4tcl", Mk4tcl_Init, NULL);
   349    345   #endif
   350    346   #ifdef KIT_INCLUDES_PWB
   351    347   	Tcl_StaticPackage(0, "pwb", Pwb_Init, NULL);
   352    348   #endif 
   353    349   	Tcl_StaticPackage(0, "rechan", Rechan_Init, NULL);
................................................................................
   364    360   #ifdef _WIN32
   365    361   	Tcl_StaticPackage(0, "dde", Dde_Init, NULL);
   366    362   	Tcl_StaticPackage(0, "registry", Registry_Init, NULL);
   367    363   #endif
   368    364   #ifdef KIT_INCLUDES_TK
   369    365   	Tcl_StaticPackage(0, "Tk", Tk_Init, Tk_SafeInit);
   370    366   #endif
          367  +
          368  +	_Tclkit_GenericLib_Init();
   371    369   
   372    370   	TclSetPreInitScript(preInitCmd);
   373    371   
   374    372   	return;
   375    373   }
   376    374   
   377    375   static void _Tclkit_Interp_Init(Tcl_Interp *interp) {