1# $FreeBSD$ 2 3LIB= lzma 4LZMADIR= ${.CURDIR}/../../contrib/xz/src/liblzma 5 6.PATH: ${LZMADIR}/../common 7SRCS+= tuklib_physmem.c 8 9.PATH: ${LZMADIR}/api/lzma 10 11MAININCS= ../lzma.h 12MAININCSDIR= ${INCLUDEDIR} 13 14LZMAINCS+= base.h \ 15 bcj.h \ 16 block.h \ 17 check.h \ 18 container.h \ 19 delta.h \ 20 filter.h \ 21 hardware.h \ 22 index.h \ 23 index_hash.h \ 24 lzma.h \ 25 stream_flags.h \ 26 subblock.h \ 27 version.h \ 28 vli.h 29 30LZMAINCSDIR= ${INCLUDEDIR}/lzma 31 32INCSGROUPS= MAININCS LZMAINCS 33 34.PATH: ${LZMADIR}/common 35SRCS+= common.c \ 36 block_util.c \ 37 easy_preset.c \ 38 filter_common.c \ 39 hardware_physmem.c \ 40 index.c \ 41 stream_flags_common.c \ 42 vli_size.c \ 43 alone_encoder.c \ 44 block_buffer_encoder.c \ 45 block_encoder.c \ 46 block_header_encoder.c \ 47 easy_buffer_encoder.c \ 48 easy_encoder.c \ 49 easy_encoder_memusage.c \ 50 filter_buffer_encoder.c \ 51 filter_encoder.c \ 52 filter_flags_encoder.c \ 53 index_encoder.c \ 54 stream_buffer_encoder.c \ 55 stream_encoder.c \ 56 stream_flags_encoder.c \ 57 vli_encoder.c \ 58 alone_decoder.c \ 59 auto_decoder.c \ 60 block_buffer_decoder.c \ 61 block_decoder.c \ 62 block_header_decoder.c \ 63 easy_decoder_memusage.c \ 64 filter_buffer_decoder.c \ 65 filter_decoder.c \ 66 filter_flags_decoder.c \ 67 index_decoder.c \ 68 index_hash.c \ 69 stream_buffer_decoder.c \ 70 stream_decoder.c \ 71 stream_flags_decoder.c \ 72 vli_decoder.c 73 74.PATH: ${LZMADIR}/check 75SRCS+= check.c \ 76 crc32_table.c \ 77 crc64_table.c \ 78 sha256.c 79.if defined(MACHINE_ARCH) && ${MACHINE_ARCH} == "i386" 80SRCS+= crc32_x86.S \ 81 crc64_x86.S 82.else 83SRCS+= crc32_fast.c \ 84 crc64_fast.c 85.endif 86 87.PATH: ${LZMADIR}/lz 88SRCS+= lz_encoder.c \ 89 lz_encoder_mf.c \ 90 lz_decoder.c 91 92.PATH: ${LZMADIR}/lzma 93SRCS+= lzma_encoder.c \ 94 lzma_encoder_presets.c \ 95 lzma_encoder_optimum_fast.c \ 96 lzma_encoder_optimum_normal.c \ 97 fastpos_table.c \ 98 lzma_decoder.c \ 99 lzma2_encoder.c \ 100 lzma2_decoder.c 101 102.PATH: ${LZMADIR}/rangecoder 103SRCS+= price_table.c 104 105.PATH: ${LZMADIR}/delta 106SRCS+= delta_common.c \ 107 delta_encoder.c \ 108 delta_decoder.c 109 110.PATH: ${LZMADIR}/simple 111SRCS+= simple_coder.c \ 112 simple_encoder.c \ 113 simple_decoder.c \ 114 x86.c \ 115 powerpc.c \ 116 ia64.c \ 117 arm.c \ 118 armthumb.c \ 119 sparc.c 120 121WARNS?= 3 122 123CFLAGS+= -DHAVE_CONFIG_H \ 124 -DTUKLIB_SYMBOL_PREFIX=lzma_ \ 125 -I${.CURDIR} \ 126 -I${LZMADIR}/api \ 127 -I${LZMADIR}/common \ 128 -I${LZMADIR}/check \ 129 -I${LZMADIR}/lz \ 130 -I${LZMADIR}/rangecoder \ 131 -I${LZMADIR}/lzma \ 132 -I${LZMADIR}/subblock \ 133 -I${LZMADIR}/delta \ 134 -I${LZMADIR}/simple \ 135 -I${LZMADIR}/../common 136 137VERSION_DEF= ${.CURDIR}/Versions.def 138SYMBOL_MAPS= ${.CURDIR}/Symbol.map 139CFLAGS+= -DSYMBOL_VERSIONING 140 141.include <bsd.lib.mk> 142