File: Makefile

package info (click to toggle)
osdsh 0.7.0-10.2
  • links: PTS
  • area: main
  • in suites: stretch
  • size: 452 kB
  • ctags: 346
  • sloc: ansic: 1,063; tcl: 335; makefile: 73
file content (48 lines) | stat: -rw-r--r-- 888 bytes parent folder | download | duplicates (3)
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
CC     = gcc
PREFIX = /usr
BINDIR = $(PREFIX)/bin
DOCDIR = $(PREFIX)/doc/osdsh
LIBDIR = -L/usr/X11R6/lib -L/usr/lib
LIBS   = $(LIBDIR) -lxosd -lpthread
CFLAGS = -O3 -rdynamic

#APMOBJS = apmwatch.o
#APMLIBS = -lapm
#APM=1

OBJS   =  controlsh.o utils.o

all: osdsh libs

libs: libosdshclock.so libosdshmixer.so libosdshapm.so libosdshnet.so

%.o: %.c

	gcc -fPIC -c $<

osdsh: $(OBJS)
	gcc -c $(CFLAGS) $@.c
	gcc $(CFLAGS) -o $@ osdsh.o $(OBJS) $(LIBS) -ldl

clean: libclean
	rm -f osdsh
	rm -f *.o

libclean:
	rm -f libosdsh*.so

libosdshclock.so: 
	gcc -fPIC -c clockdisplay.c
	gcc -shared -o $@ clockdisplay.o utils.o

libosdshmixer.so:
	gcc -fPIC -c mixerwatch.c
	gcc -shared -o $@ mixerwatch.o utils.o

libosdshapm.so:
	gcc -fPIC -c apmwatch.c
	gcc -shared -o $@ apmwatch.o utils.o -lapm

libosdshnet.so: 
	gcc -fPIC -c connectionwatch.c
	gcc -shared -o $@ connectionwatch.o utils.o