/[svn]/liblscp/trunk/win32/Makefile.mingw
ViewVC logotype

Annotation of /liblscp/trunk/win32/Makefile.mingw

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1813 - (hide annotations) (download)
Sat Dec 20 23:16:45 2008 UTC (15 years, 4 months ago) by capela
File size: 1070 byte(s)
- fixed win32/Makefile.mingw.

1 capela 1671 # Makefile.mingw - liblscp.a
2     # For MinGW.
3     #
4     # Usage: make -f Makefile.mingw
5     #
6    
7     CC = gcc
8     LD = ld
9     AR = ar -r
10     RM = rm -f
11    
12     LIBNAME = liblscp
13    
14     INCDIR = ../lscp
15     SRCDIR = ../src
16    
17     CCFLAGS = -O2 -I..
18    
19     #
20     # Static library build rules.
21     #
22    
23     $(LIBNAME).a:
24     $(RM) $(LIBNAME).a
25     $(CC) $(CCFLAGS) -c $(SRCDIR)/thread.c
26     $(CC) $(CCFLAGS) -c $(SRCDIR)/socket.c
27     $(CC) $(CCFLAGS) -c $(SRCDIR)/client.c
28     $(CC) $(CCFLAGS) -c $(SRCDIR)/device.c
29     $(CC) $(CCFLAGS) -c $(SRCDIR)/common.c
30     $(CC) $(CCFLAGS) -c $(SRCDIR)/event.c
31     $(AR) $(LIBNAME).a thread.o socket.o client.o device.o common.o event.o
32    
33     #
34     # Examples build rules.
35     #
36    
37     EXDIR = ../examples
38    
39     LDFLAGS = -L.
40     LDLIBS = -llscp -lws2_32
41    
42     examples: $(LIBNAME).a
43     $(CC) $(CCFLAGS) -c $(EXDIR)/server.c
44     $(CC) $(CCFLAGS) -c $(EXDIR)/parser.c
45 capela 1813 $(CC) -o example_client $(CCFLAGS) -I$(EXDIR) $(EXDIR)/example_client.c $(LDFLAGS) $(LDLIBS)
46 capela 1671 $(CC) -o example_server $(CCFLAGS) -I$(EXDIR) $(EXDIR)/example_server.c server.o parser.o $(LDFLAGS) $(LDLIBS)
47    
48     #
49     # Common rules.
50     #
51    
52     all: $(LIBNAME).a examples
53    
54     clean:
55     - $(RM) *.o
56     - $(RM) *.a
57     - $(RM) *.exe

  ViewVC Help
Powered by ViewVC