GDAL_ROOT	=	..\..\..
!INCLUDE $(GDAL_ROOT)\nmake.opt


OBJ	=	\
	jcapimin12.obj jcapistd12.obj jccoefct12.obj jccolor12.obj jcdctmgr12.obj jchuff12.obj \
        jcinit12.obj jcmainct12.obj jcmarker12.obj jcmaster12.obj jcomapi12.obj jcparam12.obj \
        jcphuff12.obj jcprepct12.obj jcsample12.obj jctrans12.obj jdapimin12.obj jdapistd12.obj \
        jdatadst12.obj jdatasrc12.obj jdcoefct12.obj jdcolor12.obj jddctmgr12.obj jdhuff12.obj \
        jdinput12.obj jdmainct12.obj jdmarker12.obj jdmaster12.obj jdmerge12.obj jdphuff12.obj \
        jdpostct12.obj jdsample12.obj jdtrans12.obj jerror12.obj jfdctflt12.obj jfdctfst12.obj \
        jfdctint12.obj jidctflt12.obj jidctfst12.obj jidctint12.obj jidctred12.obj jquant112.obj \
        jquant212.obj jutils12.obj jmemmgr12.obj jmemansi12.obj 

GDAL_ROOT	=	..\..\..

EXTRAFLAGS      = -DDEFAULT_MAX_MEM=500000000L

default:	jcapimin12.c $(OBJ)
	xcopy /D  /Y *.obj ..\..\o

jcapimin12.c:	../libjpeg/jcapimin.c
	xcopy /Y ..\libjpeg\*.h
	xcopy /Y jmorecfg.h.12 jmorecfg.h
	xcopy /Y ..\libjpeg\*.c
	ren jcapimin.c jcapimin12.c
	ren jcapistd.c jcapistd12.c
	ren jccoefct.c jccoefct12.c
	ren jccolor.c jccolor12.c
	ren jcdctmgr.c jcdctmgr12.c
	ren jchuff.c jchuff12.c
	ren jcinit.c jcinit12.c
	ren jcmainct.c jcmainct12.c
	ren jcmarker.c jcmarker12.c
	ren jcmaster.c jcmaster12.c
	ren jcomapi.c jcomapi12.c
	ren jcparam.c jcparam12.c
	ren jcphuff.c jcphuff12.c
	ren jcprepct.c jcprepct12.c
	ren jcsample.c jcsample12.c
	ren jctrans.c jctrans12.c
	ren jdapimin.c jdapimin12.c
	ren jdapistd.c jdapistd12.c
	ren jdatadst.c jdatadst12.c
	ren jdatasrc.c jdatasrc12.c
	ren jdcoefct.c jdcoefct12.c
	ren jdcolor.c jdcolor12.c
	ren jddctmgr.c jddctmgr12.c
	ren jdhuff.c jdhuff12.c
	ren jdinput.c jdinput12.c
	ren jdmainct.c jdmainct12.c
	ren jdmarker.c jdmarker12.c
	ren jdmaster.c jdmaster12.c
	ren jdmerge.c jdmerge12.c
	ren jdphuff.c jdphuff12.c
	ren jdpostct.c jdpostct12.c
	ren jdsample.c jdsample12.c
	ren jdtrans.c jdtrans12.c
	ren jerror.c jerror12.c
	ren jfdctflt.c jfdctflt12.c
	ren jfdctfst.c jfdctfst12.c
	ren jfdctint.c jfdctint12.c
	ren jidctflt.c jidctflt12.c
	ren jidctfst.c jidctfst12.c
	ren jidctint.c jidctint12.c
	ren jidctred.c jidctred12.c
	ren jmemansi.c jmemansi12.c
	ren jmemmgr.c jmemmgr12.c
	ren jquant1.c jquant112.c
	ren jquant2.c jquant212.c
	ren jutils.c jutils12.c

clean:
	-del *.obj
	-del *.c
	-del *.h
