8a4fdf1240
hopefully in a cleaner way. Do the same for the tk sources for tk-tclX Both should now build. {tcl,tk}-tclX/Makefile have an awful lot in common so someone might like to split a lot of it out.
127 lines
5.1 KiB
Text
127 lines
5.1 KiB
Text
$NetBSD: patch-af,v 1.3 2001/04/27 09:16:19 skrll Exp $
|
|
|
|
--- ../tk/unix/Makefile.in.orig Mon Feb 7 00:54:01 2000
|
|
+++ ../tk/unix/Makefile.in
|
|
@@ -65,8 +65,8 @@
|
|
|
|
STANDALONE_OBJS = tkx.o
|
|
|
|
-LIBTCLX = ../../tcl/unix/${TCLX_STLIB_NAME}
|
|
-TCL = ../../tcl/unix/tcl
|
|
+LIBTCLX = ${PREFIX}/lib/${TCLX_STLIB_NAME}
|
|
+TCL = ${PREFIX}/bin/tcl
|
|
|
|
HELP_DIR = ${srcbasedir}/tk/help
|
|
|
|
@@ -92,29 +92,29 @@
|
|
standalone: wishx.standalone tktest.standalone hello
|
|
|
|
wishx: tkXAppInit.o @TKX_SHLIB_BUILD_REF@ @TKX_STLIB_BUILD_REF@ ${TCL} Makefile
|
|
- ${CC} ${LD_SWITCHES} tkXAppInit.o ${ALL_LIBS} \
|
|
- -o $@ || (rm -f $@; exit 1)
|
|
+ ${LD} tkXAppInit.o -o $@ -Wl,-R ${PREFIX}/lib -Wl,-R${X11BASE}/lib \
|
|
+ -L${PREFIX}/lib -L${X11BASE}/lib \
|
|
+ ${TKX_SHLIB_NAME:C/\.so.*/.la/} -ltclx82 -ltk83 -ltcl83 -lX11 -lm
|
|
|
|
wishx.static: tkXAppInit.o ${TKX_STLIB_NAME} ${LIBTCLX} Makefile
|
|
- ${CC} ${LD_SWITCHES} tkXAppInit.o ${STATIC_LIBS} -o $@ || \
|
|
+ ${LD} ${LD_SWITCHES} tkXAppInit.o ${STATIC_LIBS} -o $@ || \
|
|
(rm -f $@; exit 1)
|
|
|
|
wishx.standalone: tkXAppInitSA.o ${TKX_STLIB_NAME} ${LIBTCLX} Makefile
|
|
- ${CC} ${LD_SWITCHES} tkXAppInitSA.o ${STATIC_LIBS} -o $@ || \
|
|
+ ${LD} ${LD_SWITCHES} tkXAppInitSA.o ${STATIC_LIBS} -o $@ || \
|
|
(rm -f $@; exit 1)
|
|
|
|
${TKX_STLIB_NAME}: ${OBJS}
|
|
- ${AR} cr ${TKX_STLIB_NAME} ${OBJS}
|
|
- ${RANLIB} ${TKX_STLIB_NAME}
|
|
+# ${AR} cr ${TKX_STLIB_NAME} ${OBJS}
|
|
+# ${RANLIB} ${TKX_STLIB_NAME}
|
|
|
|
@TKX_SHLIB_BUILD_TARGET@: ${SOBJS}
|
|
- rm -f ${TKX_SHLIB_NAME}
|
|
- ${TCL_SHLIB_LD} -o ${TKX_SHLIB_NAME} ${SOBJS} \
|
|
- ${TK_BUILD_STUB_LIB_SPEC} ${TCLX_BUILD_LIB_SPEC} \
|
|
- ${TCL_BUILD_STUB_LIB_SPEC} ${TCL_SHLIB_LD_LIBS}
|
|
+ ${LIBTOOL} --mode=link @CC@ -o ${TKX_SHLIB_NAME:C/\.so.*/.la/} ${SOBJS:.o=.lo} \
|
|
+ -Wl,-R${PREFIX}/lib -Wl,-R${X11BASE}/lib -rpath ${PREFIX}/lib \
|
|
+ -L${PREFIX}/lib -L${X11BASE}/lib -ltclx82 -ltk83 -ltcl83 -lX11 -lm -version-info 1:0
|
|
|
|
hello: hello.c
|
|
- ${CC} ${LD_SWITCHES} -o $@ hello.c ${STATIC_LIBS}
|
|
+ ${LD} ${LD_SWITCHES} -o $@ hello.c ${STATIC_LIBS}
|
|
|
|
#------------------------------------------------------------------------------
|
|
# We need the "help" directory here so that the help command will work before
|
|
@@ -154,15 +154,16 @@
|
|
#
|
|
|
|
tktest: ${TEST_OBJS} @TKX_SHLIB_BUILD_REF@ @TKX_STLIB_BUILD_REF@ ${TCL}
|
|
- ${CC} ${LD_SWITCHES} ${TEST_OBJS} ${ALL_LIBS} \
|
|
- -o $@ || (rm -f $@; exit 1)
|
|
+ ${LD} ${TEST_OBJS} -o $@ -Wl,-R${PREFIX}/lib -Wl,-R${X11BASE}/lib \
|
|
+ -L${PREFIX}/lib -L${X11BASE}/lib \
|
|
+ ${TKX_SHLIB_NAME:C/\.so.*/.la/} -ltclx82 -ltk83 -ltcl83 -lX11 -lm
|
|
|
|
tktest.static: ${TEST_OBJS} @TKX_STLIB_BUILD_REF@ ${TCL}
|
|
- ${CC} ${LD_SWITCHES} ${TEST_OBJS} ${STATIC_LIBS} \
|
|
+ ${LD} ${LD_SWITCHES} ${TEST_OBJS} ${STATIC_LIBS} \
|
|
-o $@ || (rm -f $@; exit 1)
|
|
|
|
tktest.standalone: ${TEST_SAOBJS} @TKX_STLIB_BUILD_REF@ ${TCL}
|
|
- ${CC} ${LD_SWITCHES} ${TEST_SAOBJS} ${STATIC_LIBS} \
|
|
+ ${LD} ${LD_SWITCHES} ${TEST_SAOBJS} ${STATIC_LIBS} \
|
|
-o $@ || (rm -f $@; exit 1)
|
|
|
|
tkTest.o: ${TK_SRC_DIR}/generic/tkTest.c
|
|
@@ -199,7 +200,7 @@
|
|
buildhelp:
|
|
rm -rf ${HELP_DIR} help help.tmp
|
|
mkdir ${HELP_DIR}
|
|
- ${BLDMANHELP} ${TK_SRC_DIR}/doc ${TCLX_TOOLS_SRC_DIR}/tkmanpages \
|
|
+ ${PREFIX}/bin/tcl ../../unix/tools/bldmanhelp.tcl ${TK_SRC_DIR}/doc ${TCLX_TOOLS_SRC_DIR}/tkmanpages \
|
|
${HELP_DIR} Tk.brf
|
|
|
|
#------------------------------------------------------------------------------
|
|
@@ -212,27 +213,24 @@
|
|
|
|
install-doc:
|
|
|
|
-install-misc: buildhelp
|
|
- ${INSTCOPY} ${TKX_UNIX_SRC_DIR}/tkXAppInit.c \
|
|
+install-misc:
|
|
+ -${BSD_INSTALL_DATA_DIR} ${INSTALL_ROOT}${TKX_INST_RUNTIME}
|
|
+ ${BSD_INSTALL_DATA} ${TKX_UNIX_SRC_DIR}/tkXAppInit.c \
|
|
${INSTALL_ROOT}${TKX_INST_RUNTIME}
|
|
- ${INSTCOPY} ${HELP_DIR} ${INSTALL_ROOT}${TKX_INST_RUNTIME}/help
|
|
+ cd ${HELP_DIR} && ${GTAR} cf - . | (cd ${INSTALL_ROOT}${TCLX_INST_RUNTIME}/help && ${GTAR} xf -)
|
|
+ ${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${INSTALL_ROOT}${TCLX_INST_RUNTIME}/help
|
|
|
|
install-runtime:
|
|
- ${INSTCOPY} tkx.tcl ${INSTALL_ROOT}${TKX_INST_RUNTIME}
|
|
+ -${BSD_INSTALL_DATA_DIR} ${INSTALL_ROOT}${TKX_INST_RUNTIME}
|
|
+ ${BSD_INSTALL_DATA} tkx.tcl ${INSTALL_ROOT}${TKX_INST_RUNTIME}
|
|
|
|
install-exec:
|
|
- ${INSTCOPY} wishx ${INSTALL_ROOT}${TKX_INST_BIN}
|
|
- ${STRIP} ${INSTALL_ROOT}${TKX_INST_BIN}/wishx
|
|
- if test "X@TKX_STLIB_BUILD_REF@" != "X"; then \
|
|
- ${INSTCOPY} ${TKX_STLIB_NAME} ${INSTALL_ROOT}${TKX_INST_LIB}; \
|
|
- ${RANLIB} ${INSTALL_ROOT}${TKX_INST_LIB}/${TKX_STLIB_NAME}; \
|
|
- fi
|
|
- ${INSTCOPY} tkxConfig.sh ${INSTALL_ROOT}${TKX_INST_LIB}
|
|
- if test "@SHARED_BUILD@" = "1"; then \
|
|
- ${INSTCOPY} ${TKX_SHLIB_NAME} ${INSTALL_ROOT}${TKX_INST_LIB} ;\
|
|
- ${INSTCOPY} pkgIndex.tcl ${INSTALL_ROOT}${TKX_EXEC_RUNTIME} ;\
|
|
- fi
|
|
- ${INSTCOPY} tclhelp ${INSTALL_ROOT}${TKX_INST_BIN}
|
|
+ -${BSD_INSTALL_DATA_DIR} ${INSTALL_ROOT}${TKX_INST_RUNTIME}
|
|
+ ${LIBTOOL} --mode=install ${BSD_INSTALL_PROGRAM} wishx ${INSTALL_ROOT}${TKX_INST_BIN}
|
|
+ ${BSD_INSTALL_DATA} tkxConfig.sh ${INSTALL_ROOT}${TKX_INST_LIB}
|
|
+ ${LIBTOOL} --mode=install ${BSD_INSTALL_DATA} ${TKX_SHLIB_NAME:C/\.so.*/.la/} ${INSTALL_ROOT}${TKX_INST_LIB}
|
|
+ ${BSD_INSTALL_DATA} pkgIndex.tcl ${INSTALL_ROOT}${TKX_EXEC_RUNTIME}
|
|
+ ${BSD_INSTALL_SCRIPT} tclhelp ${INSTALL_ROOT}${TKX_INST_BIN}
|
|
|
|
#------------------------------------------------------------------------------
|
|
config:
|