~ubuntu-branches/ubuntu/intrepid/micro-httpd/intrepid

« back to all changes in this revision

Viewing changes to Makefile

  • Committer: Bazaar Package Importer
  • Author(s): Daniel Baumann
  • Date: 2006-08-14 14:24:00 UTC
  • mfrom: (2.1.2 edgy)
  • Revision ID: james.westby@ubuntu.com-20060814142400-hdu32p3spypc3ngl
Tags: 20051212-3
hrm, I'm too lazy to change the address in control :(

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Makefile for micro_httpd
2
 
# Author: Daniel Baumann <daniel.baumann@panthera-systems.net>
3
 
 
4
 
 
5
 
# Note: If you are using a SystemV-based operating systems, such as Sun Solaris,
6
 
#       you will need to uncomment this definition.
7
 
#SYSV_LIBS=-lnsl -lsocket
8
 
 
9
 
DESTDIR=
10
 
PREFIX=/usr/local
11
 
BINDIR=$(PREFIX)/sbin
12
 
MANDIR=$(PREFIX)/man/man8
13
 
 
14
 
CC=gcc
15
 
CFLAGS=-Wall -g -O2
16
 
LDFLAGS=-g $(SYSVLIBS)
17
 
 
18
 
 
19
 
all:            make
20
 
 
21
 
make:           micro_httpd
22
 
 
23
 
install:        make
24
 
                install -d -m 755 $(DESTDIR)/$(BINDIR)
25
 
                install -m 755 micro_httpd $(DESTDIR)/$(BINDIR)
26
 
                install -d -m 755 $(DESTDIR)/$(MANDIR)
27
 
                install -m 644 micro_httpd.8 $(DESTDIR)/$(MANDIR)
28
 
 
29
 
uninstall:
30
 
                rm -f $(DESTDIR)/$(BINDIR)/micro_httpd
31
 
                rm -f $(DESTDIR)/$(MANDIR)/micro_httpd.8
32
 
 
33
 
clean:
34
 
                rm -f micro_httpd micro_httpd.o
35
 
                rm -f core core.* *.core
36
 
 
37
 
distclean:      clean
38
 
 
 
1
BINDIR =        /usr/local/sbin
 
2
MANDIR =        /usr/local/man/man8
 
3
CC =            gcc
 
4
CFLAGS =        -O
 
5
#CFLAGS =       -g
 
6
#SYSVLIBS =     -lnsl -lsocket
 
7
LDFLAGS =       -s ${SYSVLIBS}
 
8
#LDFLAGS =      -g ${SYSVLIBS}
 
9
 
 
10
all:            micro_httpd
39
11
 
40
12
micro_httpd:    micro_httpd.o
41
 
                $(CC) $(CFLAGS) micro_httpd.o $(LDFLAGS) -o micro_httpd
 
13
        ${CC} ${CFLAGS} micro_httpd.o ${LDFLAGS} -o micro_httpd
42
14
 
43
15
micro_httpd.o:  micro_httpd.c
44
 
                $(CC) $(CFLAGS) -c micro_httpd.c
 
16
        ${CC} ${CFLAGS} -c micro_httpd.c
 
17
 
 
18
install:        all
 
19
        rm -f ${BINDIR}/micro_httpd
 
20
        cp micro_httpd ${BINDIR}/micro_httpd
 
21
        rm -f ${MANDIR}/micro_httpd.8
 
22
        cp micro_httpd.8 ${MANDIR}/micro_httpd.8
 
23
 
 
24
clean:
 
25
        rm -f micro_httpd *.o core core.* *.core