tools/pcre/Makefile.am
author Ruben Gonzalez <drifter01620@gmail.com>
Thu May 22 09:49:27 2014 -0400 (2014-05-22)
changeset 4378 568f4497ef4a
parent 3831 babd0eee3c5e
permissions -rw-r--r--
Update CS:GO team score gamedata.
     1 ## Process this file with automake to produce Makefile.in.
     2 
     3 ACLOCAL_AMFLAGS = -I m4
     4 
     5 dist_doc_DATA = \
     6   doc/pcre.txt \
     7   doc/pcre-config.txt \
     8   doc/pcregrep.txt \
     9   doc/pcretest.txt \
    10   AUTHORS \
    11   COPYING \
    12   ChangeLog \
    13   LICENCE \
    14   NEWS \
    15   README
    16 
    17 dist_html_DATA = \
    18   doc/html/index.html \
    19   doc/html/pcre.html \
    20   doc/html/pcre16.html \
    21   doc/html/pcre-config.html \
    22   doc/html/pcre_assign_jit_stack.html \
    23   doc/html/pcre_compile.html \
    24   doc/html/pcre_compile2.html \
    25   doc/html/pcre_config.html \
    26   doc/html/pcre_copy_named_substring.html \
    27   doc/html/pcre_copy_substring.html \
    28   doc/html/pcre_dfa_exec.html \
    29   doc/html/pcre_exec.html \
    30   doc/html/pcre_free_study.html \
    31   doc/html/pcre_free_substring.html \
    32   doc/html/pcre_free_substring_list.html \
    33   doc/html/pcre_fullinfo.html \
    34   doc/html/pcre_get_named_substring.html \
    35   doc/html/pcre_get_stringnumber.html \
    36   doc/html/pcre_get_stringtable_entries.html \
    37   doc/html/pcre_get_substring.html \
    38   doc/html/pcre_get_substring_list.html \
    39   doc/html/pcre_jit_exec.html \
    40   doc/html/pcre_jit_stack_alloc.html \
    41   doc/html/pcre_jit_stack_free.html \
    42   doc/html/pcre_maketables.html \
    43   doc/html/pcre_pattern_to_host_byte_order.html \
    44   doc/html/pcre_refcount.html \
    45   doc/html/pcre_study.html \
    46   doc/html/pcre_utf16_to_host_byte_order.html \
    47   doc/html/pcre_version.html \
    48   doc/html/pcreapi.html \
    49   doc/html/pcrebuild.html \
    50   doc/html/pcrecallout.html \
    51   doc/html/pcrecompat.html \
    52   doc/html/pcredemo.html \
    53   doc/html/pcregrep.html \
    54   doc/html/pcrejit.html \
    55   doc/html/pcrelimits.html \
    56   doc/html/pcrematching.html \
    57   doc/html/pcrepartial.html \
    58   doc/html/pcrepattern.html \
    59   doc/html/pcreperform.html \
    60   doc/html/pcreposix.html \
    61   doc/html/pcreprecompile.html \
    62   doc/html/pcresample.html \
    63   doc/html/pcrestack.html \
    64   doc/html/pcresyntax.html \
    65   doc/html/pcretest.html \
    66   doc/html/pcreunicode.html
    67 
    68 #   doc/html/pcre32.html \
    69 #   doc/html/pcre_utf32_to_host_byte_order.html \
    70 #
    71 
    72 pcrecpp_html = doc/html/pcrecpp.html
    73 dist_noinst_DATA = $(pcrecpp_html)
    74 
    75 if WITH_PCRE_CPP
    76 html_DATA = $(pcrecpp_html)
    77 endif
    78 
    79 # The Libtool libraries to install.  We'll add to this later.
    80 lib_LTLIBRARIES =
    81 
    82 # Unit tests you want to run when people type 'make check'.
    83 # TESTS is for binary unit tests, check_SCRIPTS for script-based tests
    84 TESTS =
    85 check_SCRIPTS =
    86 dist_noinst_SCRIPTS =
    87 
    88 # Some of the binaries we make are to be installed, and others are
    89 # (non-user-visible) helper programs needed to build libpcre, libpcre16
    90 # or libpcre32.
    91 bin_PROGRAMS =
    92 noinst_PROGRAMS =
    93 
    94 # Additional files to delete on 'make clean' and 'make maintainer-clean'.
    95 CLEANFILES =
    96 MAINTAINERCLEANFILES =
    97 
    98 # Additional files to bundle with the distribution, over and above what
    99 # the Autotools include by default.
   100 EXTRA_DIST =
   101 
   102 # These files contain additional m4 macros that are used by autoconf.
   103 EXTRA_DIST += \
   104   m4/ax_pthread.m4 m4/pcre_visibility.m4
   105 
   106 # These files contain maintenance information
   107 EXTRA_DIST += \
   108   doc/perltest.txt \
   109   NON-UNIX-USE \
   110   NON-AUTOTOOLS-BUILD \
   111   HACKING
   112 
   113 # These files are used in the preparation of a release
   114 EXTRA_DIST += \
   115   PrepareRelease \
   116   CheckMan \
   117   CleanTxt \
   118   Detrail \
   119   132html \
   120   doc/index.html.src
   121 
   122 # These files are to do with building for Virtual Pascal
   123 EXTRA_DIST += \
   124   makevp.bat \
   125   makevp_c.txt \
   126   makevp_l.txt \
   127   pcregexp.pas
   128 
   129 # These files are usable versions of pcre.h and config.h that are distributed
   130 # for the benefit of people who are building PCRE manually, without the
   131 # Autotools support.
   132 EXTRA_DIST += \
   133   pcre.h.generic \
   134   config.h.generic
   135 
   136 # The only difference between pcre.h.in and pcre.h is the setting of the PCRE
   137 # version number. Therefore, we can create the generic version just by copying.
   138 pcre.h.generic: pcre.h.in configure.ac
   139 	rm -f $@
   140 	cp -p pcre.h $@
   141 
   142 # It is more complicated for config.h.generic. We need the version that results
   143 # from a default configuration. We can get this by doing a configure in a
   144 # temporary directory. However, some trickery is needed,
   145 # because the source directory may already be configured. If you
   146 # just try running configure in a new directory, it complains. For this reason,
   147 # we move config.status out of the way while doing the default configuration.
   148 # The resulting config.h is munged by perl to put #ifdefs round any #defines
   149 # and to get rid of any gcc-specific visibility settings. Make sure that
   150 # PCRE_EXP_DEFN is unset (in case it has visibility settings).
   151 config.h.generic: configure.ac
   152 	rm -rf $@ _generic
   153 	mkdir _generic
   154 	cs=$(srcdir)/config.status; test ! -f $$cs || mv -f $$cs $$cs.aside
   155 	cd _generic && $(abs_top_srcdir)/configure || :
   156 	cs=$(srcdir)/config.status; test ! -f $$cs.aside || mv -f $$cs.aside $$cs
   157 	test -f _generic/config.h
   158 	perl -n \
   159 	  -e 'BEGIN{$$blank=0;}' \
   160 	  -e 'if(/PCRE_EXP_DEFN/){print"/* #undef PCRE_EXP_DEFN */\n";$$blank=0;next;}' \
   161 	  -e 'if(/to make a symbol visible/){next;}' \
   162 	  -e 'if(/__attribute__ \(\(visibility/){next;}' \
   163 	  -e 'if(/^#define\s(?!PACKAGE)(\w+)/){print"#ifndef $$1\n$$_#endif\n";$$blank=0;}' \
   164 	  -e 'else {if(/^\s*$$/){print unless $$blank; $$blank=1;} else{print;$$blank=0;}}' \
   165 	  _generic/config.h >$@
   166 	rm -rf _generic
   167 
   168 MAINTAINERCLEANFILES += pcre.h.generic config.h.generic
   169 
   170 # These are the header files we'll install. We do not distribute pcre.h because
   171 # it is generated from pcre.h.in.
   172 nodist_include_HEADERS = \
   173   pcre.h
   174 include_HEADERS = \
   175   pcreposix.h
   176 
   177 # These additional headers will be be installed if C++ support is enabled. We
   178 # do not distribute pcrecpparg.h or pcre_stringpiece.h, as these are generated
   179 # from corresponding .h.in files (which we do distribute).
   180 if WITH_PCRE_CPP
   181 nodist_include_HEADERS += \
   182   pcrecpparg.h \
   183   pcre_stringpiece.h
   184 include_HEADERS += \
   185   pcrecpp.h \
   186   pcre_scanner.h
   187 endif # WITH_PCRE_CPP
   188 
   189 bin_SCRIPTS = pcre-config
   190 
   191 ## ---------------------------------------------------------------
   192 ## The dftables program is used to rebuild character tables before compiling
   193 ## PCRE, if --enable-rebuild-chartables is specified. It is not a user-visible
   194 ## program. The default (when --enable-rebuild-chartables is not specified) is
   195 ## to copy a distributed set of tables that are defined for ASCII code. In this
   196 ## case, dftables is not needed.
   197 
   198 if WITH_REBUILD_CHARTABLES
   199 
   200 noinst_PROGRAMS += dftables
   201 dftables_SOURCES = dftables.c
   202 
   203 pcre_chartables.c: dftables$(EXEEXT)
   204 	./dftables$(EXEEXT) $@
   205 else
   206 
   207 pcre_chartables.c: $(srcdir)/pcre_chartables.c.dist
   208 	rm -f $@
   209 	$(LN_S) $(srcdir)/pcre_chartables.c.dist $@
   210 
   211 endif # WITH_REBUILD_CHARTABLES
   212 
   213 BUILT_SOURCES = pcre_chartables.c
   214 
   215 ## The main pcre library
   216 
   217 # Build the 8 bit library if it is enabled.
   218 if WITH_PCRE8
   219 lib_LTLIBRARIES += libpcre.la
   220 
   221 libpcre_la_SOURCES = \
   222   pcre_byte_order.c \
   223   pcre_compile.c \
   224   pcre_config.c \
   225   pcre_dfa_exec.c \
   226   pcre_exec.c \
   227   pcre_fullinfo.c \
   228   pcre_get.c \
   229   pcre_globals.c \
   230   pcre_internal.h \
   231   pcre_jit_compile.c \
   232   pcre_maketables.c \
   233   pcre_newline.c \
   234   pcre_ord2utf8.c \
   235   pcre_refcount.c \
   236   pcre_string_utils.c \
   237   pcre_study.c \
   238   pcre_tables.c \
   239   pcre_ucd.c \
   240   pcre_valid_utf8.c \
   241   pcre_version.c \
   242   pcre_xclass.c \
   243   ucp.h
   244 
   245 libpcre_la_CFLAGS = \
   246   $(VISIBILITY_CFLAGS) \
   247   $(AM_CFLAGS)
   248 
   249 libpcre_la_LIBADD =
   250 
   251 ## This file is generated as part of the building process, so don't distribute.
   252 nodist_libpcre_la_SOURCES = \
   253   pcre_chartables.c
   254 
   255 endif # WITH_PCRE8
   256 
   257 # Build the 16 bit library if it is enabled.
   258 if WITH_PCRE16
   259 lib_LTLIBRARIES += libpcre16.la
   260 libpcre16_la_SOURCES = \
   261   pcre16_byte_order.c \
   262   pcre16_chartables.c \
   263   pcre16_compile.c \
   264   pcre16_config.c \
   265   pcre16_dfa_exec.c \
   266   pcre16_exec.c \
   267   pcre16_fullinfo.c \
   268   pcre16_get.c \
   269   pcre16_globals.c \
   270   pcre16_jit_compile.c \
   271   pcre16_maketables.c \
   272   pcre16_newline.c \
   273   pcre16_ord2utf16.c \
   274   pcre16_refcount.c \
   275   pcre16_string_utils.c \
   276   pcre16_study.c \
   277   pcre16_tables.c \
   278   pcre16_ucd.c \
   279   pcre16_utf16_utils.c \
   280   pcre16_valid_utf16.c \
   281   pcre16_version.c \
   282   pcre16_xclass.c
   283 
   284 libpcre16_la_CFLAGS = \
   285   $(VISIBILITY_CFLAGS) \
   286   $(AM_CFLAGS)
   287 
   288 libpcre16_la_LIBADD =
   289 
   290 ## This file is generated as part of the building process, so don't distribute.
   291 nodist_libpcre16_la_SOURCES = \
   292   pcre_chartables.c
   293 
   294 endif # WITH_PCRE16
   295 
   296 # Build the 32 bit library if it is enabled.
   297 if WITH_PCRE32
   298 lib_LTLIBRARIES += libpcre32.la
   299 libpcre32_la_SOURCES = \
   300   pcre32_byte_order.c \
   301   pcre32_chartables.c \
   302   pcre32_compile.c \
   303   pcre32_config.c \
   304   pcre32_dfa_exec.c \
   305   pcre32_exec.c \
   306   pcre32_fullinfo.c \
   307   pcre32_get.c \
   308   pcre32_globals.c \
   309   pcre32_jit_compile.c \
   310   pcre32_maketables.c \
   311   pcre32_newline.c \
   312   pcre32_ord2utf32.c \
   313   pcre32_refcount.c \
   314   pcre32_string_utils.c \
   315   pcre32_study.c \
   316   pcre32_tables.c \
   317   pcre32_ucd.c \
   318   pcre32_utf32_utils.c \
   319   pcre32_valid_utf32.c \
   320   pcre32_version.c \
   321   pcre32_xclass.c
   322 
   323 libpcre32_la_CFLAGS = \
   324   $(VISIBILITY_CFLAGS) \
   325   $(AM_CFLAGS)
   326 
   327 libpcre32_la_LIBADD =
   328 
   329 ## This file is generated as part of the building process, so don't distribute.
   330 nodist_libpcre32_la_SOURCES = \
   331   pcre_chartables.c
   332 
   333 endif # WITH_PCRE32
   334 
   335 # The pcre_chartables.c.dist file is the default version of pcre_chartables.c,
   336 # used unless --enable-rebuild-chartables is specified.
   337 EXTRA_DIST += pcre_chartables.c.dist
   338 
   339 # The JIT compiler lives in a separate directory, but its files are #included
   340 # when pcre_jit_compile.c is processed, so they must be distributed.
   341 EXTRA_DIST += \
   342   sljit/sljitConfig.h \
   343   sljit/sljitConfigInternal.h \
   344   sljit/sljitExecAllocator.c \
   345   sljit/sljitLir.c \
   346   sljit/sljitLir.h \
   347   sljit/sljitNativeARM_Thumb2.c \
   348   sljit/sljitNativeARM_v5.c \
   349   sljit/sljitNativeMIPS_32.c \
   350   sljit/sljitNativeMIPS_common.c \
   351   sljit/sljitNativePPC_32.c \
   352   sljit/sljitNativePPC_64.c \
   353   sljit/sljitNativePPC_common.c \
   354   sljit/sljitNativeSPARC_32.c \
   355   sljit/sljitNativeSPARC_common.c \
   356   sljit/sljitNativeX86_32.c \
   357   sljit/sljitNativeX86_64.c \
   358   sljit/sljitNativeX86_common.c \
   359   sljit/sljitUtils.c
   360 
   361 if WITH_PCRE8
   362 libpcre_la_LDFLAGS = $(EXTRA_LIBPCRE_LDFLAGS)
   363 endif # WITH_PCRE8
   364 if WITH_PCRE16
   365 libpcre16_la_LDFLAGS = $(EXTRA_LIBPCRE16_LDFLAGS)
   366 endif # WITH_PCRE16
   367 if WITH_PCRE32
   368 libpcre32_la_LDFLAGS = $(EXTRA_LIBPCRE32_LDFLAGS)
   369 endif # WITH_PCRE32
   370 
   371 if WITH_VALGRIND
   372 if WITH_PCRE8
   373 libpcre_la_CFLAGS += $(VALGRIND_CFLAGS)
   374 endif # WITH_PCRE8
   375 if WITH_PCRE16
   376 libpcre16_la_CFLAGS += $(VALGRIND_CFLAGS)
   377 endif # WITH_PCRE16
   378 if WITH_PCRE32
   379 libpcre32_la_CFLAGS += $(VALGRIND_CFLAGS)
   380 endif # WITH_PCRE32
   381 endif # WITH_VALGRIND
   382 
   383 if WITH_GCOV
   384 if WITH_PCRE8
   385 libpcre_la_CFLAGS += $(GCOV_CFLAGS)
   386 endif # WITH_PCRE8
   387 if WITH_PCRE16
   388 libpcre16_la_CFLAGS += $(GCOV_CFLAGS)
   389 endif # WITH_PCRE16
   390 if WITH_PCRE32
   391 libpcre32_la_CFLAGS += $(GCOV_CFLAGS)
   392 endif # WITH_PCRE32
   393 endif # WITH_GCOV
   394 
   395 CLEANFILES += pcre_chartables.c
   396 
   397 ## If JIT support is enabled, arrange for the JIT test program to run.
   398 if WITH_JIT
   399 TESTS += pcre_jit_test
   400 noinst_PROGRAMS += pcre_jit_test
   401 pcre_jit_test_SOURCES = pcre_jit_test.c
   402 pcre_jit_test_CFLAGS = $(AM_CFLAGS)
   403 pcre_jit_test_LDADD =
   404 if WITH_PCRE8
   405 pcre_jit_test_LDADD += libpcre.la
   406 endif # WITH_PCRE8
   407 if WITH_PCRE16
   408 pcre_jit_test_LDADD += libpcre16.la
   409 endif # WITH_PCRE16
   410 if WITH_PCRE32
   411 pcre_jit_test_LDADD += libpcre32.la
   412 endif # WITH_PCRE32
   413 if WITH_GCOV
   414 pcre_jit_test_CFLAGS += $(GCOV_CFLAGS)
   415 pcre_jit_test_LDADD += $(GCOV_LIBS)
   416 endif # WITH_GCOV
   417 endif # WITH_JIT
   418 
   419 ## A version of the main pcre library that has a posix re API.
   420 if WITH_PCRE8
   421 
   422 lib_LTLIBRARIES += libpcreposix.la
   423 libpcreposix_la_SOURCES = \
   424   pcreposix.c
   425 libpcreposix_la_CFLAGS = $(VISIBILITY_CFLAGS) $(AM_CFLAGS)
   426 libpcreposix_la_LDFLAGS = $(EXTRA_LIBPCREPOSIX_LDFLAGS)
   427 libpcreposix_la_LIBADD = libpcre.la
   428 
   429 if WITH_GCOV
   430 libpcreposix_la_CFLAGS += $(GCOV_CFLAGS)
   431 endif # WITH_GCOV
   432 
   433 endif # WITH_PCRE8
   434 
   435 ## There's a C++ library as well.
   436 if WITH_PCRE_CPP
   437 
   438 lib_LTLIBRARIES += libpcrecpp.la
   439 libpcrecpp_la_SOURCES = \
   440   pcrecpp_internal.h \
   441   pcrecpp.cc \
   442   pcre_scanner.cc \
   443   pcre_stringpiece.cc
   444 libpcrecpp_la_CXXFLAGS = $(VISIBILITY_CXXFLAGS) $(AM_CXXFLAGS)
   445 libpcrecpp_la_LDFLAGS = $(EXTRA_LIBPCRECPP_LDFLAGS)
   446 libpcrecpp_la_LIBADD = libpcre.la
   447 
   448 TESTS += pcrecpp_unittest
   449 noinst_PROGRAMS += pcrecpp_unittest
   450 pcrecpp_unittest_SOURCES = pcrecpp_unittest.cc
   451 pcrecpp_unittest_CXXFLAGS = $(AM_CXXFLAGS)
   452 pcrecpp_unittest_LDADD = libpcrecpp.la
   453 
   454 TESTS += pcre_scanner_unittest
   455 noinst_PROGRAMS += pcre_scanner_unittest
   456 pcre_scanner_unittest_SOURCES = pcre_scanner_unittest.cc
   457 pcre_scanner_unittest_CXXFLAGS = $(AM_CXXFLAGS)
   458 pcre_scanner_unittest_LDADD = libpcrecpp.la
   459 
   460 TESTS += pcre_stringpiece_unittest
   461 noinst_PROGRAMS += pcre_stringpiece_unittest
   462 pcre_stringpiece_unittest_SOURCES = pcre_stringpiece_unittest.cc
   463 pcre_stringpiece_unittest_CXXFLAGS = $(AM_CXXFLAGS)
   464 pcre_stringpiece_unittest_LDADD = libpcrecpp.la
   465 
   466 if WITH_GCOV
   467 libpcrecpp_la_CXXFLAGS += $(GCOV_CXXFLAGS)
   468 pcrecpp_unittest_LDADD += $(GCOV_LIBS)
   469 pcre_scanner_unittest_LDADD += $(GCOV_LIBS)
   470 pcre_stringpiece_unittest_LDADD += $(GCOV_LIBS)
   471 endif # WITH_GCOV
   472 
   473 endif # WITH_PCRE_CPP
   474 
   475 ## The main unit tests
   476 
   477 # Each unit test is a binary plus a script that runs that binary in various
   478 # ways. We install these test binaries in case folks find it helpful.
   479 
   480 TESTS += RunTest
   481 dist_noinst_SCRIPTS += RunTest
   482 EXTRA_DIST += RunTest.bat
   483 bin_PROGRAMS += pcretest
   484 pcretest_SOURCES = pcretest.c
   485 pcretest_CFLAGS = $(AM_CFLAGS)
   486 pcretest_LDADD = $(LIBREADLINE)
   487 if WITH_PCRE8
   488 pcretest_SOURCES += pcre_printint.c
   489 pcretest_LDADD += libpcre.la libpcreposix.la
   490 endif # WITH_PCRE8
   491 if WITH_PCRE16
   492 pcretest_SOURCES += pcre16_printint.c
   493 pcretest_LDADD += libpcre16.la
   494 endif # WITH_PCRE16
   495 if WITH_PCRE32
   496 pcretest_SOURCES += pcre32_printint.c
   497 pcretest_LDADD += libpcre32.la
   498 endif # WITH_PCRE32
   499 if WITH_VALGRIND
   500 pcretest_CFLAGS += $(VALGRIND_CFLAGS)
   501 endif # WITH_VALGRIND
   502 if WITH_GCOV
   503 pcretest_CFLAGS += $(GCOV_CFLAGS)
   504 pcretest_LDADD += $(GCOV_LIBS)
   505 endif # WITH_GCOV
   506 
   507 if WITH_PCRE8
   508 TESTS += RunGrepTest
   509 dist_noinst_SCRIPTS += RunGrepTest
   510 bin_PROGRAMS += pcregrep
   511 pcregrep_SOURCES = pcregrep.c
   512 pcregrep_CFLAGS = $(AM_CFLAGS)
   513 pcregrep_LDADD = $(LIBZ) $(LIBBZ2)
   514 pcregrep_LDADD += libpcre.la libpcreposix.la
   515 if WITH_GCOV
   516 pcregrep_CFLAGS += $(GCOV_CFLAGS)
   517 pcregrep_LDADD += $(GCOV_LIBS)
   518 endif # WITH_GCOV
   519 endif # WITH_PCRE8
   520 
   521 EXTRA_DIST += \
   522   testdata/grepbinary \
   523   testdata/grepfilelist \
   524   testdata/grepinput \
   525   testdata/grepinput3 \
   526   testdata/grepinput8 \
   527   testdata/grepinputv \
   528   testdata/grepinputx \
   529   testdata/greplist \
   530   testdata/grepoutput \
   531   testdata/grepoutput8 \
   532   testdata/grepoutputN \
   533   testdata/greppatN4 \
   534   testdata/saved16 \
   535   testdata/saved16BE-1 \
   536   testdata/saved16BE-2 \
   537   testdata/saved16LE-1 \
   538   testdata/saved16LE-2 \
   539   testdata/saved32 \
   540   testdata/saved32BE-1 \
   541   testdata/saved32BE-2 \
   542   testdata/saved32LE-1 \
   543   testdata/saved32LE-2 \
   544   testdata/saved8 \
   545   testdata/testinput1 \
   546   testdata/testinput2 \
   547   testdata/testinput3 \
   548   testdata/testinput4 \
   549   testdata/testinput5 \
   550   testdata/testinput6 \
   551   testdata/testinput7 \
   552   testdata/testinput8 \
   553   testdata/testinput9 \
   554   testdata/testinput10 \
   555   testdata/testinput11 \
   556   testdata/testinput12 \
   557   testdata/testinput13 \
   558   testdata/testinput14 \
   559   testdata/testinput15 \
   560   testdata/testinput16 \
   561   testdata/testinput17 \
   562   testdata/testinput18 \
   563   testdata/testinput19 \
   564   testdata/testinput20 \
   565   testdata/testinput21 \
   566   testdata/testinput22 \
   567   testdata/testinput23 \
   568   testdata/testinput24 \
   569   testdata/testinput25 \
   570   testdata/testinput26 \
   571   testdata/testinputEBC \
   572   testdata/testoutput1 \
   573   testdata/testoutput2 \
   574   testdata/testoutput3 \
   575   testdata/testoutput4 \
   576   testdata/testoutput5 \
   577   testdata/testoutput6 \
   578   testdata/testoutput7 \
   579   testdata/testoutput8 \
   580   testdata/testoutput9 \
   581   testdata/testoutput10 \
   582   testdata/testoutput11-8 \
   583   testdata/testoutput11-16 \
   584   testdata/testoutput11-32 \
   585   testdata/testoutput12 \
   586   testdata/testoutput13 \
   587   testdata/testoutput14 \
   588   testdata/testoutput15 \
   589   testdata/testoutput16 \
   590   testdata/testoutput17 \
   591   testdata/testoutput18-16 \
   592   testdata/testoutput18-32 \
   593   testdata/testoutput19 \
   594   testdata/testoutput20 \
   595   testdata/testoutput21-16 \
   596   testdata/testoutput21-32 \
   597   testdata/testoutput22-16 \
   598   testdata/testoutput22-32 \
   599   testdata/testoutput23 \
   600   testdata/testoutput24 \
   601   testdata/testoutput25 \
   602   testdata/testoutput26 \
   603   testdata/testoutputEBC \
   604   testdata/wintestinput3 \
   605   testdata/wintestoutput3 \
   606   perltest.pl
   607 
   608 CLEANFILES += \
   609 	testsavedregex \
   610 	teststderr \
   611         testtemp* \
   612 	testtry \
   613         testNinput
   614 
   615 
   616 # PCRE demonstration program. No longer built automatcally. The point is that
   617 # the users should build it themselves. So just distribute the source.
   618 # noinst_PROGRAMS += pcredemo
   619 # pcredemo_SOURCES = pcredemo.c
   620 # pcredemo_LDADD = libpcre.la
   621 
   622 EXTRA_DIST += pcredemo.c
   623 
   624 
   625 ## Utility rules, documentation, etc.
   626 
   627 # A compatibility line, the old build system worked with 'make test'
   628 test: check ;
   629 
   630 
   631 # A PCRE user submitted the following addition, saying that it "will allow
   632 # anyone using the 'mingw32' compiler to simply type 'make pcre.dll' and get a
   633 # nice DLL for Windows use". (It is used by the pcre.dll target.)
   634 DLL_OBJS= pcre_byte_order.o pcre_compile.o pcre_config.o \
   635 	pcre_dfa_exec.o pcre_exec.o pcre_fullinfo.o pcre_get.o \
   636 	pcre_globals.o pcre_jit_compile.o pcre_maketables.o \
   637 	pcre_newline.o pcre_ord2utf8.o pcre_refcount.o \
   638 	pcre_study.o pcre_tables.o pcre_ucd.o \
   639 	pcre_valid_utf8.o pcre_version.o pcre_chartables.o \
   640 	pcre_xclass.o
   641 
   642 # A PCRE user submitted the following addition, saying that it "will allow
   643 # anyone using the 'mingw32' compiler to simply type 'make pcre.dll' and get a
   644 # nice DLL for Windows use".
   645 pcre.dll: $(DLL_OBJS)
   646 	$(CC) -shared -o pcre.dll -Wl,"--strip-all" -Wl,"--export-all-symbols" $(DLL_OBJS)
   647 
   648 
   649 # We have .pc files for pkg-config users.
   650 pkgconfigdir = $(libdir)/pkgconfig
   651 pkgconfig_DATA = libpcre.pc libpcreposix.pc
   652 if WITH_PCRE16
   653 pkgconfig_DATA += libpcre16.pc
   654 endif
   655 if WITH_PCRE32
   656 pkgconfig_DATA += libpcre32.pc
   657 endif
   658 if WITH_PCRE_CPP
   659 pkgconfig_DATA += libpcrecpp.pc
   660 endif
   661 
   662 dist_man_MANS = \
   663   doc/pcre.3 \
   664   doc/pcre16.3 \
   665   doc/pcre32.3 \
   666   doc/pcre-config.1 \
   667   doc/pcre_assign_jit_stack.3 \
   668   doc/pcre_compile.3 \
   669   doc/pcre_compile2.3 \
   670   doc/pcre_config.3 \
   671   doc/pcre_copy_named_substring.3 \
   672   doc/pcre_copy_substring.3 \
   673   doc/pcre_dfa_exec.3 \
   674   doc/pcre_exec.3 \
   675   doc/pcre_free_study.3 \
   676   doc/pcre_free_substring.3 \
   677   doc/pcre_free_substring_list.3 \
   678   doc/pcre_fullinfo.3 \
   679   doc/pcre_get_named_substring.3 \
   680   doc/pcre_get_stringnumber.3 \
   681   doc/pcre_get_stringtable_entries.3 \
   682   doc/pcre_get_substring.3 \
   683   doc/pcre_get_substring_list.3 \
   684   doc/pcre_jit_exec.3 \
   685   doc/pcre_jit_stack_alloc.3 \
   686   doc/pcre_jit_stack_free.3 \
   687   doc/pcre_maketables.3 \
   688   doc/pcre_pattern_to_host_byte_order.3 \
   689   doc/pcre_refcount.3 \
   690   doc/pcre_study.3 \
   691   doc/pcre_utf16_to_host_byte_order.3 \
   692   doc/pcre_utf32_to_host_byte_order.3 \
   693   doc/pcre_version.3 \
   694   doc/pcreapi.3 \
   695   doc/pcrebuild.3 \
   696   doc/pcrecallout.3 \
   697   doc/pcrecompat.3 \
   698   doc/pcregrep.1 \
   699   doc/pcrejit.3 \
   700   doc/pcrelimits.3 \
   701   doc/pcrematching.3 \
   702   doc/pcrepartial.3 \
   703   doc/pcrepattern.3 \
   704   doc/pcreperform.3 \
   705   doc/pcreposix.3 \
   706   doc/pcreprecompile.3 \
   707   doc/pcresample.3 \
   708   doc/pcrestack.3 \
   709   doc/pcresyntax.3 \
   710   doc/pcretest.1 \
   711   doc/pcreunicode.3
   712 
   713 # Arrange for the per-function man pages to have 16- and 32-bit names as well.
   714 install-data-hook:
   715 	ln -sf pcre_assign_jit_stack.3		 $(DESTDIR)$(man3dir)/pcre16_assign_jit_stack.3
   716 	ln -sf pcre_compile.3			 $(DESTDIR)$(man3dir)/pcre16_compile.3
   717 	ln -sf pcre_compile2.3			 $(DESTDIR)$(man3dir)/pcre16_compile2.3
   718 	ln -sf pcre_config.3			 $(DESTDIR)$(man3dir)/pcre16_config.3
   719 	ln -sf pcre_copy_named_substring.3	 $(DESTDIR)$(man3dir)/pcre16_copy_named_substring.3
   720 	ln -sf pcre_copy_substring.3		 $(DESTDIR)$(man3dir)/pcre16_copy_substring.3
   721 	ln -sf pcre_dfa_exec.3			 $(DESTDIR)$(man3dir)/pcre16_dfa_exec.3
   722 	ln -sf pcre_exec.3			 $(DESTDIR)$(man3dir)/pcre16_exec.3
   723 	ln -sf pcre_free_study.3		 $(DESTDIR)$(man3dir)/pcre16_free_study.3
   724 	ln -sf pcre_free_substring.3		 $(DESTDIR)$(man3dir)/pcre16_free_substring.3
   725 	ln -sf pcre_free_substring_list.3	 $(DESTDIR)$(man3dir)/pcre16_free_substring_list.3
   726 	ln -sf pcre_fullinfo.3			 $(DESTDIR)$(man3dir)/pcre16_fullinfo.3
   727 	ln -sf pcre_get_named_substring.3	 $(DESTDIR)$(man3dir)/pcre16_get_named_substring.3
   728 	ln -sf pcre_get_stringnumber.3		 $(DESTDIR)$(man3dir)/pcre16_get_stringnumber.3
   729 	ln -sf pcre_get_stringtable_entries.3	 $(DESTDIR)$(man3dir)/pcre16_get_stringtable_entries.3
   730 	ln -sf pcre_get_substring.3		 $(DESTDIR)$(man3dir)/pcre16_get_substring.3
   731 	ln -sf pcre_get_substring_list.3	 $(DESTDIR)$(man3dir)/pcre16_get_substring_list.3
   732 	ln -sf pcre_jit_exec.3			 $(DESTDIR)$(man3dir)/pcre16_jit_exec.3
   733 	ln -sf pcre_jit_stack_alloc.3		 $(DESTDIR)$(man3dir)/pcre16_jit_stack_alloc.3
   734 	ln -sf pcre_jit_stack_free.3		 $(DESTDIR)$(man3dir)/pcre16_jit_stack_free.3
   735 	ln -sf pcre_maketables.3		 $(DESTDIR)$(man3dir)/pcre16_maketables.3
   736 	ln -sf pcre_pattern_to_host_byte_order.3 $(DESTDIR)$(man3dir)/pcre16_pattern_to_host_byte_order.3
   737 	ln -sf pcre_refcount.3			 $(DESTDIR)$(man3dir)/pcre16_refcount.3
   738 	ln -sf pcre_study.3			 $(DESTDIR)$(man3dir)/pcre16_study.3
   739 	ln -sf pcre_utf16_to_host_byte_order.3	 $(DESTDIR)$(man3dir)/pcre16_utf16_to_host_byte_order.3
   740 	ln -sf pcre_version.3			 $(DESTDIR)$(man3dir)/pcre16_version.3
   741 	ln -sf pcre_assign_jit_stack.3		 $(DESTDIR)$(man3dir)/pcre32_assign_jit_stack.3
   742 	ln -sf pcre_compile.3			 $(DESTDIR)$(man3dir)/pcre32_compile.3
   743 	ln -sf pcre_compile2.3			 $(DESTDIR)$(man3dir)/pcre32_compile2.3
   744 	ln -sf pcre_config.3			 $(DESTDIR)$(man3dir)/pcre32_config.3
   745 	ln -sf pcre_copy_named_substring.3	 $(DESTDIR)$(man3dir)/pcre32_copy_named_substring.3
   746 	ln -sf pcre_copy_substring.3		 $(DESTDIR)$(man3dir)/pcre32_copy_substring.3
   747 	ln -sf pcre_dfa_exec.3			 $(DESTDIR)$(man3dir)/pcre32_dfa_exec.3
   748 	ln -sf pcre_exec.3			 $(DESTDIR)$(man3dir)/pcre32_exec.3
   749 	ln -sf pcre_free_study.3		 $(DESTDIR)$(man3dir)/pcre32_free_study.3
   750 	ln -sf pcre_free_substring.3		 $(DESTDIR)$(man3dir)/pcre32_free_substring.3
   751 	ln -sf pcre_free_substring_list.3	 $(DESTDIR)$(man3dir)/pcre32_free_substring_list.3
   752 	ln -sf pcre_fullinfo.3			 $(DESTDIR)$(man3dir)/pcre32_fullinfo.3
   753 	ln -sf pcre_get_named_substring.3	 $(DESTDIR)$(man3dir)/pcre32_get_named_substring.3
   754 	ln -sf pcre_get_stringnumber.3		 $(DESTDIR)$(man3dir)/pcre32_get_stringnumber.3
   755 	ln -sf pcre_get_stringtable_entries.3	 $(DESTDIR)$(man3dir)/pcre32_get_stringtable_entries.3
   756 	ln -sf pcre_get_substring.3		 $(DESTDIR)$(man3dir)/pcre32_get_substring.3
   757 	ln -sf pcre_get_substring_list.3	 $(DESTDIR)$(man3dir)/pcre32_get_substring_list.3
   758 	ln -sf pcre_jit_exec.3			 $(DESTDIR)$(man3dir)/pcre32_jit_exec.3
   759 	ln -sf pcre_jit_stack_alloc.3		 $(DESTDIR)$(man3dir)/pcre32_jit_stack_alloc.3
   760 	ln -sf pcre_jit_stack_free.3		 $(DESTDIR)$(man3dir)/pcre32_jit_stack_free.3
   761 	ln -sf pcre_maketables.3		 $(DESTDIR)$(man3dir)/pcre32_maketables.3
   762 	ln -sf pcre_pattern_to_host_byte_order.3 $(DESTDIR)$(man3dir)/pcre32_pattern_to_host_byte_order.3
   763 	ln -sf pcre_refcount.3			 $(DESTDIR)$(man3dir)/pcre32_refcount.3
   764 	ln -sf pcre_study.3			 $(DESTDIR)$(man3dir)/pcre32_study.3
   765 	ln -sf pcre_utf32_to_host_byte_order.3	 $(DESTDIR)$(man3dir)/pcre32_utf32_to_host_byte_order.3
   766 	ln -sf pcre_version.3			 $(DESTDIR)$(man3dir)/pcre32_version.3
   767 
   768 pcrecpp_man = doc/pcrecpp.3
   769 EXTRA_DIST += $(pcrecpp_man)
   770 
   771 if WITH_PCRE_CPP
   772 man_MANS = $(pcrecpp_man)
   773 endif
   774 
   775 # gcov/lcov code coverage reporting
   776 
   777 if WITH_GCOV
   778 
   779 # Coverage reporting targets:
   780 #
   781 # coverage: Create a coverage report from 'make check'
   782 # coverage-baseline: Capture baseline coverage information
   783 # coverage-reset: This zeros the coverage counters only
   784 # coverage-report: This creates the coverage report only
   785 # coverage-clean-report: This removes the generated coverage report
   786 #   without cleaning the coverage data itself
   787 # coverage-clean-data: This removes the captured coverage data without
   788 #   removing the coverage files created at compile time (*.gcno)
   789 # coverage-clean: This cleans all coverage data including the generated
   790 #   coverage report.
   791 
   792 COVERAGE_TEST_NAME = $(PACKAGE)
   793 COVERAGE_NAME = $(PACKAGE)-$(VERSION)
   794 COVERAGE_OUTPUT_FILE = $(COVERAGE_NAME)-coverage.info
   795 COVERAGE_OUTPUT_DIR = $(COVERAGE_NAME)-coverage
   796 COVERAGE_LCOV_EXTRA_FLAGS =
   797 COVERAGE_GENHTML_EXTRA_FLAGS =
   798 
   799 coverage_quiet = $(coverage_quiet_$(V))
   800 coverage_quiet_ = $(coverage_quiet_$(AM_DEFAULT_VERBOSITY))
   801 coverage_quiet_0 = --quiet
   802 
   803 coverage-check: all
   804 	-$(MAKE) $(AM_MAKEFLAGS) -k check
   805 
   806 coverage-baseline:
   807 	$(LCOV) $(coverage_quiet) \
   808 		--directory $(top_builddir) \
   809 		--output-file "$(COVERAGE_OUTPUT_FILE)" \
   810 		--capture \
   811 		--initial
   812 
   813 coverage-report:
   814 	$(LCOV) $(coverage_quiet) \
   815 		--directory $(top_builddir) \
   816 		--capture \
   817 		--output-file "$(COVERAGE_OUTPUT_FILE).tmp" \
   818 		--test-name "$(COVERAGE_TEST_NAME)" \
   819 		--no-checksum \
   820 		--compat-libtool \
   821 		$(COVERAGE_LCOV_EXTRA_FLAGS)
   822 	$(LCOV) $(coverage_quiet) \
   823 		--directory $(top_builddir) \
   824 		--output-file "$(COVERAGE_OUTPUT_FILE)" \
   825 		--remove "$(COVERAGE_OUTPUT_FILE).tmp" \
   826 		"/tmp/*" \
   827 		"/usr/include/*" \
   828 		"$(includedir)/*"
   829 	-@rm -f "$(COVERAGE_OUTPUT_FILE).tmp"
   830 	LANG=C $(GENHTML) $(coverage_quiet) \
   831 		--prefix $(top_builddir) \
   832 		--output-directory "$(COVERAGE_OUTPUT_DIR)" \
   833 		--title "$(PACKAGE) $(VERSION) Code Coverage Report" \
   834 		--show-details "$(COVERAGE_OUTPUT_FILE)" \
   835 		--legend \
   836 		$(COVERAGE_GENHTML_EXTRA_FLAGS)
   837 	@echo "Code coverage report written to file://$(abs_builddir)/$(COVERAGE_OUTPUT_DIR)/index.html"
   838 
   839 coverage-reset:
   840 	-$(LCOV) $(coverage_quiet) --zerocounters --directory $(top_builddir)
   841 
   842 coverage-clean-report:
   843 	-rm -f "$(COVERAGE_OUTPUT_FILE)" "$(COVERAGE_OUTPUT_FILE).tmp"
   844 	-rm -rf "$(COVERAGE_OUTPUT_DIR)"
   845 
   846 coverage-clean-data:
   847 	-find $(top_builddir) -name "*.gcda" -delete
   848 
   849 coverage-clean: coverage-reset coverage-clean-report coverage-clean-data
   850 	-find $(top_builddir) -name "*.gcno" -delete
   851 
   852 coverage-distclean: coverage-clean
   853 
   854 coverage: coverage-reset coverage-baseline coverage-check coverage-report
   855 clean-local: coverage-clean
   856 distclean-local: coverage-distclean
   857 
   858 .PHONY: coverage coverage-baseline coverage-check coverage-report coverage-reset coverage-clean-report coverage-clean-data coverage-clean coverage-distclean
   859 
   860 else
   861 
   862 coverage:
   863 	@echo "Configuring with --enable-coverage required to generate code coverage report."
   864 
   865 endif # WITH_GCOV
   866 
   867 ## CMake support
   868 
   869 EXTRA_DIST += \
   870   cmake/COPYING-CMAKE-SCRIPTS \
   871   cmake/FindPackageHandleStandardArgs.cmake \
   872   cmake/FindReadline.cmake \
   873   cmake/FindEditline.cmake \
   874   CMakeLists.txt \
   875   config-cmake.h.in
   876 
   877 ## end Makefile.am