chiark / gitweb /
agent: Allow threads to interrupt main select loop with SIGCONT.
[gnupg2.git] / am / cmacros.am
1 # cmacros.am - C macro definitions
2 #     Copyright (C) 2004 Free Software Foundation, Inc.
3 #
4 # This file is part of GnuPG.
5 #
6 # GnuPG is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 3 of the License, or
9 # (at your option) any later version.
10 #
11 # GnuPG is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU General Public License for more details.
15 #
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, see <https://www.gnu.org/licenses/>.
18
19 localedir = $(datadir)/locale
20
21 # NB: AM_CFLAGS may also be used by tools running on the build
22 # platform to create source files.
23 AM_CPPFLAGS += -DLOCALEDIR=\"$(localedir)\"
24
25 if ! HAVE_DOSISH_SYSTEM
26 AM_CPPFLAGS += -DGNUPG_BINDIR="\"$(bindir)\""            \
27                -DGNUPG_LIBEXECDIR="\"$(libexecdir)\""    \
28                -DGNUPG_LIBDIR="\"$(libdir)/@PACKAGE@\""  \
29                -DGNUPG_DATADIR="\"$(datadir)/@PACKAGE@\"" \
30                -DGNUPG_SYSCONFDIR="\"$(sysconfdir)/@PACKAGE@\"" \
31                -DGNUPG_LOCALSTATEDIR="\"$(localstatedir)\""
32 endif
33
34
35 # If a specific protect tool program has been defined, pass its name
36 # to cc.  Note that these macros should not be used directly but via
37 # the gnupg_module_name function.
38 if GNUPG_AGENT_PGM
39 AM_CPPFLAGS += -DGNUPG_DEFAULT_AGENT="\"@GNUPG_AGENT_PGM@\""
40 endif
41 if GNUPG_PINENTRY_PGM
42 AM_CPPFLAGS += -DGNUPG_DEFAULT_PINENTRY="\"@GNUPG_PINENTRY_PGM@\""
43 endif
44 if GNUPG_SCDAEMON_PGM
45 AM_CPPFLAGS += -DGNUPG_DEFAULT_SCDAEMON="\"@GNUPG_SCDAEMON_PGM@\""
46 endif
47 if GNUPG_DIRMNGR_PGM
48 AM_CPPFLAGS += -DGNUPG_DEFAULT_DIRMNGR="\"@GNUPG_DIRMNGR_PGM@\""
49 endif
50 if GNUPG_PROTECT_TOOL_PGM
51 AM_CPPFLAGS += -DGNUPG_DEFAULT_PROTECT_TOOL="\"@GNUPG_PROTECT_TOOL_PGM@\""
52 endif
53 if GNUPG_DIRMNGR_LDAP_PGM
54 AM_CPPFLAGS += -DGNUPG_DEFAULT_DIRMNGR_LDAP="\"@GNUPG_DIRMNGR_LDAP_PGM@\""
55 endif
56
57 # Under Windows we use LockFileEx.  WindowsCE provides this only on
58 # the WindowsMobile 6 platform and thus we need to use the coredll6
59 # import library.  We also want to use a stacksize of 256k instead of
60 # the 2MB which is the default with cegcc.  256k is the largest stack
61 # we use with pth.
62 if HAVE_W32CE_SYSTEM
63 extra_sys_libs = -lcoredll6
64 extra_bin_ldflags = -Wl,--stack=0x40000
65 else
66 extra_sys_libs =
67 extra_bin_ldflags =
68 endif
69
70 if HAVE_W32_SYSTEM
71 .rc.o:
72         $(WINDRES) $(DEFAULT_INCLUDES) $(INCLUDES) "$<" "$@"
73
74 endif
75 resource_objs =
76
77 # Convenience macros
78 libcommon = ../common/libcommon.a
79 libcommonpth = ../common/libcommonpth.a
80 libcommontls = ../common/libcommontls.a
81 libcommontlsnpth = ../common/libcommontlsnpth.a