Blame thirdparty/zlib/zlib-1.2.7/old/Makefile.emx
|
kusano |
7d535a |
# Makefile for zlib. Modified for emx/rsxnt by Chr. Spieler, 6/16/98.
|
|
kusano |
7d535a |
# Copyright (C) 1995-1998 Jean-loup Gailly.
|
|
kusano |
7d535a |
# For conditions of distribution and use, see copyright notice in zlib.h
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# To compile, or to compile and test, type:
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# make -fmakefile.emx; make test -fmakefile.emx
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
CC=gcc -Zwin32
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#CFLAGS=-MMD -O
|
|
kusano |
7d535a |
#CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7
|
|
kusano |
7d535a |
#CFLAGS=-MMD -g -DDEBUG
|
|
kusano |
7d535a |
CFLAGS=-MMD -O3 $(BUTT) -Wall -Wwrite-strings -Wpointer-arith -Wconversion \
|
|
kusano |
7d535a |
-Wstrict-prototypes -Wmissing-prototypes
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# If cp.exe is available, replace "copy /Y" with "cp -fp" .
|
|
kusano |
7d535a |
CP=copy /Y
|
|
kusano |
7d535a |
# If gnu install.exe is available, replace $(CP) with ginstall.
|
|
kusano |
7d535a |
INSTALL=$(CP)
|
|
kusano |
7d535a |
# The default value of RM is "rm -f." If "rm.exe" is found, comment out:
|
|
kusano |
7d535a |
RM=del
|
|
kusano |
7d535a |
LDLIBS=-L. -lzlib
|
|
kusano |
7d535a |
LD=$(CC) -s -o
|
|
kusano |
7d535a |
LDSHARED=$(CC)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
INCL=zlib.h zconf.h
|
|
kusano |
7d535a |
LIBS=zlib.a
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AR=ar rcs
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
prefix=/usr/local
|
|
kusano |
7d535a |
exec_prefix = $(prefix)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
OBJS = adler32.o compress.o crc32.o deflate.o gzclose.o gzlib.o gzread.o \
|
|
kusano |
7d535a |
gzwrite.o infback.o inffast.o inflate.o inftrees.o trees.o uncompr.o zutil.o
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
TEST_OBJS = example.o minigzip.o
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
all: example.exe minigzip.exe
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
test: all
|
|
kusano |
7d535a |
./example
|
|
kusano |
7d535a |
echo hello world | .\minigzip | .\minigzip -d
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
%.o : %.c
|
|
kusano |
7d535a |
$(CC) $(CFLAGS) -c $< -o $@
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
zlib.a: $(OBJS)
|
|
kusano |
7d535a |
$(AR) $@ $(OBJS)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
%.exe : %.o $(LIBS)
|
|
kusano |
7d535a |
$(LD) $@ $< $(LDLIBS)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
.PHONY : clean
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
clean:
|
|
kusano |
7d535a |
$(RM) *.d
|
|
kusano |
7d535a |
$(RM) *.o
|
|
kusano |
7d535a |
$(RM) *.exe
|
|
kusano |
7d535a |
$(RM) zlib.a
|
|
kusano |
7d535a |
$(RM) foo.gz
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
DEPS := $(wildcard *.d)
|
|
kusano |
7d535a |
ifneq ($(DEPS),)
|
|
kusano |
7d535a |
include $(DEPS)
|
|
kusano |
7d535a |
endif
|