The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1 | # Makefile for libpng (static) |
| 2 | # IBM C version 3.x for Win32 and OS/2 |
Sireesh Tripurari | b478e66 | 2014-05-09 15:15:10 +0530 | [diff] [blame^] | 3 | # Copyright (C) 2006, 2014 Glenn Randers-Pehrson |
The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4 | # Copyright (C) 2000 Cosmin Truta |
Patrick Scott | 5f6bd84 | 2010-06-28 16:55:16 -0400 | [diff] [blame] | 5 | # |
Patrick Scott | a0bb96c | 2009-07-22 11:50:02 -0400 | [diff] [blame] | 6 | # This code is released under the libpng license. |
| 7 | # For conditions of distribution and use, see the disclaimer |
| 8 | # and license in png.h |
Patrick Scott | 5f6bd84 | 2010-06-28 16:55:16 -0400 | [diff] [blame] | 9 | # |
The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 10 | # Notes: |
| 11 | # Derived from makefile.std |
| 12 | # All modules are compiled in C mode |
| 13 | # Tested under Win32, expected to work under OS/2 |
| 14 | # Can be easily adapted for IBM VisualAge/C++ for AIX |
| 15 | |
| 16 | # Location of the zlib library and include files |
| 17 | ZLIBINC = ../zlib |
| 18 | ZLIBLIB = ../zlib |
| 19 | |
| 20 | # Compiler, linker, lib and other tools |
| 21 | CC = icc |
| 22 | LD = ilink |
| 23 | AR = ilib |
| 24 | RM = del |
| 25 | |
Sireesh Tripurari | b478e66 | 2014-05-09 15:15:10 +0530 | [diff] [blame^] | 26 | CPPFLAGS = -I$(ZLIBINC) |
| 27 | CFLAGS = -Mc -O2 -W3 |
The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 28 | LDFLAGS = |
| 29 | |
| 30 | # File extensions |
| 31 | O=.obj |
| 32 | A=.lib |
| 33 | E=.exe |
| 34 | |
| 35 | # Variables |
| 36 | OBJS = png$(O) pngerror$(O) pngget$(O) pngmem$(O) pngpread$(O) \ |
| 37 | pngread$(O) pngrio$(O) pngrtran$(O) pngrutil$(O) pngset$(O) \ |
| 38 | pngtrans$(O) pngwio$(O) pngwrite$(O) pngwtran$(O) pngwutil$(O) |
| 39 | |
| 40 | LIBS = libpng$(A) $(ZLIBLIB)/zlib$(A) |
| 41 | |
| 42 | # Targets |
Sireesh Tripurari | b478e66 | 2014-05-09 15:15:10 +0530 | [diff] [blame^] | 43 | .c$(O): |
| 44 | $(CC) -c $(CPPFLAGS) $(CFLAGS) $< |
| 45 | |
The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 46 | all: libpng$(A) pngtest$(E) |
| 47 | |
Chris Craik | b50c217 | 2013-07-29 15:28:30 -0700 | [diff] [blame] | 48 | # see scripts/pnglibconf.mak for more options |
| 49 | pnglibconf.h: scripts/pnglibconf.h.prebuilt |
| 50 | cp scripts/pnglibconf.h.prebuilt $@ |
| 51 | |
The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 52 | libpng$(A): $(OBJS) |
| 53 | $(AR) -out:$@ $(OBJS) |
| 54 | |
| 55 | test: pngtest$(E) |
| 56 | pngtest$(E) |
| 57 | |
| 58 | pngtest: pngtest$(E) |
| 59 | |
| 60 | pngtest$(E): pngtest$(O) libpng$(A) |
| 61 | $(LD) $(LDFLAGS) pngtest$(O) $(LIBS) |
| 62 | |
| 63 | clean: |
| 64 | $(RM) *$(O) |
| 65 | $(RM) libpng$(A) |
Chris Craik | b50c217 | 2013-07-29 15:28:30 -0700 | [diff] [blame] | 66 | $(RM) pnglibconf.h |
The Android Open Source Project | 893912b | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 67 | $(RM) pngtest$(E) |
| 68 | $(RM) pngout.png |
| 69 | |
Sireesh Tripurari | b478e66 | 2014-05-09 15:15:10 +0530 | [diff] [blame^] | 70 | png$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 71 | pngerror$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 72 | pngget$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 73 | pngmem$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 74 | pngpread$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 75 | pngread$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 76 | pngrio$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 77 | pngrtran$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 78 | pngrutil$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 79 | pngset$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 80 | pngtrans$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 81 | pngwio$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 82 | pngwrite$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 83 | pngwtran$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
| 84 | pngwutil$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h |
Patrick Scott | a0bb96c | 2009-07-22 11:50:02 -0400 | [diff] [blame] | 85 | |
Chris Craik | b50c217 | 2013-07-29 15:28:30 -0700 | [diff] [blame] | 86 | pngtest$(O): png.h pngconf.h pnglibconf.h |