Diff

Differences From Artifact [c2b5bbda30]:

To Artifact [abd6ccb011]:


39
40
41
42
43
44
45


46
47
48


49




50
51


52
53
54

55
56
57
58
59
60
61
62
63










64
65
66
67

	AC_MSG_RESULT([$tclconfigsh])
])

AC_DEFUN(DC_DO_STATIC_LINK_LIBCXX, [
	AC_MSG_CHECKING([for how to statically link to libstdc++])



	STATICLIBCXX="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic"
	LIBS="${LIBS} ${STATICLIBCXX}"



	AC_SUBST(LIBS)





	AC_MSG_RESULT([${STATICLIBCXX}])


])

AC_DEFUN(DC_FIND_TCLKIT_LIBS, [

	for proj in mk4tcl tcl tclvfs; do
		AC_MSG_CHECKING([for libraries required for ${proj}])

		libdir="../../../${proj}/inst"
		libfiles="`find "${libdir}" -name '*.a' | tr "\n" ' '`"

		ARCHS="${ARCHS} ${libfiles}"

		AC_MSG_RESULT([${libfiles}])










	done

	AC_SUBST(ARCHS)
])







>
>
|
|

>
>
|
>
>
>
>

|
>
>



>









>
>
>
>
>
>
>
>
>
>




39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88

	AC_MSG_RESULT([$tclconfigsh])
])

AC_DEFUN(DC_DO_STATIC_LINK_LIBCXX, [
	AC_MSG_CHECKING([for how to statically link to libstdc++])

	SAVELIBS="${LIBS}"
	staticlibcxx=""
	for trylink in "-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic" "-Wl,-Bstatic -lCstd -lCrun -Wl,-Bdynamic" "-lstdc++" "-lCstd -lCrun"; do
		LIBS="${SAVELIBS} ${trylink}"

		AC_LINK_IFELSE(, [
			staticlibcxx="${trylink}"

			break
		])
	done
	LIBS="${SAVELIBS} ${staticlibcxx}"

	AC_MSG_RESULT([${staticlibcxx}])

	AC_SUBST(LIBS)
])

AC_DEFUN(DC_FIND_TCLKIT_LIBS, [

	for proj in mk4tcl tcl tclvfs; do
		AC_MSG_CHECKING([for libraries required for ${proj}])

		libdir="../../../${proj}/inst"
		libfiles="`find "${libdir}" -name '*.a' | tr "\n" ' '`"

		ARCHS="${ARCHS} ${libfiles}"

		AC_MSG_RESULT([${libfiles}])

		if test "${libfiles}" != ""; then
			upperproj=`echo "${proj}" | dd conv=ucase 2>/dev/null`

			AC_DEFINE(KIT_INCLUDES_$upperproj)

			if test "${proj}" = "mk4tcl"; then
				DC_DO_STATIC_LINK_LIBCXX
			fi
		fi
	done

	AC_SUBST(ARCHS)
])