Diff

Differences From Artifact [bc43649110]:

To Artifact [e537bcd01c]:


90
91
92
93
94
95
96
97
98
99
100
101

102
103
104
105
106
107
108
109
110

111
112
113
114


115
116
117
118
119
















120
121
122
123
124
125
126
	AC_SUBST(CFLAGS)
	AC_SUBST(CPPFLAGS)
	AC_SUBST(LIBS)

	AC_MSG_RESULT([$tkconfigsh])
])

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

	SAVELIBS="${LIBS}"
	staticlibcxx=""

	dnl HP/UX uses -Wl,-a,archive -lstdc++ -Wl,-a,shared_archive
	dnl Linux and Solaris us -Wl,-Bstatic ... -Wl,-Bdynamic
	dnl
	dnl Sun Studio uses -lCstd -lCrun, most platforms use -lstdc++
	for trylink in "-Wl,-a,archive -lstdc++ -Wl,-a,shared_archive" "-Wl,-Bstatic -lCstd -lCrun -Wl,-Bdynamic" "-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic" "-lCstd -lCrun" "-lstdc++"; do
		LIBS="${SAVELIBS} ${trylink}"

		AC_LINK_IFELSE(AC_LANG_PROGRAM([], []), [
			staticlibcxx="${trylink}"


			break
		])
	done


	LIBS="${SAVELIBS} ${staticlibcxx}"

	AC_MSG_RESULT([${staticlibcxx}])

	AC_SUBST(LIBS)
















])

AC_DEFUN(DC_FIND_TCLKIT_LIBS, [
	DC_SETUP_TCL_PLAT_DEFS

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







|
|


|
>


<
<
|



|
>




>
>
|

|

|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







90
91
92
93
94
95
96
97
98
99
100
101
102
103
104


105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
	AC_SUBST(CFLAGS)
	AC_SUBST(CPPFLAGS)
	AC_SUBST(LIBS)

	AC_MSG_RESULT([$tkconfigsh])
])

AC_DEFUN(DC_DO_STATIC_LINK_LIB, [
	AC_MSG_CHECKING([for how to statically link to $1])

	SAVELIBS="${LIBS}"
	staticlib=""
	found="0"
	dnl HP/UX uses -Wl,-a,archive -lstdc++ -Wl,-a,shared_archive
	dnl Linux and Solaris us -Wl,-Bstatic ... -Wl,-Bdynamic


	for trylink in "-Wl,-a,archive $2 -Wl,-a,shared_archive" "-Wl,-Bstatic $2 -Wl,-Bdynamic" "$2"; do
		LIBS="${SAVELIBS} ${trylink}"

		AC_LINK_IFELSE(AC_LANG_PROGRAM([], []), [
			staticlib="${trylink}"
			found="1"

			break
		])
	done

	if test "${found}" = "1"; then
		LIBS="${SAVELIBS} ${staticlib}"

		AC_MSG_RESULT([${staticlib}])

		AC_SUBST(LIBS)

		$3
	else
		LIBS="${SAVELIBS}"

		AC_MSG_RESULT([cant])

		$4
	fi
])

AC_DEFUN(DC_DO_STATIC_LINK_LIBCXX, [
	dnl Sun Studio uses -lCstd -lCrun, most platforms use -lstdc++
	DC_DO_STATIC_LINK_LIB([C++ Library (Sun Studio)], [-lCstd -lCrun],, [
		DC_DO_STATIC_LINK_LIB([C++ Library (UNIX)], [-lstdc++])
	])
])

AC_DEFUN(DC_FIND_TCLKIT_LIBS, [
	DC_SETUP_TCL_PLAT_DEFS

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