Mercurial > minori
annotate configure.ac @ 249:6b2441c776dd
*: merge
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Wed, 24 Jan 2024 20:18:59 -0500 |
parents | 1ae4d8b28a5c 06d6c351925c |
children | c130f47f6f48 |
rev | line source |
---|---|
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
1 AC_INIT([minori], [0.1.0-alpha.1]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
2 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
3 AC_CANONICAL_HOST |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
4 |
237 | 5 AC_CONFIG_SUBDIRS([dep/pugixml dep/animia dep/anitomy]) |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
6 AC_CONFIG_SRCDIR([src/main.cc]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
7 AC_CONFIG_AUX_DIR([build-aux]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
8 AC_CONFIG_MACRO_DIRS([m4]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
9 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
10 AM_INIT_AUTOMAKE([-Wall -Wportability foreign subdir-objects]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
11 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
12 # Do we have a C++17 compiler |
237 | 13 : ${CXXFLAGS=""} |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
14 AC_PROG_CXX |
237 | 15 AX_CXX_COMPILE_STDCXX([17], [noext], [mandatory]) |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
16 |
237 | 17 # Init libtool |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
18 AM_PROG_AR |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
19 LT_INIT |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
20 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
21 # Qt? |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
22 AX_HAVE_QT |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
23 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
24 if test "x$have_qt" = "xno"; then |
241
06d6c351925c
*: reorganize resources, +docs, build translations with autotools
Paper <paper@paper.us.eu.org>
parents:
240
diff
changeset
|
25 AC_MSG_ERROR([*** Qt not found.]) |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
26 fi |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
27 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
28 # need this for moc |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
29 AC_PROG_MKDIR_P |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
30 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
31 # libcurl? |
237 | 32 LIBCURL_CHECK_CONFIG([yes], [7.7.2], [have_libcurl=yes], [have_libcurl=no]) |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
33 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
34 if test "x$have_libcurl" = "xno"; then |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
35 AC_MSG_ERROR([*** libcurl not found.]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
36 fi |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
37 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
38 build_windows=no |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
39 build_osx=no |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
40 build_glib=no |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
41 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
42 case "${host_os}" in |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
43 cygwin*|mingw*) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
44 # Windows |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
45 build_windows=yes |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
46 AC_CHECK_TOOL([WINDRES], [windres]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
47 AC_SUBST(WINDRES) |
247
1ae4d8b28a5c
autotools/windres: use AC_PROG_SED for sed
Paper <mrpapersonic@gmail.com>
parents:
236
diff
changeset
|
48 AC_PROG_SED # We need sed for version numbers in windres |
1ae4d8b28a5c
autotools/windres: use AC_PROG_SED for sed
Paper <mrpapersonic@gmail.com>
parents:
236
diff
changeset
|
49 AC_SUBST(SED) |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
50 AC_DEFINE(WIN32) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
51 ;; |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
52 darwin*) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
53 # Mac OS X |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
54 build_osx=yes |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
55 AC_DEFINE(MACOSX) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
56 ;; |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
57 *) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
58 if test "x$host_os" = "xlinux"; then |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
59 AC_DEFINE(LINUX) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
60 fi |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
61 # Everything else |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
62 AC_SUBST([GIO_CFLAGS]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
63 AC_SUBST([GIO_LIBS]) |
237 | 64 PKG_CHECK_MODULES([GIO], [gio-2.0], [build_glib=yes], []) |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
65 ;; |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
66 esac |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
67 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
68 AM_CONDITIONAL([BUILD_WIN], [test "x$build_windows" = "xyes"]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
69 AM_CONDITIONAL([BUILD_OSX], [test "x$build_osx" = "xyes"]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
70 AM_CONDITIONAL([BUILD_GLIB], [test "x$build_glib" = "xyes"]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
71 AM_CONDITIONAL([BUILD_WINDRES], [test "x$WINDRES" != "x"]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
72 |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
73 AC_CONFIG_FILES([Makefile]) |
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
74 AC_OUTPUT |