1# Makefile for Independent JPEG Group's software 2 3# This makefile is for Microsoft Visual C++ on Windows NT (and 95?). 4# It builds the IJG library as a statically linkable library (.LIB), 5# and builds the sample applications as console-mode apps. 6# Thanks to Xingong Chang, Raymond Everly and others. 7 8# Read installation instructions before saying "nmake" !! 9# To build an optimized library without debug info, say "nmake nodebug=1". 10 11# Pull in standard variable definitions 12!include <win32.mak> 13 14# You may want to adjust these compiler options: 15CFLAGS= $(cflags) $(cdebug) $(cvars) -I. 16# Generally, we recommend defining any configuration symbols in jconfig.h, 17# NOT via -D switches here. 18 19# Link-time options: 20LDFLAGS= $(ldebug) $(conlflags) 21 22# To link any special libraries, add the necessary commands here. 23LDLIBS= $(conlibs) 24 25# Put here the object file name for the correct system-dependent memory 26# manager file. For NT we suggest jmemnobs.obj, which expects the OS to 27# provide adequate virtual memory. 28SYSDEPMEM= jmemnobs.obj 29 30# miscellaneous OS-dependent stuff 31# file deletion command 32RM= del 33 34# End of configurable options. 35 36 37# source files: JPEG library proper 38LIBSOURCES= jaricom.c jcapimin.c jcapistd.c jcarith.c jccoefct.c jccolor.c \ 39 jcdctmgr.c jchuff.c jcinit.c jcmainct.c jcmarker.c jcmaster.c \ 40 jcomapi.c jcparam.c jcprepct.c jcsample.c jctrans.c jdapimin.c \ 41 jdapistd.c jdarith.c jdatadst.c jdatasrc.c jdcoefct.c jdcolor.c \ 42 jddctmgr.c jdhuff.c jdinput.c jdmainct.c jdmarker.c jdmaster.c \ 43 jdmerge.c jdpostct.c jdsample.c jdtrans.c jerror.c jfdctflt.c \ 44 jfdctfst.c jfdctint.c jidctflt.c jidctfst.c jidctint.c jquant1.c \ 45 jquant2.c jutils.c jmemmgr.c 46# memmgr back ends: compile only one of these into a working library 47SYSDEPSOURCES= jmemansi.c jmemname.c jmemnobs.c jmemdos.c jmemmac.c 48# source files: cjpeg/djpeg/jpegtran applications, also rdjpgcom/wrjpgcom 49APPSOURCES= cjpeg.c djpeg.c jpegtran.c rdjpgcom.c wrjpgcom.c cdjpeg.c \ 50 rdcolmap.c rdswitch.c transupp.c rdppm.c wrppm.c rdgif.c wrgif.c \ 51 rdtarga.c wrtarga.c rdbmp.c wrbmp.c rdrle.c wrrle.c 52SOURCES= $(LIBSOURCES) $(SYSDEPSOURCES) $(APPSOURCES) 53# files included by source files 54INCLUDES= jdct.h jerror.h jinclude.h jmemsys.h jmorecfg.h jpegint.h \ 55 jpeglib.h jversion.h cdjpeg.h cderror.h transupp.h 56# documentation, test, and support files 57DOCS= README install.txt usage.txt cjpeg.1 djpeg.1 jpegtran.1 rdjpgcom.1 \ 58 wrjpgcom.1 wizard.txt example.c libjpeg.txt structure.txt \ 59 coderules.txt filelist.txt change.log 60MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.bcc \ 61 makefile.mc6 makefile.dj makefile.wat makefile.vc makejdsw.vc6 \ 62 makeadsw.vc6 makejdep.vc6 makejdsp.vc6 makejmak.vc6 makecdep.vc6 \ 63 makecdsp.vc6 makecmak.vc6 makeddep.vc6 makeddsp.vc6 makedmak.vc6 \ 64 maketdep.vc6 maketdsp.vc6 maketmak.vc6 makerdep.vc6 makerdsp.vc6 \ 65 makermak.vc6 makewdep.vc6 makewdsp.vc6 makewmak.vc6 makejsln.vc9 \ 66 makeasln.vc9 makejvcp.vc9 makecvcp.vc9 makedvcp.vc9 maketvcp.vc9 \ 67 makervcp.vc9 makewvcp.vc9 makeproj.mac makcjpeg.st makdjpeg.st \ 68 makljpeg.st maktjpeg.st makefile.manx makefile.sas makefile.mms \ 69 makefile.vms makvms.opt 70CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ 71 jconfig.vc jconfig.mac jconfig.st jconfig.manx jconfig.sas \ 72 jconfig.vms 73CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp missing 74OTHERFILES= jconfig.txt ckconfig.c ansi2knr.c ansi2knr.1 jmemdosa.asm \ 75 libjpeg.map 76TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ 77 testimgp.jpg 78DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ 79 $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) 80# library object files common to compression and decompression 81COMOBJECTS= jaricom.obj jcomapi.obj jutils.obj jerror.obj jmemmgr.obj $(SYSDEPMEM) 82# compression library object files 83CLIBOBJECTS= jcapimin.obj jcapistd.obj jcarith.obj jctrans.obj jcparam.obj \ 84 jdatadst.obj jcinit.obj jcmaster.obj jcmarker.obj jcmainct.obj \ 85 jcprepct.obj jccoefct.obj jccolor.obj jcsample.obj jchuff.obj \ 86 jcdctmgr.obj jfdctfst.obj jfdctflt.obj jfdctint.obj 87# decompression library object files 88DLIBOBJECTS= jdapimin.obj jdapistd.obj jdarith.obj jdtrans.obj jdatasrc.obj \ 89 jdmaster.obj jdinput.obj jdmarker.obj jdhuff.obj jdmainct.obj \ 90 jdcoefct.obj jdpostct.obj jddctmgr.obj jidctfst.obj jidctflt.obj \ 91 jidctint.obj jdsample.obj jdcolor.obj jquant1.obj jquant2.obj \ 92 jdmerge.obj 93# These objectfiles are included in libjpeg.lib 94LIBOBJECTS= $(CLIBOBJECTS) $(DLIBOBJECTS) $(COMOBJECTS) 95# object files for sample applications (excluding library files) 96COBJECTS= cjpeg.obj rdppm.obj rdgif.obj rdtarga.obj rdrle.obj rdbmp.obj \ 97 rdswitch.obj cdjpeg.obj 98DOBJECTS= djpeg.obj wrppm.obj wrgif.obj wrtarga.obj wrrle.obj wrbmp.obj \ 99 rdcolmap.obj cdjpeg.obj 100TROBJECTS= jpegtran.obj rdswitch.obj cdjpeg.obj transupp.obj 101 102# Template command for compiling .c to .obj 103.c.obj: 104 $(cc) $(CFLAGS) $*.c 105 106 107all: libjpeg.lib cjpeg.exe djpeg.exe jpegtran.exe rdjpgcom.exe wrjpgcom.exe 108 109libjpeg.lib: $(LIBOBJECTS) 110 $(RM) libjpeg.lib 111 lib -out:libjpeg.lib $(LIBOBJECTS) 112 113cjpeg.exe: $(COBJECTS) libjpeg.lib 114 $(link) $(LDFLAGS) -out:cjpeg.exe $(COBJECTS) libjpeg.lib $(LDLIBS) 115 116djpeg.exe: $(DOBJECTS) libjpeg.lib 117 $(link) $(LDFLAGS) -out:djpeg.exe $(DOBJECTS) libjpeg.lib $(LDLIBS) 118 119jpegtran.exe: $(TROBJECTS) libjpeg.lib 120 $(link) $(LDFLAGS) -out:jpegtran.exe $(TROBJECTS) libjpeg.lib $(LDLIBS) 121 122rdjpgcom.exe: rdjpgcom.obj 123 $(link) $(LDFLAGS) -out:rdjpgcom.exe rdjpgcom.obj $(LDLIBS) 124 125wrjpgcom.exe: wrjpgcom.obj 126 $(link) $(LDFLAGS) -out:wrjpgcom.exe wrjpgcom.obj $(LDLIBS) 127 128 129clean: 130 $(RM) *.obj *.exe libjpeg.lib 131 $(RM) testout* 132 133test: cjpeg.exe djpeg.exe jpegtran.exe 134 $(RM) testout* 135 .\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg 136 .\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg 137 .\cjpeg -dct int -outfile testout.jpg testimg.ppm 138 .\djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg 139 .\cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm 140 .\jpegtran -outfile testoutt.jpg testprog.jpg 141 fc /b testimg.ppm testout.ppm 142 fc /b testimg.bmp testout.bmp 143 fc /b testimg.jpg testout.jpg 144 fc /b testimg.ppm testoutp.ppm 145 fc /b testimgp.jpg testoutp.jpg 146 fc /b testorig.jpg testoutt.jpg 147 148 149jaricom.obj: jaricom.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 150jcapimin.obj: jcapimin.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 151jcapistd.obj: jcapistd.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 152jcarith.obj: jcarith.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 153jccoefct.obj: jccoefct.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 154jccolor.obj: jccolor.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 155jcdctmgr.obj: jcdctmgr.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 156jchuff.obj: jchuff.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 157jcinit.obj: jcinit.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 158jcmainct.obj: jcmainct.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 159jcmarker.obj: jcmarker.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 160jcmaster.obj: jcmaster.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 161jcomapi.obj: jcomapi.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 162jcparam.obj: jcparam.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 163jcprepct.obj: jcprepct.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 164jcsample.obj: jcsample.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 165jctrans.obj: jctrans.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 166jdapimin.obj: jdapimin.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 167jdapistd.obj: jdapistd.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 168jdarith.obj: jdarith.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 169jdatadst.obj: jdatadst.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h 170jdatasrc.obj: jdatasrc.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h 171jdcoefct.obj: jdcoefct.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 172jdcolor.obj: jdcolor.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 173jddctmgr.obj: jddctmgr.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 174jdhuff.obj: jdhuff.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 175jdinput.obj: jdinput.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 176jdmainct.obj: jdmainct.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 177jdmarker.obj: jdmarker.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 178jdmaster.obj: jdmaster.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 179jdmerge.obj: jdmerge.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 180jdpostct.obj: jdpostct.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 181jdsample.obj: jdsample.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 182jdtrans.obj: jdtrans.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 183jerror.obj: jerror.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jversion.h jerror.h 184jfdctflt.obj: jfdctflt.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 185jfdctfst.obj: jfdctfst.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 186jfdctint.obj: jfdctint.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 187jidctflt.obj: jidctflt.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 188jidctfst.obj: jidctfst.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 189jidctint.obj: jidctint.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jdct.h 190jquant1.obj: jquant1.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 191jquant2.obj: jquant2.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 192jutils.obj: jutils.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h 193jmemmgr.obj: jmemmgr.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jmemsys.h 194jmemansi.obj: jmemansi.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jmemsys.h 195jmemname.obj: jmemname.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jmemsys.h 196jmemnobs.obj: jmemnobs.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jmemsys.h 197jmemdos.obj: jmemdos.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jmemsys.h 198jmemmac.obj: jmemmac.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h jmemsys.h 199cjpeg.obj: cjpeg.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h jversion.h 200djpeg.obj: djpeg.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h jversion.h 201jpegtran.obj: jpegtran.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h transupp.h jversion.h 202rdjpgcom.obj: rdjpgcom.c jinclude.h jconfig.h 203wrjpgcom.obj: wrjpgcom.c jinclude.h jconfig.h 204cdjpeg.obj: cdjpeg.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 205rdcolmap.obj: rdcolmap.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 206rdswitch.obj: rdswitch.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 207transupp.obj: transupp.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h transupp.h 208rdppm.obj: rdppm.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 209wrppm.obj: wrppm.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 210rdgif.obj: rdgif.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 211wrgif.obj: wrgif.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 212rdtarga.obj: rdtarga.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 213wrtarga.obj: wrtarga.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 214rdbmp.obj: rdbmp.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 215wrbmp.obj: wrbmp.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 216rdrle.obj: rdrle.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 217wrrle.obj: wrrle.c cdjpeg.h jinclude.h jconfig.h jpeglib.h jmorecfg.h jerror.h cderror.h 218