File: Makefile

package info (click to toggle)
wmfrog 0.3.1%2Bgit20161115-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 460 kB
  • sloc: ansic: 677; perl: 267; makefile: 51
file content (37 lines) | stat: -rw-r--r-- 837 bytes parent folder | download | duplicates (4)
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
CC     = gcc
CFLAGS = -g #-O2 -Wall
INCDIR = -I/usr/X11R6/include/X11 -I/usr/X11R6/include
LIBDIR = -L/usr/X11R6/lib
# for linux
LIBS   = -lXpm -lX11 -lXext
# for Solaris
# LIBS   = -lXpm -lX11 -lXext -lsocket
PREFIX=/usr

OBJS   = wmfrog.o \
         xutils.o


.c.o:
	$(CC) $(CPPFLAGS) $(CFLAGS) -D$(shell echo `uname -s`) -c $< -o $*.o $(INCDIR)


all:	wmfrog.o wmfrog 

wmfrog.o: frog.xpm frog.xbm
wmfrog:	$(OBJS) 
	$(CC) $(LDFLAGS) $(SYSTEM) -o wmfrog $^ $(INCDIR) $(LIBDIR) $(LIBS)
install:
		mkdir -p "$(DESTDIR)$(PREFIX)/bin"
		mkdir -p "$(DESTDIR)$(PREFIX)/share/wmfrog"
		mkdir -p "$(DESTDIR)$(PREFIX)/share/man/man1"
		cp wmfrog "$(DESTDIR)$(PREFIX)/bin"
		cp weather.pl "$(DESTDIR)$(PREFIX)/share/wmfrog"
		cp wmfrog.1 "$(DESTDIR)$(PREFIX)/share/man/man1"
clean:
	for i in $(OBJS) ; do \
		rm -f $$i; \
	done
	rm -f wmfrog