DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 1 | lib_LTLIBRARIES = libjpeg.la libturbojpeg.la |
DRC | a1e9878 | 2010-01-28 22:18:41 +0000 | [diff] [blame] | 2 | libjpeg_la_LDFLAGS = -version-number 62:0:0 -no-undefined |
DRC | 21d6683 | 2010-02-12 04:34:41 +0000 | [diff] [blame] | 3 | libturbojpeg_la_LDFLAGS = -avoid-version -no-undefined |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 4 | include_HEADERS = jerror.h jmorecfg.h jpeglib.h turbojpeg.h |
| 5 | nodist_include_HEADERS = jconfig.h |
DRC | 0c0f304 | 2010-01-28 05:34:53 +0000 | [diff] [blame] | 6 | |
Adam Tkac | da5a1fe | 2008-10-22 11:19:25 +0000 | [diff] [blame] | 7 | HDRS = jchuff.h jdct.h jdhuff.h jerror.h jinclude.h jmemsys.h jmorecfg.h \ |
DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 8 | jpegint.h jpeglib.h jversion.h jsimd.h jsimddct.h |
Constantin Kaplinsky | 0ca4425 | 2008-09-28 05:08:48 +0000 | [diff] [blame] | 9 | |
| 10 | libjpeg_la_SOURCES = $(HDRS) jcapimin.c jcapistd.c jccoefct.c jccolor.c \ |
| 11 | jcdctmgr.c jchuff.c jcinit.c jcmainct.c jcmarker.c jcmaster.c \ |
| 12 | jcomapi.c jcparam.c jcphuff.c jcprepct.c jcsample.c jctrans.c \ |
| 13 | jdapimin.c jdapistd.c jdatadst.c jdatasrc.c jdcoefct.c jdcolor.c \ |
| 14 | jddctmgr.c jdhuff.c jdinput.c jdmainct.c jdmarker.c jdmaster.c \ |
| 15 | jdmerge.c jdphuff.c jdpostct.c jdsample.c jdtrans.c jerror.c \ |
| 16 | jfdctflt.c jfdctfst.c jfdctint.c jidctflt.c jidctfst.c jidctint.c \ |
Pierre Ossman | ba82ddf | 2009-06-29 11:20:42 +0000 | [diff] [blame] | 17 | jidctred.c jquant1.c jquant2.c jutils.c jmemmgr.c jmemnobs.c |
Constantin Kaplinsky | 0ca4425 | 2008-09-28 05:08:48 +0000 | [diff] [blame] | 18 | |
DRC | 6f8c668 | 2010-02-16 05:03:51 +0000 | [diff] [blame] | 19 | libturbojpeg_la_SOURCES = $(libjpeg_la_SOURCES) turbojpegl.c turbojpeg.h \ |
| 20 | turbojpeg-mapfile |
| 21 | |
| 22 | if VERSION_SCRIPT |
| 23 | |
DRC | d86e4d9 | 2010-02-16 22:40:26 +0000 | [diff] [blame] | 24 | libturbojpeg_la_LDFLAGS += $(VERSION_SCRIPT_FLAG)$(srcdir)/turbojpeg-mapfile |
DRC | 6f8c668 | 2010-02-16 05:03:51 +0000 | [diff] [blame] | 25 | |
| 26 | endif |
DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 27 | |
DRC | 60cddeb | 2010-02-12 05:37:07 +0000 | [diff] [blame] | 28 | if WITH_SIMD |
| 29 | |
Pierre Ossman | 3a65ef4 | 2009-03-16 13:34:18 +0000 | [diff] [blame] | 30 | SUBDIRS = simd |
| 31 | libjpeg_la_LIBADD = simd/libsimd.la |
DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 32 | libturbojpeg_la_LIBADD = simd/libsimd.la |
Pierre Ossman | 2ae181c | 2009-03-09 13:21:27 +0000 | [diff] [blame] | 33 | |
DRC | 60cddeb | 2010-02-12 05:37:07 +0000 | [diff] [blame] | 34 | else |
| 35 | |
| 36 | libjpeg_la_SOURCES += jsimd_none.c |
| 37 | |
| 38 | endif |
| 39 | |
DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 40 | TSTHDRS = rrutil.h rrtimer.h |
DRC | 2e7b76b | 2009-04-03 12:04:24 +0000 | [diff] [blame] | 41 | |
DRC | 8e2bba9 | 2010-06-04 23:54:10 +0000 | [diff] [blame] | 42 | bin_PROGRAMS = cjpeg djpeg jpegtran rdjpgcom wrjpgcom |
| 43 | noinst_PROGRAMS = jpgtest jpegut |
DRC | 2e7b76b | 2009-04-03 12:04:24 +0000 | [diff] [blame] | 44 | |
DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 45 | jpgtest_SOURCES = $(TSTHDRS) jpgtest.cxx bmp.h bmp.c |
DRC | 2e7b76b | 2009-04-03 12:04:24 +0000 | [diff] [blame] | 46 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 47 | jpgtest_LDADD = libturbojpeg.la |
DRC | 2e7b76b | 2009-04-03 12:04:24 +0000 | [diff] [blame] | 48 | |
DRC | 1bf1a14 | 2010-02-11 06:39:32 +0000 | [diff] [blame] | 49 | jpegut_SOURCES = $(TSTHDRS) jpegut.c bmp.h bmp.c |
DRC | 2e7b76b | 2009-04-03 12:04:24 +0000 | [diff] [blame] | 50 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 51 | jpegut_LDADD = libturbojpeg.la |
DRC | 73de982 | 2009-06-25 20:41:17 +0000 | [diff] [blame] | 52 | |
| 53 | cjpeg_SOURCES = cdjpeg.h cderror.h cdjpeg.c cjpeg.c rdbmp.c rdgif.c \ |
| 54 | rdppm.c rdswitch.c rdtarga.c |
| 55 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 56 | cjpeg_LDADD = libjpeg.la |
DRC | 73de982 | 2009-06-25 20:41:17 +0000 | [diff] [blame] | 57 | |
| 58 | cjpeg_CFLAGS = -DBMP_SUPPORTED -DGIF_SUPPORTED -DPPM_SUPPORTED \ |
| 59 | -DTARGA_SUPPORTED |
| 60 | |
| 61 | djpeg_SOURCES = cdjpeg.h cderror.h cdjpeg.c djpeg.c rdcolmap.c rdswitch.c \ |
| 62 | wrbmp.c wrgif.c wrppm.c wrtarga.c |
| 63 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 64 | djpeg_LDADD = libjpeg.la |
DRC | 73de982 | 2009-06-25 20:41:17 +0000 | [diff] [blame] | 65 | |
| 66 | djpeg_CFLAGS = -DBMP_SUPPORTED -DGIF_SUPPORTED -DPPM_SUPPORTED \ |
| 67 | -DTARGA_SUPPORTED |
DRC | 60fa060 | 2010-02-12 06:01:49 +0000 | [diff] [blame] | 68 | |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 69 | jpegtran_SOURCES = jpegtran.c rdswitch.c cdjpeg.c transupp.c transupp.h |
DRC | 60fa060 | 2010-02-12 06:01:49 +0000 | [diff] [blame] | 70 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 71 | jpegtran_LDADD = libjpeg.la |
DRC | 60fa060 | 2010-02-12 06:01:49 +0000 | [diff] [blame] | 72 | |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 73 | rdjpgcom_SOURCES = rdjpgcom.c |
DRC | 60fa060 | 2010-02-12 06:01:49 +0000 | [diff] [blame] | 74 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 75 | rdjpgcom_LDADD = libjpeg.la |
DRC | 60fa060 | 2010-02-12 06:01:49 +0000 | [diff] [blame] | 76 | |
| 77 | wrjpgcom_SOURCES = wrjpgcom.c |
| 78 | |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 79 | wrjpgcom_LDADD = libjpeg.la |
DRC | 60fa060 | 2010-02-12 06:01:49 +0000 | [diff] [blame] | 80 | |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 81 | |
DRC | cbda81a | 2010-06-05 01:12:35 +0000 | [diff] [blame] | 82 | dist_man1_MANS = cjpeg.1 djpeg.1 jpegtran.1 rdjpgcom.1 wrjpgcom.1 |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 83 | |
| 84 | DOCS= README install.doc usage.doc wizard.doc example.c libjpeg.doc \ |
| 85 | structure.doc coderules.doc filelist.doc jconfig.doc change.log \ |
DRC | 0b7d4ed | 2010-03-03 09:37:58 +0000 | [diff] [blame] | 86 | README-turbo.txt rdrle.c wrrle.c LICENSE.txt LGPL.txt BUILDING.txt \ |
| 87 | ChangeLog.txt |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 88 | |
DRC | 968c8bb | 2010-02-22 22:50:13 +0000 | [diff] [blame] | 89 | TESTFILES= testorig.jpg testorig.ppm testimg.bmp testimgflt.jpg \ |
DRC | 13b0944 | 2010-06-10 18:56:27 +0000 | [diff] [blame] | 90 | testimgfst.jpg testimgint.jpg testimgp.jpg testimgfst.ppm testimgint.ppm \ |
| 91 | testimg-nosimd.bmp testimgfst-nosimd.ppm testorig-nosimd.ppm \ |
| 92 | testimgflt-nosimd.jpg testimgint-nosimd.jpg testimgfst-nosimd.jpg \ |
| 93 | testimgp-nosimd.jpg |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 94 | |
DRC | 8e2bba9 | 2010-06-04 23:54:10 +0000 | [diff] [blame] | 95 | EXTRA_DIST = win release $(DOCS) $(TESTFILES) |
DRC | 0a945a1 | 2010-02-15 11:04:51 +0000 | [diff] [blame] | 96 | |
| 97 | dist-hook: |
| 98 | rm -rf `find $(distdir) -name .svn` |
| 99 | |
| 100 | |
DRC | 83f2144 | 2010-06-10 18:52:41 +0000 | [diff] [blame] | 101 | if WITH_SIMD |
| 102 | |
DRC | 4924e49 | 2010-02-19 07:00:30 +0000 | [diff] [blame] | 103 | test: testclean cjpeg djpeg jpegtran jpegut |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 104 | ./jpegut |
DRC | 0fd8be5 | 2010-02-19 05:12:39 +0000 | [diff] [blame] | 105 | ./cjpeg -dct int -outfile testoutint.jpg $(srcdir)/testorig.ppm |
| 106 | ./cjpeg -dct fast -opt -outfile testoutfst.jpg $(srcdir)/testorig.ppm |
| 107 | ./cjpeg -dct float -outfile testoutflt.jpg $(srcdir)/testorig.ppm |
| 108 | cmp $(srcdir)/testimgint.jpg testoutint.jpg |
| 109 | cmp $(srcdir)/testimgfst.jpg testoutfst.jpg |
| 110 | cmp $(srcdir)/testimgflt.jpg testoutflt.jpg |
| 111 | ./djpeg -dct int -fast -ppm -outfile testoutint.ppm $(srcdir)/testorig.jpg |
| 112 | ./djpeg -dct fast -ppm -outfile testoutfst.ppm $(srcdir)/testorig.jpg |
| 113 | ./djpeg -dct float -ppm -outfile testoutflt.ppm $(srcdir)/testorig.jpg |
| 114 | cmp $(srcdir)/testimgint.ppm testoutint.ppm |
| 115 | cmp $(srcdir)/testimgfst.ppm testoutfst.ppm |
DRC | 3095971 | 2010-08-07 16:06:56 +0000 | [diff] [blame^] | 116 | cmp $(srcdir)/testimgflt.ppm testoutflt.ppm |
DRC | 971d851 | 2010-02-13 22:55:05 +0000 | [diff] [blame] | 117 | ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp $(srcdir)/testorig.jpg |
DRC | 6f52592 | 2010-02-15 11:10:08 +0000 | [diff] [blame] | 118 | cmp $(srcdir)/testimg.bmp testout.bmp |
DRC | 0fd8be5 | 2010-02-19 05:12:39 +0000 | [diff] [blame] | 119 | ./cjpeg -dct int -progressive -outfile testoutp.jpg $(srcdir)/testorig.ppm |
DRC | 6f52592 | 2010-02-15 11:10:08 +0000 | [diff] [blame] | 120 | cmp $(srcdir)/testimgp.jpg testoutp.jpg |
DRC | 0fd8be5 | 2010-02-19 05:12:39 +0000 | [diff] [blame] | 121 | ./jpegtran -outfile testoutt.jpg testoutp.jpg |
| 122 | cmp $(srcdir)/testimgint.jpg testoutt.jpg |
DRC | 34d59e7 | 2010-02-12 06:27:34 +0000 | [diff] [blame] | 123 | |
DRC | 83f2144 | 2010-06-10 18:52:41 +0000 | [diff] [blame] | 124 | else |
| 125 | |
| 126 | test: testclean cjpeg djpeg jpegtran jpegut |
| 127 | ./jpegut |
DRC | 3095971 | 2010-08-07 16:06:56 +0000 | [diff] [blame^] | 128 | ./cjpeg -dct int -outfile testoutint.jpg $(srcdir)/testorig.ppm |
| 129 | ./cjpeg -dct fast -opt -outfile testoutfst.jpg $(srcdir)/testorig.ppm |
| 130 | ./cjpeg -dct float -outfile testoutflt.jpg $(srcdir)/testorig.ppm |
| 131 | cmp $(srcdir)/testimgint.jpg testoutint.jpg |
| 132 | cmp $(srcdir)/testimgfst.jpg testoutfst.jpg |
DRC | 83f2144 | 2010-06-10 18:52:41 +0000 | [diff] [blame] | 133 | cmp $(srcdir)/testimgflt-nosimd.jpg testoutflt.jpg |
| 134 | ./djpeg -dct int -fast -ppm -outfile testoutint.ppm $(srcdir)/testorig.jpg |
| 135 | ./djpeg -dct fast -ppm -outfile testoutfst.ppm $(srcdir)/testorig.jpg |
| 136 | ./djpeg -dct float -ppm -outfile testoutflt.ppm $(srcdir)/testorig.jpg |
| 137 | cmp $(srcdir)/testimgint.ppm testoutint.ppm |
DRC | 3095971 | 2010-08-07 16:06:56 +0000 | [diff] [blame^] | 138 | cmp $(srcdir)/testimgfst.ppm testoutfst.ppm |
| 139 | cmp $(srcdir)/testorig.ppm testoutflt.ppm |
DRC | 83f2144 | 2010-06-10 18:52:41 +0000 | [diff] [blame] | 140 | ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp $(srcdir)/testorig.jpg |
DRC | 3095971 | 2010-08-07 16:06:56 +0000 | [diff] [blame^] | 141 | cmp $(srcdir)/testimg.bmp testout.bmp |
| 142 | ./cjpeg -dct int -progressive -outfile testoutp.jpg $(srcdir)/testorig.ppm |
| 143 | cmp $(srcdir)/testimgp.jpg testoutp.jpg |
DRC | 83f2144 | 2010-06-10 18:52:41 +0000 | [diff] [blame] | 144 | ./jpegtran -outfile testoutt.jpg testoutp.jpg |
DRC | 3095971 | 2010-08-07 16:06:56 +0000 | [diff] [blame^] | 145 | cmp $(srcdir)/testimgint.jpg testoutt.jpg |
DRC | 83f2144 | 2010-06-10 18:52:41 +0000 | [diff] [blame] | 146 | |
| 147 | endif |
| 148 | |
DRC | 34d59e7 | 2010-02-12 06:27:34 +0000 | [diff] [blame] | 149 | testclean: |
DRC | 7b99172 | 2010-06-10 19:44:56 +0000 | [diff] [blame] | 150 | rm -f testout* |
| 151 | rm -f *_GRAYQ[0-9]*.bmp |
| 152 | rm -f *_GRAYQ[0-9]*.ppm |
| 153 | rm -f *_GRAYQ[0-9]*.jpg |
| 154 | rm -f *_420Q[0-9]*.bmp |
| 155 | rm -f *_420Q[0-9]*.ppm |
| 156 | rm -f *_420Q[0-9]*.jpg |
| 157 | rm -f *_422Q[0-9]*.bmp |
| 158 | rm -f *_422Q[0-9]*.ppm |
| 159 | rm -f *_422Q[0-9]*.jpg |
| 160 | rm -f *_444Q[0-9]*.bmp |
| 161 | rm -f *_444Q[0-9]*.ppm |
| 162 | rm -f *_444Q[0-9]*.jpg |
DRC | 079b434 | 2010-02-15 11:32:23 +0000 | [diff] [blame] | 163 | |
| 164 | rpm: all |
| 165 | sh $(srcdir)/release/makerpm ${PACKAGE_NAME} ${VERSION} ${BUILD} \ |
| 166 | ${RPMARCH} ${srcdir} |
| 167 | |
DRC | f26914b | 2010-02-15 11:36:46 +0000 | [diff] [blame] | 168 | srpm: dist-gzip |
DRC | 6533b6e | 2010-02-15 14:57:18 +0000 | [diff] [blame] | 169 | sh $(srcdir)/release/makesrpm ${PACKAGE_NAME} ${VERSION} ${BUILD} ${srcdir} |
DRC | 52a19f2 | 2010-02-15 12:06:27 +0000 | [diff] [blame] | 170 | |
| 171 | deb: all |
| 172 | sh $(srcdir)/release/makedpkg ${PACKAGE_NAME} ${VERSION} ${BUILD} \ |
| 173 | ${DEBARCH} ${srcdir} |
DRC | 6533b6e | 2010-02-15 14:57:18 +0000 | [diff] [blame] | 174 | |
DRC | 315123f | 2010-02-15 16:14:26 +0000 | [diff] [blame] | 175 | if X86_64 |
| 176 | |
| 177 | udmg: all |
| 178 | sh $(srcdir)/release/makemacpkg ${PACKAGE_NAME} ${VERSION} ${BUILD} \ |
| 179 | ${srcdir} universal |
| 180 | |
| 181 | endif |
| 182 | |
DRC | 6533b6e | 2010-02-15 14:57:18 +0000 | [diff] [blame] | 183 | dmg: all |
| 184 | sh $(srcdir)/release/makemacpkg ${PACKAGE_NAME} ${VERSION} ${BUILD} ${srcdir} |
DRC | b9b1ca3 | 2010-02-17 02:24:02 +0000 | [diff] [blame] | 185 | |
| 186 | if X86_64 |
| 187 | |
| 188 | sunpkg: all |
| 189 | sh $(srcdir)/release/makesunpkg ${PACKAGE_NAME} ${VERSION} ${BUILD} \ |
| 190 | ${DEBARCH} ${srcdir} $(CC) $(CXX) combined |
| 191 | |
DRC | 3dc1bc2 | 2010-05-10 22:18:10 +0000 | [diff] [blame] | 192 | nsi: all |
| 193 | makensis -nocd -DVERSION=$(VERSION) -DAPPNAME=libjpeg-turbo-gcc64 \ |
DRC | ef663e3 | 2010-05-10 23:39:22 +0000 | [diff] [blame] | 194 | -DWLIBDIR=.libs -DWSRCDIR=$(srcdir) -DWBLDDIR=. -DWHDRDIR=. -DWIN64 \ |
DRC | 3dc1bc2 | 2010-05-10 22:18:10 +0000 | [diff] [blame] | 195 | -DPLATFORM="GCC 64-bit" -DGCC $(srcdir)/release/libjpeg-turbo.nsi |
| 196 | |
DRC | b9b1ca3 | 2010-02-17 02:24:02 +0000 | [diff] [blame] | 197 | else |
| 198 | |
| 199 | sunpkg: all |
| 200 | sh $(srcdir)/release/makesunpkg ${PACKAGE_NAME} ${VERSION} ${BUILD} \ |
| 201 | ${DEBARCH} ${srcdir} $(CC) $(CXX) |
| 202 | |
DRC | 0a1f68e | 2010-02-24 07:24:26 +0000 | [diff] [blame] | 203 | nsi: all |
| 204 | makensis -nocd -DVERSION=$(VERSION) -DAPPNAME=libjpeg-turbo-gcc \ |
| 205 | -DWLIBDIR=.libs -DWSRCDIR=$(srcdir) -DWBLDDIR=. -DWHDRDIR=. \ |
| 206 | -DPLATFORM="GCC" -DGCC $(srcdir)/release/libjpeg-turbo.nsi |
DRC | 3dc1bc2 | 2010-05-10 22:18:10 +0000 | [diff] [blame] | 207 | |
| 208 | endif |
DRC | ae79fdb | 2010-06-09 20:16:04 +0000 | [diff] [blame] | 209 | |
| 210 | cygwinpkg: all |
| 211 | sh $(srcdir)/release/makecygwinpkg ${PACKAGE_NAME} ${VERSION} ${srcdir} |