/[winpt]/trunk/configure.ac
ViewVC logotype

Annotation of /trunk/configure.ac

Parent Directory Parent Directory | Revision Log Revision Log


Revision 57 - (hide annotations)
Wed Nov 2 11:29:44 2005 UTC (19 years, 3 months ago) by werner
File size: 6611 byte(s)
Builds but we need to check the SetWindowsHookEx semantics to make it run.

1 werner 36 # configure.ac - for WinPT
2     # Copyright (C) 2005 g10 Code GmbH
3     #
4     # This file is free software; as a special exception the author gives
5     # unlimited permission to copy and/or distribute it, with or without
6     # modifications, as long as this notice is preserved.
7     #
8     # This program is distributed in the hope that it will be useful, but
9     # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
10     # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11    
12     # Process this file with autoconf to produce a configure script.
13     AC_PREREQ(2.59)
14     min_automake_version="1.9.4"
15    
16     # Version number: Remember to change it immediately *after* a release.
17     # Add a "-cvs" prefix for non-released code.
18     AC_INIT(WinPT, 0.11.0-cvs, http://www.winpt.org)
19    
20     NEED_GPGME_API=1
21     NEED_GPGME_VERSION=1.1.0
22     NEED_GPG_ERROR_VERSION=1.2
23    
24     PACKAGE=$PACKAGE_NAME
25     PACKAGE_GT=${PACKAGE_NAME}
26     VERSION=$PACKAGE_VERSION
27    
28 werner 57 AC_CONFIG_SRCDIR(Src/WinPT.cpp)
29 werner 36 AM_CONFIG_HEADER(config.h)
30     AC_CANONICAL_TARGET()
31     AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
32    
33     AC_GNU_SOURCE
34    
35     AC_SUBST(PACKAGE)
36     AC_SUBST(PACKAGE_GT)
37     AC_SUBST(VERSION)
38     AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of this package])
39     AC_DEFINE_UNQUOTED(PACKAGE_GT, "$PACKAGE_GT",
40     [Name of this package for gettext])
41     AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version of this package])
42     AC_DEFINE_UNQUOTED(PACKAGE_BUGREPORT, "$PACKAGE_BUGREPORT",
43     [Bug report address])
44     AC_DEFINE_UNQUOTED(NEED_GPGME_VERSION, "$NEED_GPGME_VERSION",
45     [Required version of GPGME])
46    
47     BUILD_TIMESTAMP=`date --iso-8601=minutes`
48     AC_SUBST(BUILD_TIMESTAMP)
49     changequote(,)dnl
50     BUILD_FILEVERSION=`echo "$VERSION" | sed 's/\([0-9.]*\).*/\1.0/;s/\./,/g'`
51     changequote([,])dnl
52     AC_SUBST(BUILD_FILEVERSION)
53    
54    
55     AH_BOTTOM([
56     /* Some global constants. */
57    
58     /* Set to distinguish between the old custom Makefile based build
59 werner 47 system and our new automake based one. This is only required in
60     Include/wptVersion.h. Fixme: See whether we may define the constants
61     there by means of command line apssed args or similar. */
62 werner 36 #define WINPT_MODERN_BUILD 1
63    
64 werner 47 /* FIXME: For what is this needed? */
65     #define WINPT_IPC 1
66    
67 werner 48 /* We need to include this header to be able to include specific parts
68     of the header files. For now we require at least Internet Exploder
69     4.01 to be installed. */
70     #include <w32api.h>
71     #define _WIN32_IE IE401
72    
73 werner 36 ])
74    
75     AM_MAINTAINER_MODE
76    
77     # Checks for programs.
78     AC_PROG_MAKE_SET
79     AM_SANITY_CHECK
80     missing_dir=`cd $ac_aux_dir && pwd`
81     AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
82     AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
83     AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
84     AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
85     AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
86     AC_PROG_AWK
87     AC_PROG_CC
88     AC_PROG_CPP
89     AC_PROG_CXX
90     AC_PROG_INSTALL
91     AC_PROG_LN_S
92     AC_PROG_MAKE_SET
93     AC_PROG_RANLIB
94     AC_CHECK_TOOL(AR, ar, :)
95     AC_CHECK_TOOL(DLLTOOL, dlltool, :)
96     AC_CHECK_TOOL(WINDRES, windres, :)
97    
98    
99     try_gettext=yes
100     have_dosish_system=no
101     have_w32_system=no
102     case "${host}" in
103     *-mingw32*)
104     # special stuff for Windoze NT
105     ac_cv_have_dev_random=no
106     AC_DEFINE(USE_ONLY_8DOT3,1,
107     [set this to limit filenames to the 8.3 format])
108     AC_DEFINE(HAVE_DRIVE_LETTERS,1,
109     [defined if we must run on a stupid file system])
110     AC_DEFINE(USE_SIMPLE_GETTEXT,1,
111     [because the Unix gettext has too much overhead on
112     MingW32 systems and these systems lack Posix functions,
113     we use a simplified version of gettext])
114     have_dosish_system=yes
115     have_w32_system=yes
116     try_gettext="no"
117     ;;
118     *)
119     AC_MSG_ERROR([[
120     ***
121     *** This software my only be build for W32 systems. Use
122     *** ./autogen.sh --build-w32
123     *** to prepare it for such a build.
124     ***]])
125     ;;
126     esac
127    
128     if test "$have_dosish_system" = yes; then
129     AC_DEFINE(HAVE_DOSISH_SYSTEM,1,
130     [Defined if we run on some of the PCDOS like systems
131     (DOS, Windoze. OS/2) with special properties like
132     no file modes])
133     fi
134     AM_CONDITIONAL(HAVE_DOSISH_SYSTEM, test "$have_dosish_system" = yes)
135    
136     if test "$have_w32_system" = yes; then
137     AC_DEFINE(HAVE_W32_SYSTEM,1, [Defined if we run on a W32 API based system])
138     fi
139     AM_CONDITIONAL(HAVE_W32_SYSTEM, test "$have_w32_system" = yes)
140    
141    
142    
143     #
144     # Checks for libraries.
145     #
146    
147    
148     AM_PATH_GPGME("$NEED_GPGME_API:$NEED_GPGME_VERSION",
149     have_gpgme=yes,have_gpgme=no)
150     AM_PATH_GPG_ERROR("$NEED_GPG_ERROR_VERSION",
151     have_gpg_error=yes,have_gpg_error=no)
152    
153     # Checks for header files.
154     AC_HEADER_STDC
155     AC_CHECK_HEADERS(string.h unistd.h langinfo.h termio.h locale.h)
156    
157     AC_CHECK_FUNCS(stpcpy)
158    
159     # Checks for typedefs, structures, and compiler characteristics.
160     AC_C_CONST
161     AC_C_INLINE
162     AC_TYPE_SIZE_T
163     AC_TYPE_SIGNAL
164    
165     AM_CONDITIONAL(CROSS_COMPILING, test x$cross_compiling = xyes)
166    
167     # Add some extra libs here so that previous tests don't fail for
168     # mysterious reasons - the final link step should bail out.
169     if test "$have_w32_system" = yes; then
170     W32LIBS="-lwsock32"
171     fi
172    
173     if test "$GCC" = yes; then
174     CFLAGS="$CFLAGS -Wall -mms-bitfields"
175     CXXFLAGS="$CXXFLAGS -Wall -mms-bitfields"
176     if test "$USE_MAINTAINER_MODE" = "yes"; then
177     CFLAGS="$CFLAGS -Wcast-align -Wshadow -Wstrict-prototypes"
178     CFLAGS="$CFLAGS -Wno-format-y2k -Wformat-security"
179     CXXFLAGS="$CXXFLAGS -Wcast-align -Wshadow"
180     CXXFLAGS="$CXXFLAGS -Wno-format-y2k -Wformat-security"
181     fi
182     fi
183    
184     AC_SUBST(W32LIBS)
185    
186    
187    
188     #
189     # Print errors here so that they are visible all
190     # together and the user can acquire them all together.
191     #
192     die=no
193     if test "$have_gpgme" = "no"; then
194     die=yes
195     AC_MSG_NOTICE([[
196     ***
197     *** You need gpgme to build this program.
198     ** This library is for example available at
199     *** ftp://ftp.gnupg.org/gcrypt/gpgme/
200     *** (at least version $NEED_GPGME_VERSION is required.)
201     ***]])
202     fi
203     if test "$have_gpg_error" = "no"; then
204     die=yes
205     AC_MSG_NOTICE([[
206     ***
207     *** You need libgpg-error to build this program.
208     ** This library is for example available at
209     *** ftp://ftp.gnupg.org/gcrypt/libgpg-error
210     *** (at least version $NEED_GPG_ERROR_VERSION is required.)
211     ***]])
212     fi
213     if test "$die" = "yes"; then
214     AC_MSG_ERROR([[
215     ***
216     *** Required libraries not found. Please consult the above messages
217     *** and install them before running configure again.
218     ***]])
219     fi
220    
221    
222     AC_CONFIG_FILES([ Makefile
223 werner 46 PTD/Makefile
224     PTD/versioninfo.rc
225     Src/Makefile
226     Src/versioninfo.rc
227     Include/Makefile
228     Ico/Makefile
229     m4/Makefile
230     w32gpgme/Makefile
231     Gnupg/Makefile
232 werner 36 ])
233     AC_OUTPUT

Properties

Name Value
svn:eol-style native

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26