File: Makefile

package info (click to toggle)
uml-utilities 20060323-3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 660 kB
  • ctags: 413
  • sloc: ansic: 3,231; perl: 930; makefile: 224; sh: 215; exp: 129
file content (36 lines) | stat: -rw-r--r-- 860 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
TUNCTL = $(shell [ -e /usr/include/linux/if_tun.h ] && echo tunctl)

SUBDIRS = jail jailtest humfsify mconsole moo port-helper $(TUNCTL) uml_net \
	uml_switch watchdog
UMLVER = $(shell date +%Y%m%d)
TARBALL = uml_utilities_$(UMLVER).tar.bz2
BIN_DIR = /usr/bin

ifeq ($(shell uname -m),x86_64)
LIB_DIR = /usr/lib64/uml
else
LIB_DIR = /usr/lib/uml
endif

CFLAGS = -g -Wall
#CFLAGS = -g -O2 -Wall

export BIN_DIR LIB_DIR CFLAGS

all install: 
	set -e ; for dir in $(SUBDIRS); do $(MAKE) -C $$dir $@; done

tarball : clean spec
	cd .. ;					\
	mv tools tools-$(UMLVER);		\
	tar cjf $(TARBALL) tools-$(UMLVER);	\
	mv tools-$(UMLVER) tools

clean:
	rm -rf *~
	rm -f uml_util.spec
	find . -iname tags|xargs --no-run-if-empty rm
	set -e ; for dir in $(SUBDIRS); do $(MAKE) -C $$dir $@; done

spec:	
	sed -e 's/__UMLVER__/$(UMLVER)/' < uml_util.spec.in > uml_util.spec