Check-in [770ae24263]
Overview
Comment:Allow projects to override init functions and package names
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:770ae242632c8563caeb0d9ad75c8e79aec6cb86
User & Date: rkeene on 2018-06-10 06:15:22
Other Links: manifest | tags
Context
2018-06-10
06:15
Specify Tcl package name and init function, if specified check-in: 008f3ba007 user: rkeene tags: trunk
06:15
Allow projects to override init functions and package names check-in: 770ae24263 user: rkeene tags: trunk
06:14
Updated ignores for LMDB check-in: 41bafb40be user: rkeene tags: trunk
Changes

Modified kitsh/buildsrc/kitsh-0.0/aclocal.m4 from [44cc3a905e] to [859b63dc85].

   302    302   
   303    303   		if test -n "${subprojs}"; then
   304    304   			if test -n "${projlibfilesnostub}"; then
   305    305   				for subproj in $subprojs; do
   306    306   					subprojucase="`echo ${subproj} | dd conv=ucase 2>/dev/null`"
   307    307   					subprojtcase="`echo ${subprojucase} | cut -c 1``echo ${subproj} | cut -c 2-`"
   308    308   					lib_init_func="${subprojtcase}_Init"
          309  +					if test -f "${projdir}/inst/tcl-init-func"; then
          310  +						lib_init_func="`cat "${projdir}/inst/tcl-init-func"`"
          311  +					fi
   309    312   
   310    313   					echo "#define KIT_INCLUDES_${subprojucase}" >> kitInit-libs.h
   311    314   					echo "Tcl_AppInitProc ${lib_init_func};" >> kitInit-libs.h
   312    315   
   313    316   					libs_init_funcs="${libs_init_funcs} ${lib_init_func}"
   314    317   				done
   315    318   			fi
................................................................................
   319    322   		LIBS="${LIBS} ${projlibextra}"
   320    323   	done
   321    324   
   322    325   	echo '' >> kitInit-libs.h
   323    326   	echo 'static void _Tclkit_GenericLib_Init(void) {' >> kitInit-libs.h
   324    327   	for lib_init_func in ${libs_init_funcs}; do
   325    328   		proj="`echo ${lib_init_func} | sed 's@_Init$$@@@' | dd conv=lcase 2>/dev/null`"
          329  +		if test -f "${projdir}/inst/tcl-pkg-name"; then
          330  +			proj="`cat "${projdir}/inst/tcl-pkg-name"`"
          331  +		fi
   326    332   		echo "	Tcl_StaticPackage(0, \"${proj}\", ${lib_init_func}, NULL);" >> kitInit-libs.h
   327    333   	done
   328    334   	echo '	return;' >> kitInit-libs.h
   329    335   	echo '}' >> kitInit-libs.h
   330    336   
   331    337   	AC_SUBST(ARCHS)
   332    338   	AC_SUBST(STRIPLIBS)