configure.ac 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936
  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.2],
  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=2
  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(DTCLIENTLIBS, '$(LIBPRINT) $(LIBHELP) $(LIBWIDGET) $(LIBSVC) \
  155. $(LIBTT) $(LIBXIN)')
  156. dnl set up come convenience replacements for global include dirs
  157. AC_SUBST(DT_INCDIR, '-I$(top_builddir)/include/Dt')
  158. AC_SUBST(DTI_INCDIR, '-I$(top_builddir)/include/DtI')
  159. AC_SUBST(TT_INCDIR, '-I$(top_builddir)/include/Tt')
  160. AC_SUBST(XM_INCDIR, '-I$(top_builddir)/include/Xm')
  161. AC_SUBST(CSA_INCDIR, '-I$(top_builddir)/include/csa')
  162. AC_SUBST(SPC_INCDIR, '-I$(top_builddir)/include/SPC')
  163. dnl language enables
  164. AC_ARG_ENABLE([german],
  165. AS_HELP_STRING([--enable-german], [Build German locale (default=no)]),
  166. [enable_de="yes"], [enable_de=""]
  167. )
  168. AM_CONDITIONAL([GERMAN], [test -n "$enable_de"])
  169. AC_ARG_ENABLE([italian],
  170. AS_HELP_STRING([--enable-italian], [Build Italian locale (default=no)]),
  171. [enable_it="yes"], [enable_it=""]
  172. )
  173. AM_CONDITIONAL([ITALIAN], [test -n "$enable_it"])
  174. AC_ARG_ENABLE([french],
  175. AS_HELP_STRING([--enable-french], [Build French locale (default=no)]),
  176. [enable_fr="yes"], [enable_fr=""]
  177. )
  178. AM_CONDITIONAL([FRENCH], [test -n "$enable_fr"])
  179. AC_ARG_ENABLE([spanish],
  180. AS_HELP_STRING([--enable-spanish], [Build Spanish locale (default=no)]),
  181. [enable_es="yes"], [enable_es=""]
  182. )
  183. AM_CONDITIONAL([SPANISH], [test -n "$enable_es"])
  184. AC_ARG_ENABLE([japanese],
  185. AS_HELP_STRING([--enable-japanese], [Build Japanese locale (default=no)]),
  186. [enable_ja="yes"], [enable_ja=""]
  187. )
  188. AM_CONDITIONAL([JAPANESE], [test -n "$enable_ja"])
  189. dnl interface font
  190. AC_ARG_ENABLE([misc-fixed],
  191. AS_HELP_STRING([--enable-misc-fixed], [Set interface font to misc-fixed (default=no)]),
  192. [enable_misc_fixed="yes"], [enable_misc_fixed=""]
  193. )
  194. AM_CONDITIONAL([MISC_FIXED], [test -n "$enable_misc_fixed"])
  195. dnl Build the help and dtinfo docs?
  196. AC_ARG_ENABLE([docs],
  197. AS_HELP_STRING([--disable-docs], [Disable building help/dtinfo docs (default=no)]),
  198. [disable_docs="yes"], [disable_docs=""]
  199. )
  200. AM_CONDITIONAL([BUILD_DOCS], [test -z "$disable_docs"])
  201. dnl Xrender usage
  202. AC_ARG_ENABLE([xrender],
  203. AS_HELP_STRING([--disable-xrender], [Disable use of the Xrender extension (default=auto)]),
  204. [disable_xrender="yes"], [disable_xrender=""]
  205. )
  206. dnl copied from xdm...
  207. AC_ARG_WITH(utmp_file,
  208. AS_HELP_STRING([--with-utmp-file=<pathname>],
  209. [specify file to pass to sessreg -u for current logins])
  210. AS_HELP_STRING([--without-utmp-file],
  211. [specify passing "none" to sessreg -u to not record logins in utmp]),
  212. [UTMP_FILE="$withval"])
  213. if test "x$UTMP_FILE" = "xyes" ; then
  214. UTMP_FILE=""
  215. elif test "x$UTMP_FILE" = "xno" ; then
  216. UTMP_FILE="none"
  217. fi
  218. AC_MSG_CHECKING([for path to file listing current logins for sessreg])
  219. if test "x$UTMP_FILE" = "x" ; then
  220. AC_MSG_RESULT([use sessreg default])
  221. else
  222. AC_MSG_RESULT([$UTMP_FILE])
  223. fi
  224. AM_CONDITIONAL(SET_UTMP_FILE, test x$UTMP_FILE != x)
  225. AC_SUBST(UTMP_FILE)
  226. AC_ARG_WITH(wtmp_file,
  227. AS_HELP_STRING([--with-wtmp-file=<pathname>],
  228. [specify file to pass to sessreg -w for login history])
  229. AS_HELP_STRING([--without-wtmp-file],
  230. [specify passing "none" to sessreg -w to not record logins in wtmp]),
  231. [WTMP_FILE="$withval"])
  232. if test "x$WTMP_FILE" = "xyes" ; then
  233. WTMP_FILE=""
  234. elif test "x$WTMP_FILE" = "xno" ; then
  235. WTMP_FILE="none"
  236. fi
  237. AC_MSG_CHECKING([for path to file listing login history for sessreg])
  238. if test "x$WTMP_FILE" = "x" ; then
  239. AC_MSG_RESULT([use sessreg default])
  240. else
  241. AC_MSG_RESULT([$WTMP_FILE])
  242. fi
  243. AM_CONDITIONAL(SET_WTMP_FILE, test x$WTMP_FILE != x)
  244. AC_SUBST(WTMP_FILE)
  245. dnl hmmm...
  246. RM="rm -f"
  247. AC_SUBST(RM)
  248. CP="cp -f"
  249. AC_SUBST(CP)
  250. dnl these should be configurable someday...
  251. CDE_INSTALLATION_TOP="$ac_default_prefix"
  252. CDE_LOGFILES_TOP=/var/dt
  253. CDE_CONFIGURATION_TOP=/etc/dt
  254. CDE_USER_TOP=.dt
  255. AC_SUBST(CDE_INSTALLATION_TOP)
  256. AC_SUBST(CDE_CONFIGURATION_TOP)
  257. AC_SUBST(CDE_LOGFILES_TOP)
  258. AC_SUBST(CDE_USER_TOP)
  259. dnl This variable will contain a list of programs that were not found,
  260. dnl but are required to build CDE. At the end, if the variable is
  261. dnl non-empty, an error message will be printed, listing the missing
  262. dnl programs. We don't bother with the simple expected commands like
  263. dnl ln, cp, etc...
  264. MISSING_PROGS=""
  265. AC_PROG_CPP
  266. dnl we need a real preprocessor, not gcc -E. We will call it GENCPP.
  267. dnl We will go with BSD's tradcpp here... This is used for
  268. dnl pre-processing during building of CDE - in the way imake used to
  269. dnl do. This is not a replacement for cpp, used at runtime by
  270. dnl software such as tt_type_comp.
  271. AC_SUBST(GENCPP, '$(top_builddir)/util/tradcpp/tradcpp')
  272. LT_INIT
  273. dnl make sure it's installed
  274. AC_PROG_YACC
  275. if test -z "$ac_cv_prog_YACC"; then
  276. MISSING_PROGS="[bison or byacc] ${MISSING_PROGS}"
  277. fi
  278. AC_PROG_LEX(noyywrap)
  279. if test -z "$ac_cv_prog_LEX"; then
  280. MISSING_PROGS="[flex or lex] ${MISSING_PROGS}"
  281. fi
  282. AC_PROG_INSTALL
  283. AC_PROG_LN_S
  284. AC_PROG_MAKE_SET
  285. AC_PROG_SED
  286. AC_PROG_AWK
  287. AC_PROG_GREP
  288. dnl AC_PROG_AR
  289. AC_PROG_RANLIB
  290. AC_C_CONST
  291. AC_C_BIGENDIAN
  292. AC_C_INLINE
  293. AC_C_CHAR_UNSIGNED
  294. AC_C_FLEXIBLE_ARRAY_MEMBER
  295. AC_SYS_POSIX_TERMIOS
  296. AX_PTHREAD
  297. AC_PATH_X
  298. AC_PATH_XTRA
  299. dnl check some compiler flags
  300. C_FLAG_CHECK([-Wno-format-truncation])
  301. CXX_FLAG_CHECK([-Wno-format-truncation])
  302. C_FLAG_CHECK([-fno-strict-aliasing])
  303. CXX_FLAG_CHECK([-fno-strict-aliasing])
  304. C_FLAG_CHECK([-Wno-write-strings])
  305. CXX_FLAG_CHECK([-Wno-write-strings])
  306. C_FLAG_CHECK([-Wno-unused-result])
  307. CXX_FLAG_CHECK([-Wno-unused-result])
  308. dnl Add X11 goodies here
  309. EXTRA_LIBS="${X_LIBS} ${EXTRA_LIBS}"
  310. EXTRA_INCS="${X_CFLAGS} ${EXTRA_INCS}"
  311. AC_FUNC_FORK
  312. dnl programs with full paths
  313. dnl - KSH, some systems call it as ksh93
  314. AC_PATH_PROG(KSH, ksh)
  315. if test -z "$ac_cv_path_KSH"; then
  316. AC_PATH_PROG(KSH, ksh93)
  317. if test -z "$ac_cv_path_KSH"; then
  318. MISSING_PROGS="[ksh or ksh93] ${MISSING_PROGS}"
  319. fi
  320. fi
  321. AC_PATH_PROG(XRDB, xrdb)
  322. if test -z "$ac_cv_path_XRDB"; then
  323. MISSING_PROGS="xrdb ${MISSING_PROGS}"
  324. fi
  325. AC_PATH_PROG(PERL, perl)
  326. if test -z "$ac_cv_path_PERL"; then
  327. MISSING_PROGS="perl ${MISSING_PROGS}"
  328. fi
  329. dnl we need to use cpp for some things, like tooltalk and other
  330. dnl runtime uses. So look for the system's cpp. NOTE: this is NOT
  331. dnl the CPP (gcc -E) set by AC_PROG_CPP. At this point I don't know
  332. dnl if we should even bother looking for that as we can't really use
  333. dnl it.
  334. AC_PATH_PROG(CPP_PROGRAM, cpp, ,
  335. [/lib:/usr/bin:/usr/ccs/lib/:/usr/lib:/usr/libexec:/opt/langtools/lbin:$PATH])
  336. if test -z "$ac_cv_path_CPP_PROGRAM"; then
  337. MISSING_PROGS="cpp ${MISSING_PROGS}"
  338. fi
  339. dnl major external program dependencies
  340. AC_CHECK_PROGS(BDFTOPCF, bdftopcf)
  341. if test -z "$ac_cv_prog_BDFTOPCF"; then
  342. MISSING_PROGS="bdftopcf ${MISSING_PROGS}"
  343. fi
  344. AC_CHECK_PROGS(MKFONTDIR, mkfontdir)
  345. if test -z "$ac_cv_prog_MKFONTDIR"; then
  346. MISSING_PROGS="mkfontdir ${MISSING_PROGS}"
  347. fi
  348. AC_CHECK_PROGS(GZIP, gzip)
  349. if test -z "$ac_cv_prog_GZIP"; then
  350. MISSING_PROGS="gzip ${MISSING_PROGS}"
  351. fi
  352. AC_CHECK_PROGS(M4, m4)
  353. if test -z "$ac_cv_prog_M4"; then
  354. MISSING_PROGS="m4 ${MISSING_PROGS}"
  355. fi
  356. AC_CHECK_PROGS(RPCGEN, rpcgen)
  357. if test -z "$ac_cv_prog_RPCGEN"; then
  358. MISSING_PROGS="rpcgen ${MISSING_PROGS}"
  359. fi
  360. AC_CHECK_PROGS(GENCAT, gencat)
  361. if test -z "$ac_cv_prog_GENCAT"; then
  362. MISSING_PROGS="gencat ${MISSING_PROGS}"
  363. fi
  364. AC_CHECK_PROGS(ONSGMLS, onsgmls)
  365. if test -z "$ac_cv_prog_ONSGMLS"; then
  366. MISSING_PROGS="ONSGMLS ${MISSING_PROGS}"
  367. fi
  368. AC_CHECK_PROGS(SESSREG, sessreg)
  369. if test -z "$ac_cv_prog_SESSREG"; then
  370. MISSING_PROGS="SESSREG ${MISSING_PROGS}"
  371. fi
  372. dnl Used to check if program 'tic' is available to install terminfo files
  373. AC_CHECK_PROGS(TIC, tic, :)
  374. dnl headers
  375. AC_CHECK_HEADERS([locale.h security/pam_appl.h utempter.h])
  376. dnl Xrender header
  377. AC_CHECK_HEADERS([X11/extensions/Xrender.h], [],
  378. [ disable_xrender="yes"], [#include <X11/Xlib.h>])
  379. dnl libraries
  380. AC_CHECK_LIB(m, cosf)
  381. AC_SEARCH_LIBS(dlopen, [dl dld], [], [])
  382. AC_CHECK_LIB(crypt, crypt)
  383. dnl this should be configurable, for now it is required
  384. AC_CHECK_LIB(Xinerama, XineramaQueryScreens,
  385. [SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DUSE_XINERAMA"],
  386. [AC_MSG_ERROR([libXinerama not found])], $X_LIBS)
  387. dnl Special check for tirpc...
  388. AC_CHECK_LIB(tirpc, svc_register,
  389. [CFLAGS="${CFLAGS} -DOPT_TIRPC -I/usr/include/tirpc";
  390. CXXFLAGS="${CXXFLAGS} -DOPT_TIRPC -I/usr/include/tirpc";
  391. TIRPCLIB=-ltirpc])
  392. AC_SUBST(TIRPCLIB)
  393. dnl see if the rpc_inline_t type exists
  394. AC_CHECK_TYPE(rpc_inline_t, [],
  395. [AC_DEFINE_UNQUOTED([rpc_inline_t], [int32_t],
  396. [Define to int32_t if not defined by including rpc/rpc.h])],
  397. [
  398. AC_INCLUDES_DEFAULT
  399. #include <rpc/rpc.h>
  400. ])
  401. dnl check sizeof time_t for RPC
  402. AC_CHECK_SIZEOF([int])
  403. AC_CHECK_SIZEOF([long])
  404. AC_CHECK_SIZEOF([long long])
  405. AC_CHECK_SIZEOF([time_t])
  406. AC_STRUCT_TIMEZONE
  407. AC_CHECK_DECLS([timezone],,,
  408. [#include <time.h>])
  409. AC_CHECK_MEMBERS([struct tm.tm_gmtoff],,,
  410. [#include <time.h>])
  411. dnl jpeg
  412. AC_CHECK_LIB(jpeg, jpeg_read_header, [JPEGLIB="-ljpeg"],
  413. [AC_MSG_ERROR([libjpeg not found, please install it])],
  414. [${EXTRA_INCS} ${EXTRA_LIBS}])
  415. AC_SUBST(JPEGLIB)
  416. dnl Setup XTOOLLIB - we do it in this specific order to avoid ordering
  417. dnl issues
  418. XTOOLLIB=""
  419. AC_CHECK_LIB(X11, XOpenDisplay, [XTOOLLIB="-lX11"], ,
  420. [${EXTRA_INCS} ${EXTRA_LIBS}])
  421. AC_CHECK_LIB(Xext, XextFindDisplay, [XTOOLLIB="-lXext ${XTOOLLIB}"], ,
  422. [${EXTRA_INCS} ${EXTRA_LIBS}])
  423. if test "x$disable_xrender" != "xyes" ; then
  424. AC_CHECK_LIB(Xrender, XRenderComposite,
  425. [XTOOLLIB="-lXrender ${XTOOLLIB}";
  426. SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DUSE_XRENDER"], ,
  427. [${EXTRA_INCS} ${EXTRA_LIBS}])
  428. fi
  429. AC_CHECK_LIB(Xau, XauReadAuth, [XTOOLLIB="-lXau ${XTOOLLIB}"], ,
  430. [${EXTRA_INCS} ${EXTRA_LIBS}])
  431. AC_CHECK_LIB(Xpm, XpmLibraryVersion, [XTOOLLIB="-lXpm ${XTOOLLIB}"], ,
  432. [${EXTRA_INCS} ${EXTRA_LIBS}])
  433. AC_CHECK_LIB(Xt, XtInitialize, [XTOOLLIB="-lXt ${XTOOLLIB}"], ,
  434. [${EXTRA_INCS} ${EXTRA_LIBS}])
  435. AC_CHECK_LIB(Xmu, XmuMakeAtom, [XTOOLLIB="-lXmu ${XTOOLLIB}"], ,
  436. [${EXTRA_INCS} ${EXTRA_LIBS}])
  437. AC_CHECK_LIB(ICE, IceCloseConnection, [XTOOLLIB="-lICE ${XTOOLLIB}"], ,
  438. [${EXTRA_INCS} ${EXTRA_LIBS}])
  439. AC_CHECK_LIB(SM, SmcOpenConnection, [XTOOLLIB="-lSM ${XTOOLLIB}"], ,
  440. [${EXTRA_INCS} ${EXTRA_LIBS}])
  441. AC_CHECK_LIB(Xm, XmTextSetString, [XTOOLLIB="-lXm ${XTOOLLIB}"], ,
  442. [${EXTRA_INCS} ${EXTRA_LIBS}])
  443. XTOOLLIB="${EXTRA_INCS} ${EXTRA_LIBS} ${X_EXTRA_LIBS} ${XTOOLLIB}"
  444. AC_SUBST([XTOOLLIB])
  445. dnl only needed by dtlogin
  446. AC_CHECK_LIB(Xdmcp, XdmcpFlush, [XDMCPLIB="-lXdmcp"], [XDMCPLIB=""],
  447. [${EXTRA_INCS} ${EXTRA_LIBS}])
  448. AC_SUBST(XDMCPLIB)
  449. dnl iconv
  450. AM_ICONV
  451. dnl figure out pam support
  452. dnl Right now this only works on linux and netbsd (9.2 tested)
  453. if test "$supports_pam" = "yes"
  454. then
  455. AC_CHECK_LIB(pam, pam_start,
  456. [SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DHAS_PAM_LIBRARY";
  457. PAMLIB="-lpam"])
  458. AC_SUBST(PAMLIB)
  459. else
  460. AC_CHECK_LIB(pam, NOTSUPPORTED)
  461. fi
  462. AM_CONDITIONAL([HAS_PAM_LIBRARY], [test "x$ac_cv_lib_pam_pam_start" = "xyes"])
  463. dnl figure out utempter support
  464. AC_CHECK_LIB(utempter, utempter_add_record,
  465. [SOURCE_CPP_DEFINES="${SOURCE_CPP_DEFINES} -DHAS_UTEMPTER_LIBRARY"])
  466. AM_CONDITIONAL([HAS_UTEMPTER_LIBRARY], [test "x$ac_cv_lib_utempter_utempter_add_record" = "xyes"])
  467. dnl Figure out TCL
  468. SC_PATH_TCLCONFIG
  469. SC_LOAD_TCLCONFIG
  470. dnl check MISSING_PROGS - error out here if there's stuff in it.
  471. if test -n "$MISSING_PROGS"; then
  472. AC_MSG_ERROR([Please install the following REQUIRED programs: ${MISSING_PROGS}])
  473. fi
  474. dnl set CPPFLAGS, CFLAGS, and CXXFLAGS.
  475. dnl The Autoconf manual says that these are user variables and
  476. dnl shouldn't be modified. It suggests that you create a special
  477. dnl variable and presumably add those to your Makefile.am files. We
  478. dnl have 192 of these currently, so... The user will just have to
  479. dnl deal, or modify them here directly.
  480. CPPFLAGS="${CPPFLAGS} ${SOURCE_CPP_DEFINES} ${CPP_COMPILER_FLAGS}"
  481. CFLAGS="${CFLAGS} ${C_COMPILER_FLAGS} ${EXTRA_INCS} ${PTHREAD_CFLAGS}"
  482. CXXFLAGS="${CXXFLAGS} ${CXX_COMPILER_FLAGS} ${EXTRA_INCS} ${PTHREAD_CFLAGS}"
  483. LIBS="${EXTRA_LIBS} ${LIBS} ${PTHREAD_LIBS}"
  484. dnl All of the makefiles we need to generate go here...
  485. AC_CONFIG_FILES([
  486. Makefile
  487. util/Makefile
  488. util/tradcpp/Makefile
  489. lib/Makefile
  490. lib/DtXinerama/Makefile
  491. lib/tt/Makefile
  492. lib/tt/mini_isam/Makefile
  493. lib/tt/slib/Makefile
  494. lib/tt/lib/Makefile
  495. lib/tt/lib/api/Makefile
  496. lib/tt/lib/api/dnd/Makefile
  497. lib/tt/lib/api/c/Makefile
  498. lib/tt/lib/tttk/Makefile
  499. lib/tt/lib/db/Makefile
  500. lib/tt/lib/mp/Makefile
  501. lib/tt/lib/util/Makefile
  502. lib/tt/bin/Makefile
  503. lib/tt/bin/shell/Makefile
  504. lib/tt/bin/ttauth/Makefile
  505. lib/tt/bin/scripts/Makefile
  506. lib/tt/bin/tttar/Makefile
  507. lib/tt/bin/tt_type_comp/Makefile
  508. lib/tt/bin/tttrace/Makefile
  509. lib/tt/bin/dbck/Makefile
  510. lib/tt/bin/ttdbserverd/Makefile
  511. lib/tt/bin/ttsession/Makefile
  512. lib/DtSvc/Makefile
  513. lib/DtSearch/Makefile
  514. lib/DtSearch/raima/Makefile
  515. lib/DtWidget/Makefile
  516. lib/DtHelp/Makefile
  517. lib/DtHelp/il/Makefile
  518. lib/DtPrint/Makefile
  519. lib/DtTerm/Term/Makefile
  520. lib/DtTerm/Makefile
  521. lib/DtTerm/TermView/Makefile
  522. lib/DtTerm/util/Makefile
  523. lib/DtTerm/TermPrim/Makefile
  524. lib/DtMrm/Makefile
  525. lib/csa/Makefile
  526. lib/DtMmdb/Makefile
  527. lib/DtMmdb/HardCopy/Makefile
  528. lib/DtMmdb/StyleSheet/Makefile
  529. lib/DtMmdb/api/Makefile
  530. lib/DtMmdb/btree/Makefile
  531. lib/DtMmdb/btree_berkeley/Makefile
  532. lib/DtMmdb/compression/Makefile
  533. lib/DtMmdb/diskhash/Makefile
  534. lib/DtMmdb/dstr/Makefile
  535. lib/DtMmdb/dti_cc/Makefile
  536. lib/DtMmdb/dti_excs/Makefile
  537. lib/DtMmdb/dynhash/Makefile
  538. lib/DtMmdb/hmphf/Makefile
  539. lib/DtMmdb/index/Makefile
  540. lib/DtMmdb/mgrs/Makefile
  541. lib/DtMmdb/misc/Makefile
  542. lib/DtMmdb/object/Makefile
  543. lib/DtMmdb/oliasdb/Makefile
  544. lib/DtMmdb/schema/Makefile
  545. lib/DtMmdb/storage/Makefile
  546. lib/DtMmdb/utility/Makefile
  547. programs/Makefile
  548. programs/backdrops/Makefile
  549. programs/palettes/Makefile
  550. programs/icons/Makefile
  551. programs/dsdm/Makefile
  552. programs/dthelp/Makefile
  553. programs/dthelp/dthelpview/Makefile
  554. programs/dthelp/dthelpgen/Makefile
  555. programs/dthelp/dthelpprint/Makefile
  556. programs/dthelp/parser/Makefile
  557. programs/dthelp/parser/pass1/Makefile
  558. programs/dthelp/parser/pass1/util/Makefile
  559. programs/dthelp/parser/pass1/build/Makefile
  560. programs/dthelp/parser/pass1/eltdef/Makefile
  561. programs/dthelp/parser/pass1/helptag/Makefile
  562. programs/dthelp/parser/pass1/parser/Makefile
  563. programs/dthelp/parser/canon1/Makefile
  564. programs/dthelp/parser/canon1/util/Makefile
  565. programs/dthelp/parser/canon1/build/Makefile
  566. programs/dthelp/parser/canon1/eltdef/Makefile
  567. programs/dthelp/parser/canon1/helptag/Makefile
  568. programs/dthelp/parser/canon1/parser/Makefile
  569. programs/dthelp/parser/pass2/Makefile
  570. programs/dthelp/parser/pass2/util/Makefile
  571. programs/dthelp/parser/pass2/build/Makefile
  572. programs/dthelp/parser/pass2/eltdef/Makefile
  573. programs/dthelp/parser/pass2/htag2/Makefile
  574. programs/dthelp/parser/pass2/parser/Makefile
  575. programs/dthelp/parser/helptag/Makefile
  576. programs/dtmail/Makefile
  577. programs/dtmail/dtmail/Makefile
  578. programs/dtmail/MotifApp/Makefile
  579. programs/dtmail/dtmailpr/Makefile
  580. programs/dtmail/libDtMail/Makefile
  581. programs/dtmail/libDtMail/RFC/Makefile
  582. programs/dtmail/libDtMail/Common/Makefile
  583. programs/dtpad/Makefile
  584. programs/dtfile/Makefile
  585. programs/dtfile/dtcopy/Makefile
  586. programs/dtwm/Makefile
  587. programs/dtlogin/Makefile
  588. programs/dtlogin/config/Makefile
  589. programs/dtsession/Makefile
  590. programs/dtsession/config/Makefile
  591. programs/dthello/Makefile
  592. programs/dtstyle/Makefile
  593. programs/dtexec/Makefile
  594. programs/dtdbcache/Makefile
  595. programs/dticon/Makefile
  596. programs/dtterm/Makefile
  597. programs/dtcalc/Makefile
  598. programs/dtaction/Makefile
  599. programs/dtspcd/Makefile
  600. programs/dtscreen/Makefile
  601. programs/dtksh/Makefile
  602. programs/dtksh/examples/Makefile
  603. programs/dtcm/Makefile
  604. programs/dtcm/libDtCmP/Makefile
  605. programs/dtcm/server/Makefile
  606. programs/dtcm/dtcm/Makefile
  607. programs/dtsearchpath/Makefile
  608. programs/dtsearchpath/libCliSrv/Makefile
  609. programs/dtsearchpath/dtsp/Makefile
  610. programs/dtsearchpath/dtappg/Makefile
  611. programs/dtappbuilder/Makefile
  612. programs/dtappbuilder/src/Makefile
  613. programs/dtappbuilder/src/libAButil/Makefile
  614. programs/dtappbuilder/src/libABobj/Makefile
  615. programs/dtappbuilder/src/libABobjXm/Makefile
  616. programs/dtappbuilder/src/libABil/Makefile
  617. programs/dtappbuilder/src/abmf/Makefile
  618. programs/dtappbuilder/src/ab/Makefile
  619. programs/dtappintegrate/Makefile
  620. programs/dtprintegrate/Makefile
  621. programs/dtconfig/Makefile
  622. programs/dtconfig/sun/Makefile
  623. programs/dtcreate/Makefile
  624. programs/dtprintinfo/Makefile
  625. programs/fontaliases/Makefile
  626. programs/dtdspmsg/Makefile
  627. programs/ttsnoop/Makefile
  628. programs/dtimsstart/Makefile
  629. programs/dtpdm/Makefile
  630. programs/dtsr/Makefile
  631. programs/dtpdmd/Makefile
  632. programs/dtinfo/Makefile
  633. programs/dtinfo/tools/Makefile
  634. programs/dtinfo/tools/misc/Makefile
  635. programs/dtinfo/clients/Makefile
  636. programs/dtinfo/clients/dtinfo_start/Makefile
  637. programs/dtinfo/dtinfo/Makefile
  638. programs/dtinfo/dtinfo/wwl/Makefile
  639. programs/dtinfo/dtinfo/wwl/src/Makefile
  640. programs/dtinfo/dtinfo/src/Makefile
  641. programs/dtinfo/dtinfo/src/Widgets/Makefile
  642. programs/dtinfo/dtinfo/src/Support/Makefile
  643. programs/dtinfo/dtinfo/src/UAS/Makefile
  644. programs/dtinfo/dtinfo/src/UAS/Base/Makefile
  645. programs/dtinfo/dtinfo/src/UAS/MMDB/Makefile
  646. programs/dtinfo/dtinfo/src/UAS/DtSR/Makefile
  647. programs/dtinfo/dtinfo/src/Basic/Makefile
  648. programs/dtinfo/dtinfo/src/OliasSearch/Makefile
  649. programs/dtinfo/dtinfo/src/Marks/Makefile
  650. programs/dtinfo/dtinfo/src/Graphics/Makefile
  651. programs/dtinfo/dtinfo/src/Preferences/Makefile
  652. programs/dtinfo/dtinfo/src/Managers/Makefile
  653. programs/dtinfo/dtinfo/src/Other/Makefile
  654. programs/dtinfo/dtinfo/src/Query/Makefile
  655. programs/dtinfo/dtinfo/src/Agents/Makefile
  656. programs/dtinfo/dtinfo/src/OnlineRender/Makefile
  657. programs/dtinfo/dtinfo/src/Messages/Makefile
  658. programs/dtinfo/dtinfo/src/cgm/Makefile
  659. programs/dtinfo/dtinfo/install/Makefile
  660. programs/dtinfo/dtinfo/install/lib/Makefile
  661. programs/dtinfo/dtinfo/install/lib/bitmaps/Makefile
  662. programs/types/Makefile
  663. programs/tttypes/Makefile
  664. programs/util/Makefile
  665. programs/util/dttypes/Makefile
  666. programs/dtopen/Makefile
  667. programs/dtdocbook/Makefile
  668. programs/dtdocbook/dtdocbook2man
  669. programs/dtdocbook/dtdocbook2sdl
  670. programs/dtdocbook/doc_utils/Makefile
  671. programs/dtdocbook/dtsr/Makefile
  672. programs/dtdocbook/infolib/Makefile
  673. programs/dtdocbook/instant/Makefile
  674. programs/dtdocbook/locales/Makefile
  675. programs/dtdocbook/locales/de_DE.UTF-8/Makefile
  676. programs/dtdocbook/locales/el_GR.UTF-8/Makefile
  677. programs/dtdocbook/locales/en_US.UTF-8/Makefile
  678. programs/dtdocbook/locales/es_ES.UTF-8/Makefile
  679. programs/dtdocbook/locales/fr_FR.UTF-8/Makefile
  680. programs/dtdocbook/locales/it_IT.UTF-8/Makefile
  681. programs/dtdocbook/locales/ja_JP.UTF-8/Makefile
  682. programs/dtdocbook/sgml/Makefile
  683. programs/dtdocbook/spec/Makefile
  684. programs/dtdocbook/tcl/Makefile
  685. programs/dtdocbook/tpt/Makefile
  686. programs/localized/Makefile
  687. programs/localized/util/Makefile
  688. programs/localized/C/Makefile
  689. programs/localized/C/app-defaults/Makefile
  690. programs/localized/C/config/Makefile
  691. programs/localized/C/backdrops/Makefile
  692. programs/localized/C/types/Makefile
  693. programs/localized/C/palettes/Makefile
  694. programs/localized/C/msg/Makefile
  695. programs/localized/C/appmanager/Makefile
  696. programs/localized/de_DE.UTF-8/Makefile
  697. programs/localized/de_DE.UTF-8/app-defaults/Makefile
  698. programs/localized/de_DE.UTF-8/config/Makefile
  699. programs/localized/de_DE.UTF-8/backdrops/Makefile
  700. programs/localized/de_DE.UTF-8/types/Makefile
  701. programs/localized/de_DE.UTF-8/palettes/Makefile
  702. programs/localized/de_DE.UTF-8/msg/Makefile
  703. programs/localized/de_DE.UTF-8/appmanager/Makefile
  704. programs/localized/fr_FR.UTF-8/Makefile
  705. programs/localized/fr_FR.UTF-8/app-defaults/Makefile
  706. programs/localized/fr_FR.UTF-8/config/Makefile
  707. programs/localized/fr_FR.UTF-8/backdrops/Makefile
  708. programs/localized/fr_FR.UTF-8/types/Makefile
  709. programs/localized/fr_FR.UTF-8/palettes/Makefile
  710. programs/localized/fr_FR.UTF-8/msg/Makefile
  711. programs/localized/fr_FR.UTF-8/appmanager/Makefile
  712. programs/localized/it_IT.UTF-8/Makefile
  713. programs/localized/it_IT.UTF-8/app-defaults/Makefile
  714. programs/localized/it_IT.UTF-8/config/Makefile
  715. programs/localized/it_IT.UTF-8/backdrops/Makefile
  716. programs/localized/it_IT.UTF-8/types/Makefile
  717. programs/localized/it_IT.UTF-8/palettes/Makefile
  718. programs/localized/it_IT.UTF-8/msg/Makefile
  719. programs/localized/it_IT.UTF-8/appmanager/Makefile
  720. programs/localized/es_ES.UTF-8/Makefile
  721. programs/localized/es_ES.UTF-8/app-defaults/Makefile
  722. programs/localized/es_ES.UTF-8/config/Makefile
  723. programs/localized/es_ES.UTF-8/backdrops/Makefile
  724. programs/localized/es_ES.UTF-8/types/Makefile
  725. programs/localized/es_ES.UTF-8/palettes/Makefile
  726. programs/localized/es_ES.UTF-8/msg/Makefile
  727. programs/localized/es_ES.UTF-8/appmanager/Makefile
  728. programs/localized/ja_JP.UTF-8/Makefile
  729. programs/localized/ja_JP.UTF-8/app-defaults/Makefile
  730. programs/localized/ja_JP.UTF-8/config/Makefile
  731. programs/localized/ja_JP.UTF-8/backdrops/Makefile
  732. programs/localized/ja_JP.UTF-8/types/Makefile
  733. programs/localized/ja_JP.UTF-8/palettes/Makefile
  734. programs/localized/ja_JP.UTF-8/msg/Makefile
  735. programs/localized/ja_JP.UTF-8/appmanager/Makefile
  736. doc/Makefile
  737. doc/en_US.UTF-8/Makefile
  738. doc/en_US.UTF-8/help/Makefile
  739. doc/en_US.UTF-8/help/common/Desktop.hf
  740. doc/en_US.UTF-8/help/common/DesktopIntro.hf
  741. doc/en_US.UTF-8/man/Makefile
  742. doc/en_US.UTF-8/guides/Makefile
  743. doc/en_US.UTF-8/m-guides/Makefile
  744. doc/de_DE.UTF-8/Makefile
  745. doc/de_DE.UTF-8/guides/Makefile
  746. doc/de_DE.UTF-8/help/Makefile
  747. doc/de_DE.UTF-8/help/common/Desktop.hf
  748. doc/de_DE.UTF-8/help/common/DesktopIntro.hf
  749. doc/es_ES.UTF-8/Makefile
  750. doc/es_ES.UTF-8/guides/Makefile
  751. doc/es_ES.UTF-8/help/Makefile
  752. doc/es_ES.UTF-8/help/common/Desktop.hf
  753. doc/es_ES.UTF-8/help/common/DesktopIntro.hf
  754. doc/fr_FR.UTF-8/Makefile
  755. doc/fr_FR.UTF-8/guides/Makefile
  756. doc/fr_FR.UTF-8/help/Makefile
  757. doc/fr_FR.UTF-8/help/common/Desktop.hf
  758. doc/fr_FR.UTF-8/help/common/DesktopIntro.hf
  759. doc/it_IT.UTF-8/Makefile
  760. doc/it_IT.UTF-8/guides/Makefile
  761. doc/it_IT.UTF-8/help/Makefile
  762. doc/it_IT.UTF-8/help/common/Desktop.hf
  763. doc/it_IT.UTF-8/help/common/DesktopIntro.hf
  764. doc/ja_JP.UTF-8/Makefile
  765. doc/ja_JP.UTF-8/guides/Makefile
  766. doc/ja_JP.UTF-8/help/Makefile
  767. doc/ja_JP.UTF-8/help/common/Desktop.hf
  768. doc/ja_JP.UTF-8/help/common/DesktopIntro.hf
  769. include/Makefile
  770. copyright
  771. doc/common/help/HELPEnt.sgm
  772. include/Dt/Dt.h
  773. lib/tt/bin/ttauth/ttauth.man
  774. ])
  775. AC_OUTPUT