1 # This makefile is made for OpenWatcom/NT and runs on my system. 2 # It should not be too hard to make it run on other systems, too. 3 # 4 # FIRST, move this makefile and _stdint.h to the libexif main 5 # directory (the place where you find README and COPYING etc.) 6 # 7 # WARNING: I used another makefile as template, so some things might be 8 # thrown away. Don't hesitate to improve this makefile! 9 # 10 # WARNING: This makefile has been made mainly for myself, I didn't 11 # waste time to make it look "nice". 12 # 13 # LICENSE: no restrictions at all, but USE ON YOUR OWN RISK ONLY. 14 # 15 # USAGE: Simply type "wmake" or "wmake -f <makefilename>" when 16 # being in the libexif main directory. This makefile should 17 # be in that directory, too, of course. 18 # 19 # Angela Wrobel <http://www.wrobelnet.de/> 20 21 22 # Uncomment line for desired system 23 #SYSTEM=DOS 24 #SYSTEM=OS2 25 SYSTEM=NT 26 27 # The name of your C compiler: 28 CC= wcl386 29 30 # We're using similar constants like wxWidgets 31 !ifeq FINAL 1 32 OPTFLAGS= -5r -zp8 -otexan 33 !else 34 OPTFLAGS= -5r -od -d2 35 !endif 36 37 LIBEXIFDIR=libexif 38 TESTEXIFDIR=test 39 40 IFLAGS= -i=. 41 WINVERFLAGS= 42 EXTRACPPFLAGS=-dEXIF_DONT_CHANGE_MAKER_NOTE 43 DEBUGCFLAGS= 44 EXTRACFLAGS= 45 OUTPUTDIR=$(LIBEXIFDIR) 46 CPPFLAGS = /dWIN32 /bm /fo=$(OUTPUTDIR)\ /fr -zq $(IFLAGS) $(OPTFLAGS) $(WINVERFLAGS) $(EXTRACPPFLAGS) 47 48 # zm and zv as well as the linker options below are used to make the resulting 49 # .exe smaller 50 CFLAGS = $(CPPFLAGS) $(DEBUGCFLAGS) $(EXTRACFLAGS) /zm 51 52 # Link-time cc options: 53 !ifeq SYSTEM DOS 54 LDFLAGS= -zq -l=dos4g 55 !else ifeq SYSTEM OS2 56 LDFLAGS= -zq -l=os2v2 57 !else ifeq SYSTEM NT 58 LDFLAGS= -zq -l=nt 59 !endif 60 61 # End of configurable options. 62 63 64 65 LIBOBJECTS = & 66 $(LIBEXIFDIR)\exif-byte-order.obj $(LIBEXIFDIR)\exif-content.obj & 67 $(LIBEXIFDIR)\exif-data.obj $(LIBEXIFDIR)\exif-entry.obj & 68 $(LIBEXIFDIR)\exif-format.obj $(LIBEXIFDIR)\exif-ifd.obj & 69 $(LIBEXIFDIR)\exif-loader.obj $(LIBEXIFDIR)\exif-log.obj & 70 $(LIBEXIFDIR)\exif-mem.obj & 71 $(LIBEXIFDIR)\exif-mnote-data.obj $(LIBEXIFDIR)\exif-tag.obj & 72 $(LIBEXIFDIR)\exif-utils.obj & 73 $(LIBEXIFDIR)\exif-mnote-data-olympus.obj & 74 $(LIBEXIFDIR)\mnote-olympus-entry.obj & 75 $(LIBEXIFDIR)\mnote-olympus-tag.obj & 76 $(LIBEXIFDIR)\exif-mnote-data-pentax.obj & 77 $(LIBEXIFDIR)\mnote-pentax-entry.obj & 78 $(LIBEXIFDIR)\mnote-pentax-tag.obj & 79 $(LIBEXIFDIR)\exif-mnote-data-canon.obj & 80 $(LIBEXIFDIR)\mnote-canon-entry.obj & 81 $(LIBEXIFDIR)\mnote-canon-tag.obj & 82 $(LIBEXIFDIR)\exif-mnote-data-fuji.obj & 83 $(LIBEXIFDIR)\mnote-fuji-entry.obj & 84 $(LIBEXIFDIR)\mnote-fuji-tag.obj 85 86 87 #CFLAGS = /dWIN32 /bm /fr -zq -i=. -5r -od -d2 /d2 /zm /fo=$(LIBEXIFDIR)\ 88 89 all : libexif.lib test-mem.exe test-mnote.exe test-value.exe 90 # test-tree.exe 91 92 libexif.lib: $(LIBOBJECTS) 93 - del libexif.lib 94 * wlib -n libexif.lib $(LIBOBJECTS) 95 96 $(LIBEXIFDIR)\exif-byte-order.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-byte-order.c 97 $(CC) -c $(CFLAGS) $[* 98 99 $(LIBEXIFDIR)\exif-content.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-content.c 100 $(CC) -c $(CFLAGS) $[* 101 102 $(LIBEXIFDIR)\exif-data.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-data.c 103 $(CC) -c $(CFLAGS) $[* 104 105 $(LIBEXIFDIR)\exif-entry.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-entry.c 106 $(CC) -c $(CFLAGS) $[* 107 108 $(LIBEXIFDIR)\exif-format.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-format.c 109 $(CC) -c $(CFLAGS) $[* 110 111 $(LIBEXIFDIR)\exif-ifd.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-ifd.c 112 $(CC) -c $(CFLAGS) $[* 113 114 $(LIBEXIFDIR)\exif-loader.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-loader.c 115 $(CC) -c $(CFLAGS) $[* 116 117 $(LIBEXIFDIR)\exif-log.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-log.c 118 $(CC) -c $(CFLAGS) $[* 119 120 $(LIBEXIFDIR)\exif-mem.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-mem.c 121 $(CC) -c $(CFLAGS) $[* 122 123 $(LIBEXIFDIR)\exif-mnote-data.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-mnote-data.c 124 $(CC) -c $(CFLAGS) $[* 125 126 $(LIBEXIFDIR)\exif-tag.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-tag.c 127 $(CC) -c $(CFLAGS) $[* 128 129 $(LIBEXIFDIR)\exif-utils.obj : .AUTODEPEND $(LIBEXIFDIR)\exif-utils.c 130 $(CC) -c $(CFLAGS) $[* 131 132 $(LIBEXIFDIR)\exif-mnote-data-olympus.obj : .AUTODEPEND $(LIBEXIFDIR)\olympus\exif-mnote-data-olympus.c 133 $(CC) -c $(CFLAGS) $[* 134 135 $(LIBEXIFDIR)\mnote-olympus-entry.obj : .AUTODEPEND $(LIBEXIFDIR)\olympus\mnote-olympus-entry.c 136 $(CC) -c $(CFLAGS) $[* 137 138 $(LIBEXIFDIR)\mnote-olympus-tag.obj : .AUTODEPEND $(LIBEXIFDIR)\olympus\mnote-olympus-tag.c 139 $(CC) -c $(CFLAGS) $[* 140 141 $(LIBEXIFDIR)\exif-mnote-data-pentax.obj : .AUTODEPEND $(LIBEXIFDIR)\pentax\exif-mnote-data-pentax.c 142 $(CC) -c $(CFLAGS) $[* 143 144 $(LIBEXIFDIR)\mnote-pentax-entry.obj : .AUTODEPEND $(LIBEXIFDIR)\pentax\mnote-pentax-entry.c 145 $(CC) -c $(CFLAGS) $[* 146 147 $(LIBEXIFDIR)\mnote-pentax-tag.obj : .AUTODEPEND $(LIBEXIFDIR)\pentax\mnote-pentax-tag.c 148 $(CC) -c $(CFLAGS) $[* 149 150 $(LIBEXIFDIR)\exif-mnote-data-canon.obj : .AUTODEPEND $(LIBEXIFDIR)\canon\exif-mnote-data-canon.c 151 $(CC) -c $(CFLAGS) $[* 152 153 $(LIBEXIFDIR)\mnote-canon-entry.obj : .AUTODEPEND $(LIBEXIFDIR)\canon\mnote-canon-entry.c 154 $(CC) -c $(CFLAGS) $[* 155 156 $(LIBEXIFDIR)\mnote-canon-tag.obj : .AUTODEPEND $(LIBEXIFDIR)\canon\mnote-canon-tag.c 157 $(CC) -c $(CFLAGS) $[* 158 159 $(LIBEXIFDIR)\exif-mnote-data-fuji.obj : .AUTODEPEND $(LIBEXIFDIR)\fuji\exif-mnote-data-fuji.c 160 $(CC) -c $(CFLAGS) $[* 161 162 $(LIBEXIFDIR)\mnote-fuji-entry.obj : .AUTODEPEND $(LIBEXIFDIR)\fuji\mnote-fuji-entry.c 163 $(CC) -c $(CFLAGS) $[* 164 165 $(LIBEXIFDIR)\mnote-fuji-tag.obj : .AUTODEPEND $(LIBEXIFDIR)\fuji\mnote-fuji-tag.c 166 $(CC) -c $(CFLAGS) $[* 167 168 169 test-mem.exe : .AUTODEPEND $(TESTEXIFDIR)\test-mem.c 170 $(CC) $(CFLAGS) $(LDFRLAGS) $< libexif.lib 171 172 test-mnote.exe : .AUTODEPEND $(TESTEXIFDIR)\test-mnote.c 173 $(CC) $(CFLAGS) $(LDFRLAGS) $< libexif.lib 174 175 test-tree.exe : .AUTODEPEND $(TESTEXIFDIR)\test-tree.c 176 $(CC) $(CFLAGS) $(LDFRLAGS) $< libexif.lib 177 178 test-value.exe : .AUTODEPEND $(TESTEXIFDIR)\test-value.c 179 $(CC) $(CFLAGS) $(LDFRLAGS) $< libexif.lib 180 181 182 clean: .SYMBOLIC 183 - del $(LIBEXIFDIR)\*.obj 184 - del *.exe 185 - del libexif.lib 186 187