libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

Makefile.am (6276B)


      1 # This Makefile.am is in the public domain
      2 SUBDIRS  = .
      3 
      4 AM_CPPFLAGS = \
      5   -I$(top_srcdir)/src/include \
      6   $(CPPFLAGS_ac) $(LIBCURL_CPPFLAGS) \
      7   -DDATA_DIR=\"$(top_srcdir)/src/datadir/\"
      8 
      9 AM_CFLAGS = $(CFLAGS_ac) @LIBGCRYPT_CFLAGS@
     10 
     11 AM_LDFLAGS = $(LDFLAGS_ac)
     12 
     13 MHD_CPU_COUNT_DEF = -DMHD_CPU_COUNT=$(CPU_COUNT)
     14 
     15 AM_TESTS_ENVIRONMENT = $(TESTS_ENVIRONMENT_ac)
     16 
     17 if USE_COVERAGE
     18   AM_CFLAGS += --coverage
     19 endif
     20 
     21 $(top_builddir)/src/microhttpd/libmicrohttpd.la: $(top_builddir)/src/microhttpd/Makefile
     22 	@echo ' cd $(top_builddir)/src/microhttpd && $(MAKE) $(AM_MAKEFLAGS) libmicrohttpd.la'; \
     23 	$(am__cd) $(top_builddir)/src/microhttpd && $(MAKE) $(AM_MAKEFLAGS) libmicrohttpd.la
     24 
     25 
     26 # example programs
     27 noinst_PROGRAMS = \
     28  benchmark \
     29  benchmark_https \
     30  chunked_example \
     31  minimal_example \
     32  minimal_example_empty \
     33  dual_stack_example \
     34  minimal_example_comet \
     35  querystring_example \
     36  timeout \
     37  fileserver_example \
     38  fileserver_example_dirs \
     39  fileserver_example_external_select \
     40  refuse_post_example
     41 
     42 if MHD_HAVE_EPOLL
     43 noinst_PROGRAMS += \
     44   suspend_resume_epoll
     45 if HAVE_FORK_WAITPID
     46 if RUN_LIBCURL_TESTS
     47 check_PROGRAMS = test_suspend_resume_epoll
     48 TESTS = $(check_PROGRAMS)
     49 endif
     50 endif
     51 endif
     52 
     53 if HAVE_JANSSON
     54 noinst_PROGRAMS += \
     55   json_echo
     56 endif
     57 
     58 EXTRA_DIST = msgs_i18n.c
     59 noinst_EXTRA_DIST = msgs_i18n.c
     60 
     61 if ENABLE_HTTPS
     62 noinst_PROGRAMS += \
     63  https_fileserver_example \
     64  minimal_example_empty_tls
     65 endif
     66 if HAVE_POSTPROCESSOR
     67 noinst_PROGRAMS += \
     68   post_example
     69 if HAVE_POSIX_THREADS
     70 noinst_PROGRAMS += demo
     71 if ENABLE_HTTPS
     72 noinst_PROGRAMS += demo_https
     73 endif
     74 endif
     75 endif
     76 
     77 if ENABLE_DAUTH
     78 noinst_PROGRAMS += \
     79  digest_auth_example \
     80  digest_auth_example_adv
     81 endif
     82 
     83 if ENABLE_BAUTH
     84 noinst_PROGRAMS += \
     85  authorization_example
     86 endif
     87 
     88 if HAVE_POSIX_THREADS
     89 if ENABLE_UPGRADE
     90 noinst_PROGRAMS += \
     91  upgrade_example
     92 endif
     93 endif
     94 
     95 if HAVE_ZLIB
     96 noinst_PROGRAMS += \
     97  http_compression \
     98  http_chunked_compression
     99 endif
    100 
    101 if HAVE_W32
    102 AM_CFLAGS += -DWINDOWS
    103 endif
    104 
    105 minimal_example_SOURCES = \
    106  minimal_example.c
    107 minimal_example_LDADD = \
    108  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    109 
    110 minimal_example_empty_SOURCES = \
    111  minimal_example_empty.c
    112 minimal_example_empty_LDADD = \
    113  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    114 
    115 minimal_example_empty_tls_SOURCES = \
    116  minimal_example_empty_tls.c
    117 minimal_example_empty_tls_LDADD = \
    118  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    119 
    120 upgrade_example_SOURCES = \
    121  upgrade_example.c
    122 upgrade_example_CFLAGS = \
    123   $(PTHREAD_CFLAGS) $(AM_CFLAGS)
    124 upgrade_example_LDADD = \
    125   $(top_builddir)/src/microhttpd/libmicrohttpd.la \
    126   $(PTHREAD_LIBS)
    127 
    128 timeout_SOURCES = \
    129  timeout.c
    130 timeout_LDADD = \
    131  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    132 
    133 chunked_example_SOURCES = \
    134  chunked_example.c
    135 chunked_example_LDADD = \
    136  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    137 
    138 json_echo_SOURCES = \
    139  json_echo.c
    140 json_echo_LDADD = \
    141  $(top_builddir)/src/microhttpd/libmicrohttpd.la \
    142  -ljansson
    143 
    144 demo_SOURCES = \
    145  demo.c
    146 demo_CFLAGS = \
    147  $(PTHREAD_CFLAGS) $(AM_CFLAGS)
    148 demo_CPPFLAGS = \
    149  $(AM_CPPFLAGS) $(MHD_CPU_COUNT_DEF)
    150 demo_LDADD = \
    151  $(top_builddir)/src/microhttpd/libmicrohttpd.la  \
    152  $(PTHREAD_LIBS)
    153 if MHD_HAVE_LIBMAGIC
    154 demo_LDADD += -lmagic
    155 endif
    156 
    157 demo_https_SOURCES = \
    158  demo_https.c
    159 demo_https_CFLAGS = \
    160  $(PTHREAD_CFLAGS) $(AM_CFLAGS)
    161 demo_https_CPPFLAGS = \
    162  $(AM_CPPFLAGS) $(MHD_CPU_COUNT_DEF)
    163 demo_https_LDADD = \
    164  $(top_builddir)/src/microhttpd/libmicrohttpd.la  \
    165  $(PTHREAD_LIBS)
    166 if MHD_HAVE_LIBMAGIC
    167 demo_https_LDADD += -lmagic
    168 endif
    169 
    170 benchmark_SOURCES = \
    171  benchmark.c
    172 benchmark_CPPFLAGS = \
    173  $(AM_CPPFLAGS) $(MHD_CPU_COUNT_DEF)
    174 benchmark_LDADD = \
    175  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    176 
    177 suspend_resume_epoll_SOURCES = \
    178  suspend_resume_epoll.c
    179 suspend_resume_epoll_CPPFLAGS = \
    180  $(AM_CPPFLAGS) $(MHD_CPU_COUNT_DEF)
    181 suspend_resume_epoll_LDADD = \
    182  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    183 
    184 test_suspend_resume_epoll_SOURCES = \
    185  test_suspend_resume_epoll.c
    186 test_suspend_resume_epoll_LDADD = \
    187  @LIBCURL@
    188 
    189 benchmark_https_SOURCES = \
    190  benchmark_https.c
    191 benchmark_https_CPPFLAGS = \
    192  $(AM_CPPFLAGS) $(MHD_CPU_COUNT_DEF)
    193 benchmark_https_LDADD = \
    194  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    195 
    196 dual_stack_example_SOURCES = \
    197  dual_stack_example.c
    198 dual_stack_example_LDADD = \
    199  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    200 
    201 post_example_SOURCES = \
    202  post_example.c
    203 post_example_LDADD = \
    204  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    205 
    206 minimal_example_comet_SOURCES = \
    207  minimal_example_comet.c
    208 minimal_example_comet_LDADD = \
    209  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    210 
    211 authorization_example_SOURCES = \
    212  authorization_example.c
    213 authorization_example_LDADD = \
    214  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    215 
    216 digest_auth_example_SOURCES = \
    217  digest_auth_example.c
    218 digest_auth_example_LDADD = \
    219  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    220 
    221 digest_auth_example_adv_SOURCES = \
    222  digest_auth_example_adv.c
    223 digest_auth_example_adv_LDADD = \
    224  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    225 
    226 refuse_post_example_SOURCES = \
    227  refuse_post_example.c
    228 refuse_post_example_LDADD = \
    229  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    230 
    231 querystring_example_SOURCES = \
    232  querystring_example.c
    233 querystring_example_LDADD = \
    234  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    235 
    236 fileserver_example_SOURCES = \
    237  fileserver_example.c
    238 fileserver_example_LDADD = \
    239  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    240 
    241 fileserver_example_dirs_SOURCES = \
    242  fileserver_example_dirs.c
    243 fileserver_example_dirs_LDADD = \
    244  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    245 
    246 fileserver_example_external_select_SOURCES = \
    247  fileserver_example_external_select.c
    248 fileserver_example_external_select_LDADD = \
    249  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    250 
    251 https_fileserver_example_SOURCES = \
    252 https_fileserver_example.c
    253 https_fileserver_example_CPPFLAGS = \
    254  $(AM_CPPFLAGS) $(GNUTLS_CPPFLAGS)
    255 https_fileserver_example_LDADD = \
    256  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    257 
    258 http_compression_SOURCES = \
    259  http_compression.c
    260 http_chunked_compression_SOURCES = \
    261  http_chunked_compression.c
    262 http_compression_LDADD = \
    263  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    264 http_chunked_compression_LDADD = \
    265  $(top_builddir)/src/microhttpd/libmicrohttpd.la
    266 if HAVE_ZLIB
    267  http_compression_LDADD += -lz
    268  http_chunked_compression_LDADD += -lz
    269 endif