File: makefile.mgw

package info (click to toggle)
smapi 2.4.0%2Brc2-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, lenny, sarge
  • size: 1,016 kB
  • ctags: 1,831
  • sloc: ansic: 11,304; pascal: 394; makefile: 137; asm: 125
file content (50 lines) | stat: -rwxr-xr-x 800 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# $Id: makefile.mgw,v 1.20 2003/01/16 03:53:19 andr_lukyanov Exp $
#
# Makefile for Building SMAPI with cross-compiler Mingw32
# No support for the Husky build environment.

CC	= gcc
LIB	= ar

RANLIB	= ranlib
ifeq ($(TERM),msys)
RM	= rm
else
RM	= del
endif

OBJ	= .o
EXE	=.exe

# __MINGW32__ is predefined macros, __NT__ defined in compiler.h
# use __MINGW32__ in source code please (if possible)
CDEFS=

CFLAGS=-Wall -c
COPT=-O3

default: all

TARGET=libsmapimgw.a

include makefile.inc


all: $(TARGET) gnmsgid.exe

.c$(OBJ):
	$(CC) $(CFLAGS) $(CDEFS) $(COPT) $<
	$(LIB) r $(TARGET) $@

$(TARGET): $(OBJS)
	$(RANLIB) $(TARGET)

gnmsgid$(EXE): $(OBJS)
	$(CC) -Wall $(CDEFS) $(COPT) gnmsgid.c -o$@ $(MGOBJS) $(TARGET)

clean:
	-$(RM) *$(OBJ)

distclean: clean
	-$(RM) $(TARGET)
	-$(RM) gnmsgid$(EXE)