Home | History | Annotate | Download | only in open-vcdiff
      1 ## Process this file with automake to produce Makefile.in
      2 
      3 # Make sure that when we re-make ./configure, we get the macros we need
      4 ACLOCAL_AMFLAGS = -I m4 \
      5                   -I gflags/m4
      6 
      7 # This is so we can #include <google/vcencoder.h> or <gtest/gtest.h>
      8 AM_CPPFLAGS = -I$(top_srcdir)/src \
      9               -I$(top_srcdir)/src/zlib \
     10               -I$(top_srcdir)/gflags/src \
     11               -I$(top_srcdir)/gtest \
     12               -I$(top_srcdir)/gtest/include
     13 
     14 # For a non-optimized (debug) build, change "-DNDEBUG" to "-DDEBUG".
     15 AM_CXXFLAGS = -DNDEBUG -DNO_THREADS
     16 
     17 # Enable verbose gcc warnings.  We use the older option name "-W" to be
     18 # compatible with gcc v3.3 and earlier.  That option should be changed to
     19 # "-Wextra" when we can be sure that early gcc versions will not be used.
     20 if GCC
     21 AM_CXXFLAGS += -Wall -Wwrite-strings -Woverloaded-virtual -W
     22 endif
     23 
     24 AM_LDFLAGS = -no-undefined $(LIBSTDCXX_LA_LINKER_FLAG)
     25 
     26 googleincludedir = $(includedir)/google
     27 ## The .h files you want to install (that is, .h files that people
     28 ## who install this package can include in their own applications.)
     29 googleinclude_HEADERS = src/google/vcdecoder.h src/google/vcencoder.h \
     30 			src/google/format_extension_flags.h \
     31 			src/google/output_string.h
     32 
     33 docdir = $(prefix)/share/doc/$(PACKAGE)-$(VERSION)
     34 dist_doc_DATA = AUTHORS COPYING ChangeLog INSTALL NEWS README THANKS
     35 
     36 # The manual pages that should be installed
     37 dist_man1_MANS = man/vcdiff.1
     38 
     39 ## The libraries (.so's) you want to build and install
     40 lib_LTLIBRARIES =
     41 
     42 ## Binaries to be built and installed; these are added in the RULES section
     43 bin_PROGRAMS =
     44 
     45 ## Binary and script unit tests you want to run when people type 'make check'.
     46 ## Tests are added one by one to these lists in the RULES sections.
     47 check_PROGRAMS =
     48 check_SCRIPTS =
     49 
     50 ## Other binaries, scripts, and libraries that are built but not automatically
     51 ## installed.
     52 noinst_PROGRAMS =
     53 noinst_SCRIPTS =
     54 noinst_LTLIBRARIES =
     55 
     56 ## vvvv RULES TO MAKE THE LIBRARIES, BINARIES, AND UNITTESTS
     57 
     58 # google-gflags: Used for command-line client
     59 #     Please refer to http://code.google.com/p/google-gflags/ for details
     60 noinst_LTLIBRARIES += libgflags.la
     61 libgflags_la_SOURCES = gflags/src/gflags/gflags.h \
     62                        gflags/src/gflags/gflags_completions.h \
     63                        gflags/src/mutex.h \
     64                        gflags/src/gflags.cc \
     65                        gflags/src/gflags_completions.cc \
     66                        gflags/src/gflags_reporting.cc
     67 
     68 # gtest (Google Test): Used for unit tests only
     69 #     Please refer to http://code.google.com/p/googletest/ for details
     70 noinst_LTLIBRARIES += libgtest_main.la
     71 libgtest_main_la_SOURCES = gtest/include/gtest/gtest.h \
     72                            gtest/include/gtest/gtest-death-test.h \
     73                            gtest/include/gtest/gtest-message.h \
     74                            gtest/include/gtest/gtest-param-test.h \
     75                            gtest/include/gtest/gtest_pred_impl.h \
     76                            gtest/include/gtest/gtest_prod.h \
     77                            gtest/include/gtest/gtest-spi.h \
     78                            gtest/include/gtest/gtest-test-part.h \
     79                            gtest/include/gtest/gtest-typed-test.h \
     80                            gtest/include/gtest/internal/gtest-death-test-internal.h \
     81                            gtest/include/gtest/internal/gtest-filepath.h \
     82                            gtest/include/gtest/internal/gtest-internal.h \
     83                            gtest/include/gtest/internal/gtest-linked_ptr.h \
     84                            gtest/include/gtest/internal/gtest-param-util.h \
     85                            gtest/include/gtest/internal/gtest-param-util-generated.h \
     86                            gtest/include/gtest/internal/gtest-port.h \
     87                            gtest/include/gtest/internal/gtest-string.h \
     88                            gtest/include/gtest/internal/gtest-tuple.h \
     89                            gtest/include/gtest/internal/gtest-type-util.h \
     90                            gtest/src/gtest-internal-inl.h \
     91                            gtest/src/gtest.cc \
     92                            gtest/src/gtest-death-test.cc \
     93                            gtest/src/gtest-filepath.cc \
     94                            gtest/src/gtest-port.cc \
     95                            gtest/src/gtest-test-part.cc \
     96                            gtest/src/gtest-typed-test.cc \
     97                            gtest/src/gtest_main.cc \
     98                            src/testing.h
     99 
    100 noinst_LTLIBRARIES += libvcdecoder_test_common.la
    101 libvcdecoder_test_common_la_SOURCES = src/vcdecoder_test.h \
    102 				      src/vcdecoder_test.cc
    103 libvcdecoder_test_common_la_LIBADD = libvcddec.la libgtest_main.la
    104 
    105 # libvcdcom: The open-vcdiff *common* library
    106 lib_LTLIBRARIES += libvcdcom.la
    107 libvcdcom_la_SOURCES = src/google/format_extension_flags.h \
    108 		       src/google/output_string.h \
    109 		       src/addrcache.h \
    110 		       src/checksum.h \
    111 		       src/codetable.h \
    112 		       src/logging.h \
    113 		       src/varint_bigendian.h \
    114 		       src/vcdiff_defs.h \
    115 		       src/zlib/zlib.h \
    116 		       src/zlib/zconf.h \
    117 		       src/zlib/adler32.c \
    118 		       src/addrcache.cc \
    119 		       src/codetable.cc \
    120 		       src/logging.cc \
    121 		       src/varint_bigendian.cc
    122 
    123 # libvcddec: The open-vcdiff *decoder* library
    124 lib_LTLIBRARIES += libvcddec.la
    125 libvcddec_la_SOURCES = src/google/vcdecoder.h \
    126 		       src/decodetable.h \
    127 		       src/headerparser.h \
    128 		       src/decodetable.cc \
    129 		       src/headerparser.cc \
    130 		       src/vcdecoder.cc
    131 libvcddec_la_LIBADD = libvcdcom.la
    132 
    133 # libvcdenc: The open-vcdiff *encoder* library
    134 lib_LTLIBRARIES += libvcdenc.la
    135 libvcdenc_la_SOURCES = src/google/vcencoder.h \
    136 		       src/blockhash.h \
    137 		       src/codetablewriter_interface.h \
    138 		       src/compile_assert.h \
    139 		       src/encodetable.h \
    140 		       src/instruction_map.h \
    141 		       src/jsonwriter.h \
    142 		       src/rolling_hash.h \
    143 		       src/vcdiffengine.h \
    144 		       src/blockhash.cc \
    145 		       src/encodetable.cc \
    146 		       src/instruction_map.cc \
    147 		       src/jsonwriter.cc \
    148 		       src/vcdiffengine.cc \
    149                        src/vcencoder.cc
    150 libvcdenc_la_LIBADD = libvcdcom.la
    151 
    152 bin_PROGRAMS += vcdiff
    153 vcdiff_SOURCES = src/vcdiff_main.cc
    154 vcdiff_LDADD = libvcddec.la libvcdenc.la libgflags.la
    155 
    156 check_PROGRAMS += addrcache_test
    157 addrcache_test_SOURCES = src/addrcache_test.cc
    158 addrcache_test_LDADD = libvcdcom.la libgtest_main.la
    159 
    160 check_PROGRAMS += blockhash_test
    161 blockhash_test_SOURCES = src/blockhash_test.cc
    162 blockhash_test_LDADD = libvcdenc.la libgtest_main.la
    163 
    164 check_PROGRAMS += codetable_test
    165 codetable_test_SOURCES = src/codetable_test.cc
    166 codetable_test_LDADD = libvcdcom.la libgtest_main.la
    167 
    168 check_PROGRAMS += decodetable_test
    169 decodetable_test_SOURCES = src/decodetable_test.cc
    170 decodetable_test_LDADD = libvcddec.la libvcdcom.la libgtest_main.la
    171 
    172 check_PROGRAMS += encodetable_test
    173 encodetable_test_SOURCES = src/encodetable_test.cc
    174 encodetable_test_LDADD = libvcdenc.la libvcdcom.la libgtest_main.la
    175 
    176 check_PROGRAMS += headerparser_test
    177 headerparser_test_SOURCES = src/headerparser_test.cc
    178 headerparser_test_LDADD = libvcddec.la libvcdcom.la libgtest_main.la
    179 
    180 check_PROGRAMS += instruction_map_test
    181 instruction_map_test_SOURCES = src/instruction_map_test.cc
    182 instruction_map_test_LDADD = libvcdenc.la libvcdcom.la libgtest_main.la
    183 
    184 check_PROGRAMS += output_string_test
    185 output_string_test_SOURCES = src/output_string_crope.h \
    186 			     src/output_string_test.cc
    187 output_string_test_LDADD = libgtest_main.la
    188 
    189 check_PROGRAMS += rolling_hash_test
    190 rolling_hash_test_SOURCES = src/rolling_hash_test.cc
    191 rolling_hash_test_LDADD = libvcdcom.la libgtest_main.la
    192 
    193 check_PROGRAMS += varint_bigendian_test
    194 varint_bigendian_test_SOURCES = src/varint_bigendian_test.cc
    195 varint_bigendian_test_LDADD = libvcdcom.la libgtest_main.la
    196 
    197 check_PROGRAMS += vcdecoder1_test
    198 vcdecoder1_test_SOURCES = src/vcdecoder1_test.cc
    199 vcdecoder1_test_LDADD = libvcdecoder_test_common.la
    200 
    201 check_PROGRAMS += vcdecoder2_test
    202 vcdecoder2_test_SOURCES = src/vcdecoder2_test.cc
    203 vcdecoder2_test_LDADD = libvcdecoder_test_common.la
    204 
    205 check_PROGRAMS += vcdecoder3_test
    206 vcdecoder3_test_SOURCES = src/vcdecoder3_test.cc
    207 vcdecoder3_test_LDADD = libvcdecoder_test_common.la
    208 
    209 check_PROGRAMS += vcdecoder4_test
    210 vcdecoder4_test_SOURCES = src/vcdecoder4_test.cc
    211 vcdecoder4_test_LDADD = libvcdecoder_test_common.la
    212 
    213 check_PROGRAMS += vcdecoder5_test
    214 vcdecoder5_test_SOURCES = src/vcdecoder5_test.cc
    215 vcdecoder5_test_LDADD = libvcdecoder_test_common.la
    216 
    217 check_PROGRAMS += vcdiffengine_test
    218 vcdiffengine_test_SOURCES = src/vcdiffengine_test.cc
    219 vcdiffengine_test_LDADD = libvcdenc.la libvcdcom.la libgtest_main.la
    220 
    221 check_PROGRAMS += vcencoder_test
    222 vcencoder_test_SOURCES = src/vcencoder_test.cc
    223 vcencoder_test_LDADD = libvcddec.la libvcdenc.la libvcdcom.la libgtest_main.la
    224 
    225 check_PROGRAMS += jsonwriter_test
    226 jsonwriter_test_SOURCES = src/jsonwriter_test.cc
    227 jsonwriter_test_LDADD = libvcdenc.la libvcdcom.la libgtest_main.la
    228 
    229 check_SCRIPTS += src/vcdiff_test.sh
    230 dist_noinst_DATA = testdata/configure.ac.v0.1 \
    231                    testdata/configure.ac.v0.2 \
    232                    testdata/allocates_4gb.vcdiff
    233 
    234 ## ^^^^ END OF RULES TO MAKE THE LIBRARIES, BINARIES, AND UNITTESTS
    235 
    236 TESTS = $(check_PROGRAMS) $(check_SCRIPTS)
    237 ## TESTS_ENVIRONMENT sets environment variables for when you run unit tests,
    238 ## but it only seems to take effect for *binary* unit tests (argh!)
    239 TESTS_ENVIRONMENT = SRCDIR="$(top_srcdir)"
    240 
    241 rpm: dist-gzip packages/rpm.sh packages/rpm/rpm.spec
    242 	@cd packages && ./rpm.sh ${PACKAGE} ${VERSION}
    243 
    244 deb: dist-gzip packages/deb.sh packages/deb/*
    245 	@cd packages && ./deb.sh ${PACKAGE} ${VERSION}
    246 
    247 libtool: $(LIBTOOL_DEPS)
    248 	$(SHELL) ./config.status --recheck
    249 
    250 EXTRA_DIST = $(check_SCRIPTS) \
    251 	     autogen.sh \
    252 	     gflags/src/windows/config.h \
    253 	     gflags/src/windows/gflags/gflags.h \
    254 	     gflags/src/windows/gflags/gflags_completions.h \
    255 	     gflags/src/windows/port.h \
    256 	     gflags/src/windows/port.cc \
    257 	     packages/rpm.sh \
    258 	     packages/rpm/rpm.spec \
    259 	     packages/deb.sh \
    260 	     packages/deb \
    261 	     src/solaris/libstdc++.la \
    262 	     testdata/empty_file.txt \
    263 	     vsprojects/config.h \
    264 	     vsprojects/stdint.h \
    265 	     vsprojects/vcdiff_test.bat \
    266 	     vsprojects/open-vcdiff.sln \
    267 	     vsprojects/addrcache_test/addrcache_test.vcproj \
    268 	     vsprojects/blockhash_test/blockhash_test.vcproj \
    269 	     vsprojects/codetable_test/codetable_test.vcproj \
    270 	     vsprojects/decodetable_test/decodetable_test.vcproj \
    271 	     vsprojects/encodetable_test/encodetable_test.vcproj \
    272 	     vsprojects/gtest/gtest.vcproj \
    273 	     vsprojects/headerparser_test/headerparser_test.vcproj \
    274 	     vsprojects/instruction_map_test/instruction_map_test.vcproj \
    275 	     vsprojects/jsonwriter_test/jsonwriter_test.vcproj \
    276 	     vsprojects/output_string_test/output_string_test.vcproj \
    277 	     vsprojects/rolling_hash_test/rolling_hash_test.vcproj \
    278 	     vsprojects/varint_bigendian_test/varint_bigendian_test.vcproj \
    279 	     vsprojects/vcdcom/vcdcom.vcproj \
    280 	     vsprojects/vcddec/vcddec.vcproj \
    281 	     vsprojects/vcdecoder_test_common/vcdecoder_test_common.vcproj \
    282 	     vsprojects/vcdecoder1_test/vcdecoder1_test.vcproj \
    283 	     vsprojects/vcdecoder2_test/vcdecoder2_test.vcproj \
    284 	     vsprojects/vcdecoder3_test/vcdecoder3_test.vcproj \
    285 	     vsprojects/vcdecoder4_test/vcdecoder4_test.vcproj \
    286 	     vsprojects/vcdecoder5_test/vcdecoder5_test.vcproj \
    287 	     vsprojects/vcdenc/vcdenc.vcproj \
    288 	     vsprojects/vcdiff/vcdiff.vcproj \
    289 	     vsprojects/vcdiffengine_test/vcdiffengine_test.vcproj \
    290 	     vsprojects/vcdiff_test/vcdiff_test.vcproj \
    291 	     vsprojects/vcencoder_test/vcencoder_test.vcproj
    292