]> git.saurik.com Git - wxWidgets.git/blame - src/png/scripts/makefile.gcc
Add various selection menu items to the sample.
[wxWidgets.git] / src / png / scripts / makefile.gcc
CommitLineData
d5e7ffcf
KO
1# makefile for libpng using gcc (generic, static library)\r
2# Copyright (C) 2008 Glenn Randers-Pehrson\r
3# Copyright (C) 2000 Cosmin Truta\r
4# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.\r
b61cc19c
PC
5#\r
6# This code is released under the libpng license.\r
7# For conditions of distribution and use, see the disclaimer\r
8# and license in png.h\r
d5e7ffcf
KO
9\r
10# Location of the zlib library and include files\r
11ZLIBINC = ../zlib\r
12ZLIBLIB = ../zlib\r
13\r
14# Compiler, linker, lib and other tools\r
15CC = gcc\r
16LD = $(CC)\r
17AR_RC = ar rcs\r
18RANLIB = ranlib\r
19RM_F = rm -f\r
20\r
21CDEBUG = -g -DPNG_DEBUG=5\r
22LDDEBUG =\r
23CRELEASE = -O2\r
24LDRELEASE = -s\r
25#CFLAGS = -W -Wall $(CDEBUG)\r
26CFLAGS = -W -Wall $(CRELEASE)\r
27#LDFLAGS = $(LDDEBUG)\r
28LDFLAGS = $(LDRELEASE)\r
29LIBS = -lz -lm\r
30\r
31# File extensions\r
32O=.o\r
33A=.a\r
34EXE=\r
35\r
36# Variables\r
b61cc19c
PC
37OBJS = png$(O) pngerror$(O) pngget$(O) pngmem$(O) pngpread$(O) \\r
38 pngread$(O) pngrio$(O) pngrtran$(O) pngrutil$(O) pngset$(O) \\r
39 pngtrans$(O) pngwio$(O) pngwrite$(O) pngwtran$(O) pngwutil$(O)\r
d5e7ffcf
KO
40\r
41# Targets\r
42all: static\r
43\r
44.c$(O):\r
45 $(CC) -c $(CFLAGS) -I$(ZLIBINC) $<\r
46\r
47static: libpng$(A) pngtest$(EXE)\r
48\r
49shared:\r
50 @echo This is a generic makefile that cannot create shared libraries.\r
51 @echo Please use a configuration that is specific to your platform.\r
52 @false\r
53\r
54libpng$(A): $(OBJS)\r
55 $(AR_RC) $@ $(OBJS)\r
56 $(RANLIB) $@\r
57\r
58test: pngtest$(EXE)\r
59 ./pngtest$(EXE)\r
60\r
61pngtest$(EXE): pngtest$(O) libpng$(A)\r
62 $(LD) $(LDFLAGS) -L$(ZLIBLIB) -o $@ pngtest$(O) libpng$(A) $(LIBS)\r
63\r
64clean:\r
65 $(RM_F) *$(O) libpng$(A) pngtest$(EXE) pngout.png\r
66\r
b61cc19c
PC
67png$(O): png.h pngconf.h pngpriv.h\r
68pngerror$(O): png.h pngconf.h pngpriv.h\r
69pngget$(O): png.h pngconf.h pngpriv.h\r
70pngmem$(O): png.h pngconf.h pngpriv.h\r
71pngpread$(O): png.h pngconf.h pngpriv.h\r
72pngread$(O): png.h pngconf.h pngpriv.h\r
73pngrio$(O): png.h pngconf.h pngpriv.h\r
74pngrtran$(O): png.h pngconf.h pngpriv.h\r
75pngrutil$(O): png.h pngconf.h pngpriv.h\r
76pngset$(O): png.h pngconf.h pngpriv.h\r
77pngtrans$(O): png.h pngconf.h pngpriv.h\r
78pngwio$(O): png.h pngconf.h pngpriv.h\r
79pngwrite$(O): png.h pngconf.h pngpriv.h\r
80pngwtran$(O): png.h pngconf.h pngpriv.h\r
81pngwutil$(O): png.h pngconf.h pngpriv.h\r
d5e7ffcf 82\r
b61cc19c 83pngtest$(O): png.h pngconf.h\r