source: xplra/configure.ac@ 0:01765e0d3719

Last change on this file since 0:01765e0d3719 was 0:01765e0d3719, checked in by István Váradi <ivaradi@…>, 11 years ago

Very basic plugin works

File size: 1.6 KB
Line 
1AC_INIT(xplra, 0.1, ivaradi@gmail.com)
2AM_INIT_AUTOMAKE([foreign])
3
4LT_INIT
5
6AM_PROG_AS
7AC_PROG_CC
8AC_PROG_CXX
9
10PKG_PROG_PKG_CONFIG
11
12AC_CHECK_HEADERS([windows.h winsock2.h])
13
14test "$ac_cv_header_windows_h" = "yes" -a "$ac_cv_header_winsock2_h" = "yes"
15_target_win32=$?
16
17AM_CONDITIONAL([TARGET_API_WIN32], test $_target_win32 -eq 0)
18AM_CONDITIONAL([TARGET_API_POSIX], test $_target_win32 -ne 0)
19if test $_target_win32 -eq 0; then
20 AC_DEFINE([TARGET_API_WIN32], [1], [Define if the target is the Win32 API.])
21else
22 AC_DEFINE([TARGET_API_POSIX], [1], [Define if the target is the POSIX API.])
23fi
24
25AC_MSG_CHECKING([where to find the X-Plane Plugin SDK])
26AC_ARG_WITH(xpsdk,
27 AC_HELP_STRING([--with-xpsdk=DIR],
28 [use the X-Plane Plugin SDK in DIR]),
29 [
30 if test -r $withval/CHeaders/XPLM/XPLMPlugin.h; then
31 AC_MSG_RESULT([$withval])
32 XPSDK_INCLUDES="-I$withval/CHeaders/XPLM -I$withval/CHeaders/Wrappers -I$withval/CHeaders/Widgets"
33 if test $_target_win32 -eq 0; then
34 XPSDK_LDFLAGS="-L$withval/Libraries/Win"
35 else
36 XPSDK_LDFLAGS=""
37 fi
38 else
39 AC_MSG_FAILURE([not found in $withval])
40 fi
41 ],
42 [
43 AC_MSG_FAILURE([please, specify])
44 ])
45
46AC_SUBST(XPSDK_INCLUDES)
47AC_SUBST(XPSDK_LDFLAGS)
48
49PKG_CHECK_MODULES([LIBXPLCOMMON], [libxplcommon >= 0.1])
50
51AC_CONFIG_FILES([
52 Makefile
53 src/Makefile
54 src/xplra/Makefile
55])
56
57AC_OUTPUT()
Note: See TracBrowser for help on using the repository browser.