configure.ac 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895
  1. dnl When changing the version below, also change the CDE_VERSION_* macros
  2. dnl to match further below
  3. AC_INIT([Common Desktop Environment],
  4. [2.5.1],
  5. [https://sourceforge.net/projects/cdesktopenv],
  6. [cde],
  7. [https://sourceforge.net/projects/cdesktopenv])
  8. AC_CONFIG_HEADERS([include/cde_config.h])
  9. AC_CONFIG_MACRO_DIRS([m4])
  10. AM_INIT_AUTOMAKE([foreign subdir-objects no-define])
  11. dnl global CDE versioning
  12. CDE_VERSION_MAJOR=2
  13. CDE_VERSION_MINOR=5
  14. CDE_VERSION_MICRO=1
  15. dnl this is blank for a release, or contains an alpha character to indicate a
  16. dnl dev release.
  17. CDE_VERSION_DEV=
  18. AC_SUBST(CDE_VERSION_MAJOR)
  19. AC_SUBST(CDE_VERSION_MINOR)
  20. AC_SUBST(CDE_VERSION_MICRO)
  21. AC_SUBST(CDE_VERSION_DEV)
  22. dnl released in 2012, this should be sufficient
  23. AC_PREREQ([2.69])
  24. AC_CANONICAL_HOST
  25. AC_CANONICAL_BUILD
  26. dnl These must be up here for the compiler search list to actually work
  27. AC_PROG_CC([cc gcc clang])
  28. AC_PROG_CXX([c++ g++ clang++])
  29. LT_INIT
  30. AC_PREFIX_DEFAULT(/usr/dt)
  31. PKG_PROG_PKG_CONFIG
  32. dnl SOURCE_DEFINES - start with CDE project default
  33. SOURCE_CPP_DEFINES="-DANSICPP -DMULTIBYTE -DNLS16"
  34. dnl CPP_COMPILER_FLAGS - CPP/C/C++ compiler flags
  35. CPP_COMPILER_FLAGS=""
  36. dnl CXX_COMPILER_FLAGS - C++ compiler flags
  37. CXX_COMPILER_FLAGS=""
  38. dnl C_COMPILER_FLAGS - C compiler flags
  39. C_COMPILER_FLAGS=""
  40. dnl These OS version checks are deprecated and should be replaced with
  41. dnl feature checks where appropriate
  42. build_linux=no
  43. bsd=no
  44. build_freebsd=no
  45. build_openbsd=no
  46. build_netbsd=no
  47. build_solaris=no
  48. build_aix=no
  49. dnl locations of libs/includes if not in 'standard' places like on
  50. dnl linux (/usr/...). We build these up based on where X11 is, and
  51. dnl other things as we go along.
  52. EXTRA_LIBS=""
  53. EXTRA_INCS=""
  54. # pam currently only works on netbsd (9.2 tested) and linux
  55. supports_pam=no
  56. case "${build_os}" in
  57. linux*)
  58. build_linux=yes
  59. SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -D_POSIX_SOURCE \
  60. -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_SVID_SOURCE"
  61. supports_pam=yes
  62. ;;
  63. freebsd*)
  64. build_freebsd=yes
  65. bsd=yes
  66. # fbsd needs the iconv plug to avoid conflict with libiconv
  67. # and libc implementations. We prefer the libc impl.
  68. SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DLIBICONV_PLUG"
  69. ;;
  70. openbsd*)
  71. build_openbsd=yes
  72. bsd=yes
  73. ;;
  74. netbsd*)
  75. build_netbsd=yes
  76. bsd=yes
  77. supports_pam=yes
  78. ;;
  79. solaris*|sun*)
  80. build_solaris=yes
  81. ;;
  82. aix*)
  83. build_aix=yes
  84. ;;
  85. esac
  86. AM_CONDITIONAL([LINUX], [test "$build_linux" = "yes"])
  87. AM_CONDITIONAL([BSD], [test "$bsd" = "yes"])
  88. AM_CONDITIONAL([FREEBSD], [test "$build_freebsd" = "yes"])
  89. AM_CONDITIONAL([OPENBSD], [test "$build_openbsd" = "yes"])
  90. AM_CONDITIONAL([NETBSD], [test "$build_netbsd" = "yes"])
  91. AM_CONDITIONAL([SOLARIS], [test "$build_solaris" = "yes"])
  92. AM_CONDITIONAL([AIX], [test "$build_aix" = "yes"])
  93. dnl set CSRG_BASED define for the BSD's.
  94. if test "$bsd" = "yes"
  95. then
  96. SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DCSRG_BASED"
  97. fi
  98. is_x86_64=no
  99. is_i386=no
  100. is_sparc=no
  101. is_mips=no
  102. is_arm=no
  103. is_ppc=no
  104. is_riscv=no
  105. is_aarch64=no
  106. case "${host_cpu}" in
  107. i[3456]86*)
  108. is_i386=yes
  109. ;;
  110. x86_64* | amd64*)
  111. is_x86_64=yes
  112. ;;
  113. arm*)
  114. is_arm=yes
  115. ;;
  116. mips*)
  117. is_mips=yes
  118. ;;
  119. sparc*)
  120. is_sparc=yes
  121. ;;
  122. ppc* | powerpc*)
  123. is_ppc=yes
  124. ;;
  125. riscv*)
  126. is_riscv=yes
  127. ;;
  128. aarch64*)
  129. is_aarch64=yes
  130. ;;
  131. esac
  132. AM_CONDITIONAL([I386], [test "$is_i386" = yes])
  133. AM_CONDITIONAL([X86_64], [test "$is_x86_64" = yes])
  134. AM_CONDITIONAL([ARM], [test "$is_arm" = yes])
  135. AM_CONDITIONAL([SPARC], [test "$is_sparc" = yes])
  136. AM_CONDITIONAL([MIPS], [test "is_mips" = yes])
  137. AM_CONDITIONAL([PPC], [test "is_ppc" = yes])
  138. AM_CONDITIONAL([RISCV], [test "is_riscv" = yes])
  139. AM_CONDITIONAL([AARCH64], [test "is_aarch64" = yes])
  140. dnl our main libraries
  141. dnl we use single quotes so that $top_buildir is evaluated in the makefiles,
  142. dnl not here.
  143. AC_SUBST(LIBTT, '$(top_builddir)/lib/tt/lib/libtt.la')
  144. AC_SUBST(LIBXIN, '$(top_builddir)/lib/DtXinerama/libDtXinerama.la')
  145. AC_SUBST(LIBWIDGET, '$(top_builddir)/lib/DtWidget/libDtWidget.la')
  146. AC_SUBST(LIBTERM, '$(top_builddir)/lib/DtTerm/libDtTerm.la')
  147. AC_SUBST(LIBSVC, '$(top_builddir)/lib/DtSvc/libDtSvc.la')
  148. AC_SUBST(LIBSEARCH, '$(top_builddir)/lib/DtSearch/libDtSearch.la')
  149. AC_SUBST(LIBPRINT, '$(top_builddir)/lib/DtPrint/libDtPrint.la')
  150. AC_SUBST(LIBMRM, '$(top_builddir)/lib/DtMrm/libDtMrm.la')
  151. AC_SUBST(LIBMMDB, '$(top_builddir)/lib/DtMmdb/libDtMmdb.la')
  152. AC_SUBST(LIBHELP, '$(top_builddir)/lib/DtHelp/libDtHelp.la')
  153. AC_SUBST(LIBCSA, '$(top_builddir)/lib/csa/libcsa.la')
  154. AC_SUBST(LIBPAMSVC, '$(top_builddir)/lib/DtPamSvc/libDtPamSvc.la')
  155. dnl we do not inclue the DtPamSvc library here as it is not needed
  156. dnl for everything.
  157. AC_SUBST(DTCLIENTLIBS, '$(LIBPRINT) $(LIBHELP) $(LIBWIDGET) $(LIBSVC) \
  158. $(LIBTT) $(LIBXIN)')
  159. dnl set up come convenience replacements for global include dirs
  160. AC_SUBST(DT_INCDIR, '-I$(top_builddir)/include/Dt')
  161. AC_SUBST(DTI_INCDIR, '-I$(top_builddir)/include/DtI')
  162. AC_SUBST(TT_INCDIR, '-I$(top_builddir)/include/Tt')
  163. AC_SUBST(XM_INCDIR, '-I$(top_builddir)/include/Xm')
  164. AC_SUBST(CSA_INCDIR, '-I$(top_builddir)/include/csa')
  165. AC_SUBST(SPC_INCDIR, '-I$(top_builddir)/include/SPC')
  166. dnl language enables
  167. AC_ARG_ENABLE([german],
  168. AS_HELP_STRING([--enable-german], [Build German locale (default=no)]),
  169. [enable_de="yes"], [enable_de=""]
  170. )
  171. AM_CONDITIONAL([GERMAN], [test -n "$enable_de"])
  172. AC_ARG_ENABLE([italian],
  173. AS_HELP_STRING([--enable-italian], [Build Italian locale (default=no)]),
  174. [enable_it="yes"], [enable_it=""]
  175. )
  176. AM_CONDITIONAL([ITALIAN], [test -n "$enable_it"])
  177. AC_ARG_ENABLE([french],
  178. AS_HELP_STRING([--enable-french], [Build French locale (default=no)]),
  179. [enable_fr="yes"], [enable_fr=""]
  180. )
  181. AM_CONDITIONAL([FRENCH], [test -n "$enable_fr"])
  182. AC_ARG_ENABLE([spanish],
  183. AS_HELP_STRING([--enable-spanish], [Build Spanish locale (default=no)]),
  184. [enable_es="yes"], [enable_es=""]
  185. )
  186. AM_CONDITIONAL([SPANISH], [test -n "$enable_es"])
  187. AC_ARG_ENABLE([japanese],
  188. AS_HELP_STRING([--enable-japanese], [Build Japanese locale (default=no)]),
  189. [enable_ja="yes"], [enable_ja=""]
  190. )
  191. AM_CONDITIONAL([JAPANESE], [test -n "$enable_ja"])
  192. dnl interface font
  193. AC_ARG_ENABLE([misc-fixed],
  194. AS_HELP_STRING([--enable-misc-fixed], [Set interface font to misc-fixed (default=no)]),
  195. [enable_misc_fixed="yes"], [enable_misc_fixed=""]
  196. )
  197. AM_CONDITIONAL([MISC_FIXED], [test -n "$enable_misc_fixed"])
  198. dnl Build the help and dtinfo docs?
  199. AC_ARG_ENABLE([docs],
  200. AS_HELP_STRING([--disable-docs], [Disable building help/dtinfo docs (default=no)]),
  201. [disable_docs="yes"], [disable_docs=""]
  202. )
  203. AM_CONDITIONAL([BUILD_DOCS], [test -z "$disable_docs"])
  204. dnl Xrender usage
  205. AC_ARG_ENABLE([xrender],
  206. AS_HELP_STRING([--disable-xrender], [Disable use of the Xrender extension (default=auto)]),
  207. [disable_xrender="yes"], [disable_xrender=""]
  208. )
  209. dnl hmmm...
  210. RM="rm -f"
  211. AC_SUBST(RM)
  212. CP="cp -f"
  213. AC_SUBST(CP)
  214. dnl these should be configurable someday...
  215. CDE_INSTALLATION_TOP="$ac_default_prefix"
  216. CDE_LOGFILES_TOP=/var/dt
  217. CDE_CONFIGURATION_TOP=/etc/dt
  218. CDE_USER_TOP=.dt
  219. AC_SUBST(CDE_INSTALLATION_TOP)
  220. AC_SUBST(CDE_CONFIGURATION_TOP)
  221. AC_SUBST(CDE_LOGFILES_TOP)
  222. AC_SUBST(CDE_USER_TOP)
  223. dnl This variable will contain a list of programs that were not found,
  224. dnl but are required to build CDE. At the end, if the variable is
  225. dnl non-empty, an error message will be printed, listing the missing
  226. dnl programs. We don't bother with the simple expected commands like
  227. dnl ln, cp, etc...
  228. MISSING_PROGS=""
  229. AC_PROG_CPP
  230. dnl we need a real preprocessor, not gcc -E. We will call it GENCPP.
  231. dnl We will go with BSD's tradcpp here... This is used for
  232. dnl pre-processing during building of CDE - in the way imake used to
  233. dnl do. This is not a replacement for cpp, used at runtime by
  234. dnl software such as tt_type_comp.
  235. AC_SUBST(GENCPP, '$(top_builddir)/util/tradcpp/tradcpp')
  236. LT_INIT
  237. dnl make sure it's installed
  238. AC_PROG_YACC
  239. if test -z "$ac_cv_prog_YACC"; then
  240. MISSING_PROGS="[bison or byacc] ${MISSING_PROGS}"
  241. fi
  242. AC_PROG_LEX(noyywrap)
  243. if test -z "$ac_cv_prog_LEX"; then
  244. MISSING_PROGS="[flex or lex] ${MISSING_PROGS}"
  245. fi
  246. AC_PROG_INSTALL
  247. AC_PROG_LN_S
  248. AC_PROG_MAKE_SET
  249. AC_PROG_SED
  250. AC_PROG_AWK
  251. AC_PROG_GREP
  252. dnl AC_PROG_AR
  253. AC_PROG_RANLIB
  254. AC_C_CONST
  255. AC_C_BIGENDIAN
  256. AC_C_INLINE
  257. AC_C_CHAR_UNSIGNED
  258. AC_C_FLEXIBLE_ARRAY_MEMBER
  259. AC_SYS_POSIX_TERMIOS
  260. AX_PTHREAD
  261. AC_PATH_X
  262. AC_PATH_XTRA
  263. dnl check some compiler flags
  264. C_FLAG_CHECK([-Wno-format-truncation])
  265. CXX_FLAG_CHECK([-Wno-format-truncation])
  266. C_FLAG_CHECK([-fno-strict-aliasing])
  267. CXX_FLAG_CHECK([-fno-strict-aliasing])
  268. C_FLAG_CHECK([-Wno-write-strings])
  269. CXX_FLAG_CHECK([-Wno-write-strings])
  270. C_FLAG_CHECK([-Wno-unused-result])
  271. CXX_FLAG_CHECK([-Wno-unused-result])
  272. dnl Add X11 goodies here
  273. EXTRA_LIBS="${X_LIBS} ${EXTRA_LIBS}"
  274. EXTRA_INCS="${X_CFLAGS} ${EXTRA_INCS}"
  275. AC_FUNC_FORK
  276. dnl programs with full paths
  277. dnl - KSH, some systems call it as ksh93
  278. AC_PATH_PROG(KSH, ksh)
  279. if test -z "$ac_cv_path_KSH"; then
  280. AC_PATH_PROG(KSH, ksh93)
  281. if test -z "$ac_cv_path_KSH"; then
  282. MISSING_PROGS="[ksh or ksh93] ${MISSING_PROGS}"
  283. fi
  284. fi
  285. AC_PATH_PROG(XRDB, xrdb)
  286. if test -z "$ac_cv_path_XRDB"; then
  287. MISSING_PROGS="xrdb ${MISSING_PROGS}"
  288. fi
  289. AC_PATH_PROG(PERL, perl)
  290. if test -z "$ac_cv_path_PERL"; then
  291. MISSING_PROGS="perl ${MISSING_PROGS}"
  292. fi
  293. dnl we need to use cpp for some things, like tooltalk and other
  294. dnl runtime uses. So look for the system's cpp. NOTE: this is NOT
  295. dnl the CPP (gcc -E) set by AC_PROG_CPP. At this point I don't know
  296. dnl if we should even bother looking for that as we can't really use
  297. dnl it.
  298. AC_PATH_PROG(CPP_PROGRAM, cpp, ,
  299. [/lib:/usr/bin:/usr/ccs/lib/:/usr/lib:/usr/libexec:/opt/langtools/lbin:$PATH])
  300. if test -z "$ac_cv_path_CPP_PROGRAM"; then
  301. MISSING_PROGS="cpp ${MISSING_PROGS}"
  302. fi
  303. dnl major external program dependencies
  304. AC_CHECK_PROGS(BDFTOPCF, bdftopcf)
  305. if test -z "$ac_cv_prog_BDFTOPCF"; then
  306. MISSING_PROGS="bdftopcf ${MISSING_PROGS}"
  307. fi
  308. AC_CHECK_PROGS(MKFONTDIR, mkfontdir)
  309. if test -z "$ac_cv_prog_MKFONTDIR"; then
  310. MISSING_PROGS="mkfontdir ${MISSING_PROGS}"
  311. fi
  312. AC_CHECK_PROGS(GZIP, gzip)
  313. if test -z "$ac_cv_prog_GZIP"; then
  314. MISSING_PROGS="gzip ${MISSING_PROGS}"
  315. fi
  316. AC_CHECK_PROGS(M4, m4)
  317. if test -z "$ac_cv_prog_M4"; then
  318. MISSING_PROGS="m4 ${MISSING_PROGS}"
  319. fi
  320. AC_CHECK_PROGS(RPCGEN, rpcgen)
  321. if test -z "$ac_cv_prog_RPCGEN"; then
  322. MISSING_PROGS="rpcgen ${MISSING_PROGS}"
  323. fi
  324. AC_CHECK_PROGS(GENCAT, gencat)
  325. if test -z "$ac_cv_prog_GENCAT"; then
  326. MISSING_PROGS="gencat ${MISSING_PROGS}"
  327. fi
  328. AC_CHECK_PROGS(ONSGMLS, onsgmls)
  329. if test -z "$ac_cv_prog_ONSGMLS"; then
  330. MISSING_PROGS="ONSGMLS ${MISSING_PROGS}"
  331. fi
  332. dnl Used to check if program 'tic' is available to install terminfo files
  333. AC_CHECK_PROGS(TIC, tic, :)
  334. dnl headers
  335. AC_CHECK_HEADERS([locale.h security/pam_appl.h utempter.h])
  336. dnl Xrender header
  337. AC_CHECK_HEADERS([X11/extensions/Xrender.h], [],
  338. [ disable_xrender="yes"], [#include <X11/Xlib.h>])
  339. dnl libraries
  340. AC_CHECK_LIB(m, cosf)
  341. AC_SEARCH_LIBS(dlopen, [dl dld], [], [])
  342. AC_CHECK_LIB(crypt, crypt)
  343. dnl this should be configurable, for now it is required
  344. AC_CHECK_LIB(Xinerama, XineramaQueryScreens,
  345. [SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DUSE_XINERAMA"],
  346. [AC_MSG_ERROR([libXinerama not found])], $X_LIBS)
  347. dnl Special check for tirpc...
  348. AC_CHECK_LIB(tirpc, svc_register,
  349. [CFLAGS="${CFLAGS} -DOPT_TIRPC -I/usr/include/tirpc";
  350. CXXFLAGS="${CXXFLAGS} -DOPT_TIRPC -I/usr/include/tirpc";
  351. TIRPCLIB=-ltirpc])
  352. AC_SUBST(TIRPCLIB)
  353. dnl see if the rpc_inline_t type exists
  354. AC_CHECK_TYPE(rpc_inline_t, [],
  355. [AC_DEFINE_UNQUOTED([rpc_inline_t], [int32_t],
  356. [Define to int32_t if not defined by including rpc/rpc.h])],
  357. [
  358. AC_INCLUDES_DEFAULT
  359. #include <rpc/rpc.h>
  360. ])
  361. dnl check sizeof time_t for RPC
  362. AC_CHECK_SIZEOF([int])
  363. AC_CHECK_SIZEOF([long])
  364. AC_CHECK_SIZEOF([long long])
  365. AC_CHECK_SIZEOF([time_t])
  366. AC_STRUCT_TIMEZONE
  367. AC_CHECK_DECLS([timezone],,,
  368. [#include <time.h>])
  369. AC_CHECK_MEMBERS([struct tm.tm_gmtoff],,,
  370. [#include <time.h>])
  371. dnl jpeg
  372. AC_CHECK_LIB(jpeg, jpeg_read_header, [JPEGLIB="-ljpeg"],
  373. [AC_MSG_ERROR([libjpeg not found, please install it])],
  374. [${EXTRA_INCS} ${EXTRA_LIBS}])
  375. AC_SUBST(JPEGLIB)
  376. dnl Setup XTOOLLIB - we do it in this specific order to avoid ordering
  377. dnl issues
  378. XTOOLLIB=""
  379. AC_CHECK_LIB(X11, XOpenDisplay, [XTOOLLIB="-lX11"], ,
  380. [${EXTRA_INCS} ${EXTRA_LIBS}])
  381. AC_CHECK_LIB(Xext, XextFindDisplay, [XTOOLLIB="-lXext ${XTOOLLIB}"], ,
  382. [${EXTRA_INCS} ${EXTRA_LIBS}])
  383. if test "x$disable_xrender" != "xyes" ; then
  384. AC_CHECK_LIB(Xrender, XRenderComposite,
  385. [XTOOLLIB="-lXrender ${XTOOLLIB}";
  386. SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DUSE_XRENDER"], ,
  387. [${EXTRA_INCS} ${EXTRA_LIBS}])
  388. fi
  389. AC_CHECK_LIB(Xau, XauReadAuth, [XTOOLLIB="-lXau ${XTOOLLIB}"], ,
  390. [${EXTRA_INCS} ${EXTRA_LIBS}])
  391. AC_CHECK_LIB(Xpm, XpmLibraryVersion, [XTOOLLIB="-lXpm ${XTOOLLIB}"], ,
  392. [${EXTRA_INCS} ${EXTRA_LIBS}])
  393. AC_CHECK_LIB(Xt, XtInitialize, [XTOOLLIB="-lXt ${XTOOLLIB}"], ,
  394. [${EXTRA_INCS} ${EXTRA_LIBS}])
  395. AC_CHECK_LIB(Xmu, XmuMakeAtom, [XTOOLLIB="-lXmu ${XTOOLLIB}"], ,
  396. [${EXTRA_INCS} ${EXTRA_LIBS}])
  397. AC_CHECK_LIB(ICE, IceCloseConnection, [XTOOLLIB="-lICE ${XTOOLLIB}"], ,
  398. [${EXTRA_INCS} ${EXTRA_LIBS}])
  399. AC_CHECK_LIB(SM, SmcOpenConnection, [XTOOLLIB="-lSM ${XTOOLLIB}"], ,
  400. [${EXTRA_INCS} ${EXTRA_LIBS}])
  401. AC_CHECK_LIB(Xm, XmTextSetString, [XTOOLLIB="-lXm ${XTOOLLIB}"], ,
  402. [${EXTRA_INCS} ${EXTRA_LIBS}])
  403. XTOOLLIB="${EXTRA_INCS} ${EXTRA_LIBS} ${X_EXTRA_LIBS} ${XTOOLLIB}"
  404. AC_SUBST([XTOOLLIB])
  405. dnl only needed by dtlogin
  406. AC_CHECK_LIB(Xdmcp, XdmcpFlush, [XDMCPLIB="-lXdmcp"], [XDMCPLIB=""],
  407. [${EXTRA_INCS} ${EXTRA_LIBS}])
  408. AC_SUBST(XDMCPLIB)
  409. dnl iconv
  410. AM_ICONV
  411. dnl figure out pam support
  412. dnl Right now this only works on linux and netbsd (9.2 tested)
  413. if test "$supports_pam" = "yes"
  414. then
  415. AC_CHECK_LIB(pam, pam_start,
  416. [SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DHAS_PAM_LIBRARY"])
  417. else
  418. AC_CHECK_LIB(pam, NOTSUPPORTED)
  419. fi
  420. AM_CONDITIONAL([HAS_PAM_LIBRARY], [test "x$ac_cv_lib_pam_pam_start" = "xyes"])
  421. dnl figure out utempter support
  422. AC_CHECK_LIB(utempter, utempter_add_record,
  423. [SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DHAS_UTEMPTER_LIBRARY"])
  424. AM_CONDITIONAL([HAS_UTEMPTER_LIBRARY], [test "x$ac_cv_lib_utempter_utempter_add_record" = "xyes"])
  425. dnl Figure out TCL
  426. SC_PATH_TCLCONFIG
  427. SC_LOAD_TCLCONFIG
  428. dnl check MISSING_PROGS - error out here if there's stuff in it.
  429. if test -n "$MISSING_PROGS"; then
  430. AC_MSG_ERROR([Please install the following REQUIRED programs: ${MISSING_PROGS}])
  431. fi
  432. dnl set CPPFLAGS, CFLAGS, and CXXFLAGS.
  433. dnl The Autoconf manual says that these are user variables and
  434. dnl shouldn't be modified. It suggests that you create a special
  435. dnl variable and presumably add those to your Makefile.am files. We
  436. dnl have 192 of these currently, so... The user will just have to
  437. dnl deal, or modify them here directly.
  438. CPPFLAGS="${CPPFLAGS} ${SOURCE_CPP_DEFINES} ${CPP_COMPILER_FLAGS}"
  439. CFLAGS="${CFLAGS} ${C_COMPILER_FLAGS} ${EXTRA_INCS} ${PTHREAD_CFLAGS}"
  440. CXXFLAGS="${CXXFLAGS} ${CXX_COMPILER_FLAGS} ${EXTRA_INCS} ${PTHREAD_CFLAGS}"
  441. LIBS="${EXTRA_LIBS} ${LIBS} ${PTHREAD_LIBS}"
  442. dnl All of the makefiles we need to generate go here...
  443. AC_CONFIG_FILES([
  444. Makefile
  445. util/Makefile
  446. util/tradcpp/Makefile
  447. lib/Makefile
  448. lib/DtXinerama/Makefile
  449. lib/tt/Makefile
  450. lib/tt/mini_isam/Makefile
  451. lib/tt/slib/Makefile
  452. lib/tt/lib/Makefile
  453. lib/tt/lib/api/Makefile
  454. lib/tt/lib/api/dnd/Makefile
  455. lib/tt/lib/api/c/Makefile
  456. lib/tt/lib/tttk/Makefile
  457. lib/tt/lib/db/Makefile
  458. lib/tt/lib/mp/Makefile
  459. lib/tt/lib/util/Makefile
  460. lib/tt/bin/Makefile
  461. lib/tt/bin/shell/Makefile
  462. lib/tt/bin/ttauth/Makefile
  463. lib/tt/bin/scripts/Makefile
  464. lib/tt/bin/tttar/Makefile
  465. lib/tt/bin/tt_type_comp/Makefile
  466. lib/tt/bin/tttrace/Makefile
  467. lib/tt/bin/dbck/Makefile
  468. lib/tt/bin/ttdbserverd/Makefile
  469. lib/tt/bin/ttsession/Makefile
  470. lib/DtSvc/Makefile
  471. lib/DtPamSvc/Makefile
  472. lib/DtSearch/Makefile
  473. lib/DtSearch/raima/Makefile
  474. lib/DtWidget/Makefile
  475. lib/DtHelp/Makefile
  476. lib/DtHelp/il/Makefile
  477. lib/DtPrint/Makefile
  478. lib/DtTerm/Term/Makefile
  479. lib/DtTerm/Makefile
  480. lib/DtTerm/TermView/Makefile
  481. lib/DtTerm/util/Makefile
  482. lib/DtTerm/TermPrim/Makefile
  483. lib/DtMrm/Makefile
  484. lib/csa/Makefile
  485. lib/DtMmdb/Makefile
  486. lib/DtMmdb/HardCopy/Makefile
  487. lib/DtMmdb/StyleSheet/Makefile
  488. lib/DtMmdb/api/Makefile
  489. lib/DtMmdb/btree/Makefile
  490. lib/DtMmdb/btree_berkeley/Makefile
  491. lib/DtMmdb/compression/Makefile
  492. lib/DtMmdb/diskhash/Makefile
  493. lib/DtMmdb/dstr/Makefile
  494. lib/DtMmdb/dti_cc/Makefile
  495. lib/DtMmdb/dti_excs/Makefile
  496. lib/DtMmdb/dynhash/Makefile
  497. lib/DtMmdb/hmphf/Makefile
  498. lib/DtMmdb/index/Makefile
  499. lib/DtMmdb/mgrs/Makefile
  500. lib/DtMmdb/misc/Makefile
  501. lib/DtMmdb/object/Makefile
  502. lib/DtMmdb/oliasdb/Makefile
  503. lib/DtMmdb/schema/Makefile
  504. lib/DtMmdb/storage/Makefile
  505. lib/DtMmdb/utility/Makefile
  506. programs/Makefile
  507. programs/backdrops/Makefile
  508. programs/palettes/Makefile
  509. programs/icons/Makefile
  510. programs/dsdm/Makefile
  511. programs/dthelp/Makefile
  512. programs/dthelp/dthelpview/Makefile
  513. programs/dthelp/dthelpgen/Makefile
  514. programs/dthelp/dthelpprint/Makefile
  515. programs/dthelp/parser/Makefile
  516. programs/dthelp/parser/pass1/Makefile
  517. programs/dthelp/parser/pass1/util/Makefile
  518. programs/dthelp/parser/pass1/build/Makefile
  519. programs/dthelp/parser/pass1/eltdef/Makefile
  520. programs/dthelp/parser/pass1/helptag/Makefile
  521. programs/dthelp/parser/pass1/parser/Makefile
  522. programs/dthelp/parser/canon1/Makefile
  523. programs/dthelp/parser/canon1/util/Makefile
  524. programs/dthelp/parser/canon1/build/Makefile
  525. programs/dthelp/parser/canon1/eltdef/Makefile
  526. programs/dthelp/parser/canon1/helptag/Makefile
  527. programs/dthelp/parser/canon1/parser/Makefile
  528. programs/dthelp/parser/pass2/Makefile
  529. programs/dthelp/parser/pass2/util/Makefile
  530. programs/dthelp/parser/pass2/build/Makefile
  531. programs/dthelp/parser/pass2/eltdef/Makefile
  532. programs/dthelp/parser/pass2/htag2/Makefile
  533. programs/dthelp/parser/pass2/parser/Makefile
  534. programs/dthelp/parser/helptag/Makefile
  535. programs/dtmail/Makefile
  536. programs/dtmail/dtmail/Makefile
  537. programs/dtmail/MotifApp/Makefile
  538. programs/dtmail/dtmailpr/Makefile
  539. programs/dtmail/libDtMail/Makefile
  540. programs/dtmail/libDtMail/RFC/Makefile
  541. programs/dtmail/libDtMail/Common/Makefile
  542. programs/dtpad/Makefile
  543. programs/dtfile/Makefile
  544. programs/dtfile/dtcopy/Makefile
  545. programs/dtwm/Makefile
  546. programs/dtlogin/Makefile
  547. programs/dtlogin/config/Makefile
  548. programs/dtsession/Makefile
  549. programs/dtsession/config/Makefile
  550. programs/dthello/Makefile
  551. programs/dtstyle/Makefile
  552. programs/dtexec/Makefile
  553. programs/dtdbcache/Makefile
  554. programs/dticon/Makefile
  555. programs/dtterm/Makefile
  556. programs/dtcalc/Makefile
  557. programs/dtaction/Makefile
  558. programs/dtspcd/Makefile
  559. programs/dtscreen/Makefile
  560. programs/dtksh/Makefile
  561. programs/dtksh/examples/Makefile
  562. programs/dtcm/Makefile
  563. programs/dtcm/libDtCmP/Makefile
  564. programs/dtcm/server/Makefile
  565. programs/dtcm/dtcm/Makefile
  566. programs/dtsearchpath/Makefile
  567. programs/dtsearchpath/libCliSrv/Makefile
  568. programs/dtsearchpath/dtsp/Makefile
  569. programs/dtsearchpath/dtappg/Makefile
  570. programs/dtappbuilder/Makefile
  571. programs/dtappbuilder/src/Makefile
  572. programs/dtappbuilder/src/libAButil/Makefile
  573. programs/dtappbuilder/src/libABobj/Makefile
  574. programs/dtappbuilder/src/libABobjXm/Makefile
  575. programs/dtappbuilder/src/libABil/Makefile
  576. programs/dtappbuilder/src/abmf/Makefile
  577. programs/dtappbuilder/src/ab/Makefile
  578. programs/dtappintegrate/Makefile
  579. programs/dtprintegrate/Makefile
  580. programs/dtconfig/Makefile
  581. programs/dtconfig/sun/Makefile
  582. programs/dtcreate/Makefile
  583. programs/dtprintinfo/Makefile
  584. programs/fontaliases/Makefile
  585. programs/dtdspmsg/Makefile
  586. programs/ttsnoop/Makefile
  587. programs/dtimsstart/Makefile
  588. programs/dtpdm/Makefile
  589. programs/dtsr/Makefile
  590. programs/dtpdmd/Makefile
  591. programs/dtinfo/Makefile
  592. programs/dtinfo/tools/Makefile
  593. programs/dtinfo/tools/misc/Makefile
  594. programs/dtinfo/clients/Makefile
  595. programs/dtinfo/clients/dtinfo_start/Makefile
  596. programs/dtinfo/dtinfo/Makefile
  597. programs/dtinfo/dtinfo/wwl/Makefile
  598. programs/dtinfo/dtinfo/wwl/src/Makefile
  599. programs/dtinfo/dtinfo/src/Makefile
  600. programs/dtinfo/dtinfo/src/Widgets/Makefile
  601. programs/dtinfo/dtinfo/src/Support/Makefile
  602. programs/dtinfo/dtinfo/src/UAS/Makefile
  603. programs/dtinfo/dtinfo/src/UAS/Base/Makefile
  604. programs/dtinfo/dtinfo/src/UAS/MMDB/Makefile
  605. programs/dtinfo/dtinfo/src/UAS/DtSR/Makefile
  606. programs/dtinfo/dtinfo/src/Basic/Makefile
  607. programs/dtinfo/dtinfo/src/OliasSearch/Makefile
  608. programs/dtinfo/dtinfo/src/Marks/Makefile
  609. programs/dtinfo/dtinfo/src/Graphics/Makefile
  610. programs/dtinfo/dtinfo/src/Preferences/Makefile
  611. programs/dtinfo/dtinfo/src/Managers/Makefile
  612. programs/dtinfo/dtinfo/src/Other/Makefile
  613. programs/dtinfo/dtinfo/src/Query/Makefile
  614. programs/dtinfo/dtinfo/src/Agents/Makefile
  615. programs/dtinfo/dtinfo/src/OnlineRender/Makefile
  616. programs/dtinfo/dtinfo/src/Messages/Makefile
  617. programs/dtinfo/dtinfo/src/cgm/Makefile
  618. programs/dtinfo/dtinfo/install/Makefile
  619. programs/dtinfo/dtinfo/install/lib/Makefile
  620. programs/dtinfo/dtinfo/install/lib/bitmaps/Makefile
  621. programs/types/Makefile
  622. programs/tttypes/Makefile
  623. programs/util/Makefile
  624. programs/util/dttypes/Makefile
  625. programs/dtopen/Makefile
  626. programs/dtdocbook/Makefile
  627. programs/dtdocbook/dtdocbook2man
  628. programs/dtdocbook/dtdocbook2sdl
  629. programs/dtdocbook/doc_utils/Makefile
  630. programs/dtdocbook/dtsr/Makefile
  631. programs/dtdocbook/infolib/Makefile
  632. programs/dtdocbook/instant/Makefile
  633. programs/dtdocbook/locales/Makefile
  634. programs/dtdocbook/locales/de_DE.UTF-8/Makefile
  635. programs/dtdocbook/locales/el_GR.UTF-8/Makefile
  636. programs/dtdocbook/locales/en_US.UTF-8/Makefile
  637. programs/dtdocbook/locales/es_ES.UTF-8/Makefile
  638. programs/dtdocbook/locales/fr_FR.UTF-8/Makefile
  639. programs/dtdocbook/locales/it_IT.UTF-8/Makefile
  640. programs/dtdocbook/locales/ja_JP.UTF-8/Makefile
  641. programs/dtdocbook/sgml/Makefile
  642. programs/dtdocbook/spec/Makefile
  643. programs/dtdocbook/tcl/Makefile
  644. programs/dtdocbook/tpt/Makefile
  645. programs/localized/Makefile
  646. programs/localized/util/Makefile
  647. programs/localized/C/Makefile
  648. programs/localized/C/app-defaults/Makefile
  649. programs/localized/C/config/Makefile
  650. programs/localized/C/backdrops/Makefile
  651. programs/localized/C/types/Makefile
  652. programs/localized/C/palettes/Makefile
  653. programs/localized/C/msg/Makefile
  654. programs/localized/C/appmanager/Makefile
  655. programs/localized/de_DE.UTF-8/Makefile
  656. programs/localized/de_DE.UTF-8/app-defaults/Makefile
  657. programs/localized/de_DE.UTF-8/config/Makefile
  658. programs/localized/de_DE.UTF-8/backdrops/Makefile
  659. programs/localized/de_DE.UTF-8/types/Makefile
  660. programs/localized/de_DE.UTF-8/palettes/Makefile
  661. programs/localized/de_DE.UTF-8/msg/Makefile
  662. programs/localized/de_DE.UTF-8/appmanager/Makefile
  663. programs/localized/fr_FR.UTF-8/Makefile
  664. programs/localized/fr_FR.UTF-8/app-defaults/Makefile
  665. programs/localized/fr_FR.UTF-8/config/Makefile
  666. programs/localized/fr_FR.UTF-8/backdrops/Makefile
  667. programs/localized/fr_FR.UTF-8/types/Makefile
  668. programs/localized/fr_FR.UTF-8/palettes/Makefile
  669. programs/localized/fr_FR.UTF-8/msg/Makefile
  670. programs/localized/fr_FR.UTF-8/appmanager/Makefile
  671. programs/localized/it_IT.UTF-8/Makefile
  672. programs/localized/it_IT.UTF-8/app-defaults/Makefile
  673. programs/localized/it_IT.UTF-8/config/Makefile
  674. programs/localized/it_IT.UTF-8/backdrops/Makefile
  675. programs/localized/it_IT.UTF-8/types/Makefile
  676. programs/localized/it_IT.UTF-8/palettes/Makefile
  677. programs/localized/it_IT.UTF-8/msg/Makefile
  678. programs/localized/it_IT.UTF-8/appmanager/Makefile
  679. programs/localized/es_ES.UTF-8/Makefile
  680. programs/localized/es_ES.UTF-8/app-defaults/Makefile
  681. programs/localized/es_ES.UTF-8/config/Makefile
  682. programs/localized/es_ES.UTF-8/backdrops/Makefile
  683. programs/localized/es_ES.UTF-8/types/Makefile
  684. programs/localized/es_ES.UTF-8/palettes/Makefile
  685. programs/localized/es_ES.UTF-8/msg/Makefile
  686. programs/localized/es_ES.UTF-8/appmanager/Makefile
  687. programs/localized/ja_JP.UTF-8/Makefile
  688. programs/localized/ja_JP.UTF-8/app-defaults/Makefile
  689. programs/localized/ja_JP.UTF-8/config/Makefile
  690. programs/localized/ja_JP.UTF-8/backdrops/Makefile
  691. programs/localized/ja_JP.UTF-8/types/Makefile
  692. programs/localized/ja_JP.UTF-8/palettes/Makefile
  693. programs/localized/ja_JP.UTF-8/msg/Makefile
  694. programs/localized/ja_JP.UTF-8/appmanager/Makefile
  695. doc/Makefile
  696. doc/en_US.UTF-8/Makefile
  697. doc/en_US.UTF-8/help/Makefile
  698. doc/en_US.UTF-8/help/common/Desktop.hf
  699. doc/en_US.UTF-8/help/common/DesktopIntro.hf
  700. doc/en_US.UTF-8/man/Makefile
  701. doc/en_US.UTF-8/guides/Makefile
  702. doc/en_US.UTF-8/m-guides/Makefile
  703. doc/de_DE.UTF-8/Makefile
  704. doc/de_DE.UTF-8/guides/Makefile
  705. doc/de_DE.UTF-8/help/Makefile
  706. doc/de_DE.UTF-8/help/common/Desktop.hf
  707. doc/de_DE.UTF-8/help/common/DesktopIntro.hf
  708. doc/es_ES.UTF-8/Makefile
  709. doc/es_ES.UTF-8/guides/Makefile
  710. doc/es_ES.UTF-8/help/Makefile
  711. doc/es_ES.UTF-8/help/common/Desktop.hf
  712. doc/es_ES.UTF-8/help/common/DesktopIntro.hf
  713. doc/fr_FR.UTF-8/Makefile
  714. doc/fr_FR.UTF-8/guides/Makefile
  715. doc/fr_FR.UTF-8/help/Makefile
  716. doc/fr_FR.UTF-8/help/common/Desktop.hf
  717. doc/fr_FR.UTF-8/help/common/DesktopIntro.hf
  718. doc/it_IT.UTF-8/Makefile
  719. doc/it_IT.UTF-8/guides/Makefile
  720. doc/it_IT.UTF-8/help/Makefile
  721. doc/it_IT.UTF-8/help/common/Desktop.hf
  722. doc/it_IT.UTF-8/help/common/DesktopIntro.hf
  723. doc/ja_JP.UTF-8/Makefile
  724. doc/ja_JP.UTF-8/guides/Makefile
  725. doc/ja_JP.UTF-8/help/Makefile
  726. doc/ja_JP.UTF-8/help/common/Desktop.hf
  727. doc/ja_JP.UTF-8/help/common/DesktopIntro.hf
  728. include/Makefile
  729. copyright
  730. doc/common/help/HELPEnt.sgm
  731. include/Dt/Dt.h
  732. lib/tt/bin/ttauth/ttauth.man
  733. ])
  734. AC_OUTPUT