Makefile.am 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642
  1. # Libraries
  2. # Provide the full test output for failed tests when using the parallel
  3. # test suite (which is enabled by default with automake 1.13+).
  4. export VERBOSE = yes
  5. lib_LTLIBRARIES = src/libdaalabase.la src/libdaaladec.la src/libdaalaenc.la
  6. AM_CPPFLAGS = -I$(srcdir)/include
  7. noinst_HEADERS = \
  8. src/adapt.h \
  9. src/block_size.h \
  10. src/block_size_dec.h \
  11. src/block_size_enc.h \
  12. src/dct.h \
  13. src/decint.h \
  14. src/encint.h \
  15. src/entcode.h \
  16. src/entdec.h \
  17. src/entenc.h \
  18. src/filter.h \
  19. src/generic_code.h \
  20. src/internal.h \
  21. src/intra.h \
  22. src/intra_paint.h \
  23. src/laplace_code.h \
  24. src/logging.h \
  25. src/mc.h \
  26. src/mcenc.h \
  27. src/odintrin.h \
  28. src/partition.h \
  29. src/pvq.h \
  30. src/pvq_code.h \
  31. src/state.h \
  32. src/tf.h \
  33. src/zigzag.h \
  34. src/accounting.h \
  35. src/x86/cpu.h \
  36. src/x86/x86enc.h \
  37. src/x86/x86dct.h \
  38. src/x86/x86int.h
  39. src_dct_SOURCES = src/dct.c src/internal.c
  40. if ENABLE_X86ASM
  41. src_dct_SOURCES += src/x86/cpu.c
  42. if ENABLE_SSE2_INTRINSICS
  43. src_dct_SOURCES += src/x86/sse2dct.c
  44. %sse2dct.o %sse2dct.lo: CFLAGS += -msse2
  45. endif
  46. if ENABLE_SSE41_INTRINSICS
  47. src_dct_SOURCES += src/x86/sse41dct.c
  48. %sse41dct.o %sse41dct.lo: CFLAGS += -msse4.1
  49. endif
  50. if ENABLE_AVX2_INTRINSICS
  51. src_dct_SOURCES += src/x86/avx2dct.c
  52. %avx2dct.o %avx2dct.lo: CFLAGS += -mavx2
  53. endif
  54. endif
  55. src_libdaalabase_la_CFLAGS = $(OGG_CFLAGS)
  56. src_libdaalabase_la_LIBADD = $(OGG_LIBS) $(LIBM)
  57. if DUMP_IMAGES
  58. src_libdaalabase_la_LIBADD += $(PNG_LIBS)
  59. endif
  60. src_libdaalabase_la_LDFLAGS = -no-undefined \
  61. -version-info @OD_LT_CURRENT@:@OD_LT_REVISION@:@OD_LT_AGE@
  62. src_libdaalabase_la_LDFLAGS +=
  63. src_libdaalabase_la_SOURCES = \
  64. src/adapt.c \
  65. src/block_size.c \
  66. src/entcode.c \
  67. src/entdec.c \
  68. src/filter.c \
  69. src/generic_code.c \
  70. src/generic_decoder.c \
  71. src/info.c \
  72. src/intra.c \
  73. src/intra_paint.c \
  74. src/laplace_decoder.c \
  75. src/laplace_tables.c \
  76. src/logging.c \
  77. src/mc.c \
  78. src/partition.c \
  79. src/pvq.c \
  80. src/pvq_code.c \
  81. src/pvq_decoder.c \
  82. src/state.c \
  83. src/switch_table.c \
  84. src/tf.c \
  85. src/zigzag4.c \
  86. src/zigzag8.c \
  87. src/zigzag16.c \
  88. src/zigzag32.c \
  89. $(src_dct_SOURCES)
  90. if ENABLE_X86ASM
  91. src_libdaalabase_la_SOURCES += \
  92. src/x86/sse2mc.c \
  93. src/x86/x86state.c
  94. endif
  95. src_libdaaladec_la_CFLAGS = $(OGG_CFLAGS)
  96. src_libdaaladec_la_LIBADD = src/libdaalabase.la $(OGG_LIBS) $(LIBM)
  97. src_libdaaladec_la_LDFLAGS = -no-undefined \
  98. -version-info @OD_LT_CURRENT@:@OD_LT_REVISION@:@OD_LT_AGE@
  99. src_libdaaladec_la_SOURCES = \
  100. src/block_size_dec.c \
  101. src/decode.c \
  102. src/intra_paint_dec.c \
  103. src/infodec.c
  104. src_libdaalaenc_la_CFLAGS = $(OGG_CFLAGS)
  105. src_libdaalaenc_la_LIBADD = src/libdaalabase.la $(OGG_LIBS) $(LIBM)
  106. if ENCODER_CHECK
  107. src_libdaalaenc_la_LIBADD += src/libdaaladec.la
  108. endif
  109. src_libdaalaenc_la_LDFLAGS = -no-undefined \
  110. -version-info @OD_LT_CURRENT@:@OD_LT_REVISION@:@OD_LT_AGE@
  111. src_libdaalaenc_la_SOURCES = \
  112. src/block_size_dec.c \
  113. src/block_size_enc.c \
  114. src/encode.c \
  115. src/entenc.c \
  116. src/generic_encoder.c \
  117. src/infoenc.c \
  118. src/laplace_encoder.c \
  119. src/mcenc.c \
  120. src/accounting.c \
  121. src/intra_paint_enc.c \
  122. src/pvq_encoder.c
  123. if ENABLE_X86ASM
  124. src_libdaalaenc_la_SOURCES += \
  125. src/x86/x86enc.c \
  126. src/x86/x86mcenc.c
  127. endif
  128. # Example programs
  129. noinst_PROGRAMS = \
  130. examples/dump_video \
  131. examples/encoder_example
  132. if ENABLE_PLAYER_EXAMPLE
  133. noinst_PROGRAMS += examples/player_example
  134. endif
  135. if ENABLE_ANALYZER
  136. noinst_PROGRAMS += examples/analyzer
  137. endif
  138. examples_dump_video_SOURCES = examples/dump_video.c
  139. examples_dump_video_CFLAGS = $(OGG_CFLAGS)
  140. examples_dump_video_LDADD = src/libdaalabase.la src/libdaaladec.la $(OGG_LIBS)
  141. examples_encoder_example_SOURCES = examples/encoder_example.c
  142. examples_encoder_example_CFLAGS = $(OGG_CFLAGS)
  143. examples_encoder_example_LDADD = src/libdaalabase.la src/libdaalaenc.la $(OGG_LIBS) $(LIBM)
  144. if ENABLE_PLAYER_EXAMPLE
  145. examples_player_example_SOURCES = examples/player_example.c
  146. examples_player_example_CFLAGS = $(OGG_CFLAGS) $(SDL_CFLAGS)
  147. examples_player_example_LDADD = src/libdaalabase.la src/libdaaladec.la $(OGG_LIBS) $(SDL_LIBS)
  148. endif
  149. if ENABLE_ANALYZER
  150. examples_analyzer_SOURCES = examples/analyzer.cc
  151. examples_analyzer_CXXFLAGS = $(OGG_CFLAGS) $(WX_CPPFLAGS)
  152. examples_analyzer_LDADD = src/libdaalabase.la src/libdaaladec.la $(OGG_LIBS) $(WX_LIBS)
  153. endif
  154. # Includes
  155. daalaincludedir = $(includedir)/daala
  156. daalainclude_HEADERS = \
  157. include/daala/codec.h \
  158. include/daala/daaladec.h \
  159. include/daala/daalaenc.h
  160. # Tools
  161. CLEANFILES =
  162. EXTRA_PROGRAMS =
  163. if ENABLE_TOOLS
  164. tools_TARGETS = \
  165. tools/png2y4m \
  166. tools/tiff2y4m \
  167. tools/y4m2png \
  168. tools/y4m2tiff \
  169. tools/dump_psnrhvs \
  170. tools/block_size_analysis \
  171. tools/to_monochrome \
  172. tools/downsample \
  173. tools/upsample \
  174. tools/divu_const \
  175. tools/trans \
  176. tools/trans2d \
  177. tools/trans_gain \
  178. tools/gen_cdf \
  179. tools/compute_basis \
  180. tools/gen_laplace_tables \
  181. tools/dump_ssim \
  182. tools/dump_fastssim \
  183. tools/bjontegaard \
  184. tools/yuvjpeg \
  185. tools/jpegyuv \
  186. tools/yuv2yuv4mpeg \
  187. tools/dump_psnr \
  188. tools/vq_train
  189. noinst_HEADERS += \
  190. tools/cholesky.h \
  191. tools/int_search.h \
  192. tools/kiss99.h \
  193. tools/matidx.h \
  194. tools/od_defs.h \
  195. tools/od_filter.h \
  196. tools/pythag.h \
  197. tools/svd.h \
  198. tools/trans_tools.h \
  199. tools/vidinput.h
  200. EXTRA_PROGRAMS += $(tools_TARGETS)
  201. CLEANFILES += $(tools_TARGETS)
  202. # png2y4m
  203. tools_png2y4m_SOURCES = \
  204. tools/kiss99.c \
  205. tools/png2y4m.c
  206. tools_png2y4m_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  207. tools_png2y4m_LDADD = $(OGG_LIBS) $(PNG_LIBS)
  208. # tiff2y4m
  209. tools_tiff2y4m_SOURCES = \
  210. tools/kiss99.c \
  211. tools/tiff2y4m.c
  212. tools_tiff2y4m_CFLAGS = $(OGG_CFLAGS) $(TIFF_CFLAGS)
  213. tools_tiff2y4m_LDADD = $(OGG_LIBS) $(TIFF_LIBS)
  214. # y4m2png
  215. tools_y4m2png_SOURCES = \
  216. tools/vidinput.c \
  217. tools/y4m_input.c \
  218. tools/y4m2png.c
  219. tools_y4m2png_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  220. tools_y4m2png_LDADD = $(OGG_LIBS) $(PNG_LIBS)
  221. # y4m2tiff
  222. tools_y4m2tiff_SOURCES = \
  223. tools/vidinput.c \
  224. tools/y4m_input.c \
  225. tools/y4m2tiff.c
  226. tools_y4m2tiff_CFLAGS = $(OGG_CFLAGS) $(TIFF_CFLAGS)
  227. tools_y4m2tiff_LDADD = $(OGG_LIBS) $(TIFF_LIBS)
  228. # dump_psnrhvs
  229. tools_dump_psnrhvs_SOURCES = \
  230. tools/vidinput.c \
  231. tools/y4m_input.c \
  232. $(src_dct_SOURCES) \
  233. tools/dump_psnrhvs.c
  234. tools_dump_psnrhvs_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  235. tools_dump_psnrhvs_LDADD = $(OGG_LIBS) $(LIBM)
  236. # dump_ssim
  237. tools_dump_ssim_SOURCES = \
  238. tools/vidinput.c \
  239. tools/y4m_input.c \
  240. tools/dump_ssim.c
  241. tools_dump_ssim_CFLAGS = $(OGG_CFLAGS)
  242. tools_dump_ssim_LDADD = $(OGG_LIBS) $(LIBM)
  243. # dump_fastssim
  244. tools_dump_fastssim_SOURCES = \
  245. tools/vidinput.c \
  246. tools/y4m_input.c \
  247. tools/dump_fastssim.c
  248. tools_dump_fastssim_CFLAGS = $(OGG_CFLAGS)
  249. tools_dump_fastssim_LDADD = $(OGG_LIBS) $(LIBM)
  250. # dump_psnr
  251. tools_dump_psnr_SOURCES = \
  252. tools/vidinput.c \
  253. tools/y4m_input.c \
  254. tools/dump_psnr.c
  255. tools_dump_psnr_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  256. tools_dump_psnr_LDADD = $(OGG_LIBS) $(LIBM)
  257. # block_size_analysis
  258. tools_block_size_analysis_SOURCES = \
  259. tools/block_size_analysis.c \
  260. src/block_size.c \
  261. src/block_size_enc.c \
  262. tools/vidinput.c \
  263. tools/y4m_input.c \
  264. $(src_dct_SOURCES) \
  265. src/generic_encoder.c \
  266. src/generic_code.c \
  267. src/laplace_encoder.c \
  268. src/logging.c \
  269. src/laplace_tables.c \
  270. src/entcode.c \
  271. src/entenc.c \
  272. src/filter.c \
  273. src/switch_table.c
  274. tools_block_size_analysis_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  275. tools_block_size_analysis_LDADD = $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  276. # to_monochrome
  277. tools_to_monochrome_SOURCES = \
  278. tools/vidinput.c \
  279. tools/y4m_input.c \
  280. tools/to_monochrome.c
  281. tools_to_monochrome_CFLAGS = $(THEORA_CFLAGS) $(OGG_CFLAGS) $(PNG_CFLAGS)
  282. tools_to_monochrome_LDADD = $(THEORA_LIBS) $(OGG_LIBS) $(PNG_LIBS)
  283. # downsample
  284. tools_downsample_SOURCES = \
  285. tools/vidinput.c \
  286. tools/y4m_input.c \
  287. tools/downsample.c
  288. tools_downsample_CFLAGS = $(THEORA_CFLAGS) $(OGG_CFLAGS) $(PNG_CFLAGS)
  289. tools_downsample_LDADD = $(THEORA_LIBS) $(OGG_LIBS) $(PNG_LIBS)
  290. # upsample
  291. tools_upsample_SOURCES = \
  292. $(src_dct_SOURCES) \
  293. src/generic_code.c \
  294. src/switch_table.c \
  295. src/logging.c \
  296. src/info.c \
  297. src/mc.c \
  298. src/pvq.c \
  299. src/state.c \
  300. tools/vidinput.c \
  301. tools/y4m_input.c \
  302. tools/upsample.c
  303. if ENABLE_X86ASM
  304. tools_upsample_SOURCES += \
  305. src/x86/sse2mc.c \
  306. src/x86/x86state.c
  307. endif
  308. tools_upsample_CFLAGS = $(THEORA_CFLAGS) $(OGG_CFLAGS) $(PNG_CFLAGS)
  309. tools_upsample_LDADD = $(THEORA_LIBS) $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  310. # divu_const
  311. tools_divu_const_SOURCES = \
  312. tools/divu_const.c
  313. tools_divu_const_CFLAGS = $(OGG_CFLAGS)
  314. tools_divu_const_LDADD = $(OGG_LIBS) $(LIBM)
  315. # trans
  316. tools_trans_SOURCES = \
  317. tools/trans.c \
  318. tools/vidinput.c \
  319. tools/y4m_input.c \
  320. tools/od_filter.c \
  321. tools/trans_tools.c \
  322. tools/int_search.c \
  323. tools/trans_data.c \
  324. tools/kiss99.c \
  325. tools/svd.c \
  326. tools/cholesky.c \
  327. src/filter.c \
  328. $(src_dct_SOURCES)
  329. tools_trans_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS) $(OPENMP_CFLAGS)
  330. tools_trans_LDADD = $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  331. # trans_gain
  332. tools_trans_gain_SOURCES = \
  333. tools/trans_gain.c \
  334. tools/vidinput.c \
  335. tools/y4m_input.c \
  336. tools/od_filter.c \
  337. tools/trans_tools.c \
  338. src/filter.c \
  339. $(src_dct_SOURCES)
  340. tools_trans_gain_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS) $(OPENMP_CFLAGS)
  341. tools_trans_gain_LDADD = $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  342. #trans2d
  343. tools_trans2d_SOURCES = \
  344. tools/trans2d.c \
  345. tools/vidinput.c \
  346. tools/y4m_input.c \
  347. tools/od_filter.c \
  348. tools/trans_tools.c \
  349. tools/int_search.c \
  350. tools/trans_data.c \
  351. tools/kiss99.c \
  352. tools/svd.c \
  353. tools/cholesky.c \
  354. src/filter.c \
  355. $(src_dct_SOURCES)
  356. tools_trans2d_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS) $(OPENMP_CFLAGS)
  357. tools_trans2d_LDADD = $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  358. # gen_cdf
  359. tools_gen_cdf_SOURCES = \
  360. tools/gen_cdf.c
  361. tools_gen_cdf_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  362. tools_gen_cdf_LDADD = $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  363. # compute_basis
  364. tools_compute_basis_SOURCES = \
  365. tools/compute_basis.c \
  366. src/dct.c \
  367. src/filter.c \
  368. src/internal.c
  369. tools_compute_basis_CFLAGS = $(OGG_CFLAGS)
  370. tools_compute_basis_LDADD = $(OGG_LIBS) $(LIBM)
  371. # gen_laplace_tables
  372. tools_gen_laplace_tables_SOURCES = \
  373. tools/gen_laplace_tables.c
  374. tools_gen_laplace_tables_CFLAGS = $(OGG_CFLAGS) $(PNG_CFLAGS)
  375. tools_gen_laplace_tables_LDADD = $(OGG_LIBS) $(PNG_LIBS) $(LIBM)
  376. # bjontegaard
  377. tools_bjontegaard_SOURCES = \
  378. tools/bjontegaard.c \
  379. tools/cholesky.c \
  380. tools/qr.c \
  381. tools/svd.c
  382. tools_bjontegaard_CFLAGS =
  383. tools_bjontegaard_LDADD = $(LIBM)
  384. # yuvjpeg
  385. tools_yuvjpeg_SOURCES = \
  386. tools/yuvjpeg.c
  387. tools_yuvjpeg_CFLAGS =
  388. tools_yuvjpeg_LDADD = $(JPEG_LIBS)
  389. # jpegyuv
  390. tools_jpegyuv_SOURCES = \
  391. tools/jpegyuv.c
  392. tools_jpegyuv_CFLAGS =
  393. tools_jpegyuv_LDADD = $(JPEG_LIBS)
  394. # yuv2yuv4mpeg
  395. tools_yuv2yuv4mpeg_SOURCES = \
  396. tools/yuv2yuv4mpeg.c
  397. tools_yuv2yuv4mpeg_CFLAGS =
  398. tools_yuv2yuv4mpeg_LDADD =
  399. # vq_train
  400. tools_vq_train_SOURCES = \
  401. tools/vq_train.c
  402. tools_vq_train_CFLAGS = $(OPENMP_CFLAGS)
  403. tools_vq_train_LDADD = $(LIBM)
  404. endif # ENABLE_TOOLS
  405. # Tests
  406. if ENABLE_UNIT_TESTS
  407. noinst_PROGRAMS += \
  408. src/tests/dcttest \
  409. src/tests/test_32x32 \
  410. src/tests/ectest \
  411. src/tests/test_coef_coder \
  412. src/tests/logging_test \
  413. src/tests/test_divu_small \
  414. src/tests/test_filters \
  415. src/tests/check_tests
  416. TESTS = \
  417. src/tests/dcttest \
  418. src/tests/test_32x32 \
  419. src/tests/ectest \
  420. src/tests/test_coef_coder \
  421. src/tests/logging_test \
  422. src/tests/test_divu_small \
  423. src/tests/test_filters \
  424. src/tests/check_tests
  425. src_tests_dcttest_SOURCES = $(src_dct_SOURCES) src/filter.c
  426. src_tests_dcttest_CFLAGS = $(OGG_CFLAGS) \
  427. -DOD_DCT_CHECK_OVERFLOW -DOD_DCT_TEST -DOD_ENABLE_ASSERTIONS
  428. src_tests_dcttest_LDADD = $(LIBM)
  429. src_tests_test_32x32_SOURCES = src/tests/test_32x32.c
  430. src_tests_test_32x32_CFLAGS = $(OGG_CFLAGS) -D_GNU_SOURCE
  431. src_tests_test_32x32_LDADD = $(LIBM)
  432. src_tests_ectest_SOURCES = src/tests/ectest.c
  433. src_tests_ectest_CFLAGS = $(OGG_CFLAGS)
  434. src_tests_ectest_LDADD = \
  435. src/libdaalaenc.la \
  436. $(LIBM)
  437. src_tests_test_coef_coder_SOURCES = src/tests/test_coef_coder.c
  438. src_tests_test_coef_coder_CFLAGS = $(OGG_CFLAGS)
  439. src_tests_test_coef_coder_LDADD = \
  440. src/libdaalabase.la \
  441. src/libdaaladec.la \
  442. src/libdaalaenc.la \
  443. $(OGG_LIBS) \
  444. $(LIBM)
  445. src_tests_logging_test_SOURCES = src/tests/logging_test.c
  446. src_tests_logging_test_CFLAGS = $(OGG_CFLAGS)
  447. src_tests_logging_test_LDADD = \
  448. src/libdaalabase.la \
  449. src/libdaalaenc.la \
  450. $(OGG_LIBS)
  451. src_tests_test_divu_small_SOURCES = src/tests/test_divu_small.c
  452. src_tests_test_divu_small_CFLAGS = $(OGG_CFLAGS)
  453. src_tests_test_divu_small_LDADD = \
  454. src/libdaalabase.la \
  455. $(OGG_LIBS)
  456. src_tests_test_filters_SOURCES = src/tests/test_filters.c
  457. src_tests_test_filters_CFLAGS = $(OGG_CFLAGS)
  458. src_tests_test_filters_LDADD = \
  459. src/libdaalabase.la \
  460. $(OGG_LIBS)
  461. src_tests_check_tests_SOURCES = \
  462. src/tests/check_main.c \
  463. src/tests/headerencode_test.c
  464. src_tests_check_tests_CFLAGS = $(OGG_CFLAGS) $(CHECK_CFLAGS) -Wno-variadic-macros
  465. src_tests_check_tests_LDADD = \
  466. src/libdaalabase.la \
  467. src/libdaaladec.la \
  468. src/libdaalaenc.la \
  469. $(OGG_LIBS) \
  470. $(CHECK_LIBS) \
  471. $(LIBM)
  472. endif
  473. SUBDIRS=doc
  474. ACLOCAL_AMFLAGS = -I m4
  475. AM_CFLAGS = -I$(top_srcdir)/include $(DEPS_CFLAGS)
  476. dist_doc_DATA = COPYING AUTHORS
  477. pkgconfigdir = $(libdir)/pkgconfig
  478. pkgconfig_DATA = daalaenc.pc daaladec.pc
  479. debug: DEBUG_OPTIONS = -DOD_ENABLE_ASSERTIONS -DOD_LOGGING_ENABLED
  480. debug:
  481. $(MAKE) CFLAGS="$(CFLAGS) -O0 -ggdb3 $(DEBUG_OPTIONS)" all
  482. EXTRA_DIST = \
  483. daalaenc.pc.in \
  484. daaladec.pc.in \
  485. daalaenc-uninstalled.pc.in \
  486. daaladec-uninstalled.pc.in \
  487. tools/unix/Makefile \
  488. unix/Makefile
  489. # Targets to build and install just the library without the docs
  490. daala install-daala: NO_DOXYGEN = 1
  491. daala: all
  492. install-daala: install
  493. if ENABLE_TOOLS
  494. tools: $(tools_TARGETS)
  495. else
  496. tools:
  497. @echo "error: Tools support not enabled. Try running 'configure --enable-tools'."
  498. endif
  499. # Or just the docs
  500. docs: doc/doxygen-build.stamp
  501. install-docs:
  502. @if [ -z "$(NO_DOXYGEN)" ]; then \
  503. ( cd doc && \
  504. echo "Installing documentation in $(DESTDIR)$(docdir)"; \
  505. $(INSTALL) -d $(DESTDIR)$(docdir)/html/search; \
  506. for f in `find html -type f \! -name "installdox"` ; do \
  507. $(INSTALL_DATA) $$f $(DESTDIR)$(docdir)/$$f; \
  508. done ) \
  509. fi
  510. doc/doxygen-build.stamp: doc/Doxyfile $(daalainclude_HEADERS)
  511. @[ -n "$(NO_DOXYGEN)" ] || ( cd doc && doxygen && touch $(@F) )
  512. if HAVE_DOXYGEN
  513. # Or everything (by default)
  514. all-local: docs
  515. install-data-local: install-docs
  516. clean-local:
  517. $(RM) -r doc/html
  518. $(RM) -r doc/latex
  519. $(RM) -r doc/man
  520. $(RM) doc/doxygen-build.stamp
  521. $(RM) doc/doxygen_sqlite3.db
  522. uninstall-local:
  523. $(RM) -r $(DESTDIR)$(docdir)/html
  524. endif
  525. # We check this every time make is run, with configure.ac being touched to
  526. # trigger an update of the build system files if update_version changes the
  527. # current PACKAGE_VERSION (or if package_version was modified manually by a
  528. # user with either AUTO_UPDATE=no or no update_version script present - the
  529. # latter being the normal case for tarball releases).
  530. #
  531. # We can't just add the package_version file to CONFIGURE_DEPENDENCIES since
  532. # simply running autoconf will not actually regenerate configure for us when
  533. # the content of that file changes (due to autoconf dependency checking not
  534. # knowing about that without us creating yet another file for it to include).
  535. #
  536. # The MAKECMDGOALS check is a gnu-make'ism, but will degrade 'gracefully' for
  537. # makes that don't support it. The only loss of functionality is not forcing
  538. # an update of package_version for `make dist` if AUTO_UPDATE=no, but that is
  539. # unlikely to be a real problem for any real user.
  540. $(top_srcdir)/configure.ac: force
  541. @case "$(MAKECMDGOALS)" in \
  542. dist-hook) exit 0 ;; \
  543. dist-* | dist | distcheck | distclean) _arg=release ;; \
  544. esac; \
  545. if ! $(top_srcdir)/update_version $$_arg 2> /dev/null; then \
  546. if [ ! -e $(top_srcdir)/package_version ]; then \
  547. echo 'PACKAGE_VERSION="unknown"' > $(top_srcdir)/package_version; \
  548. fi; \
  549. . $(top_srcdir)/package_version || exit 1; \
  550. [ "$(PACKAGE_VERSION)" != "$$PACKAGE_VERSION" ] || exit 0; \
  551. fi; \
  552. touch $@
  553. force:
  554. # Create a minimal package_version file when make dist is run.
  555. dist-hook:
  556. echo 'PACKAGE_VERSION="$(PACKAGE_VERSION)"' > $(top_distdir)/package_version
  557. .PHONY: daala install-daala docs install-docs figures tools