[go: up one dir, main page]

File: Makefile

package info (click to toggle)
uml-utilities 20070815-1.3
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 740 kB
  • sloc: ansic: 3,390; perl: 1,277; makefile: 253; sh: 175; exp: 129
file content (35 lines) | stat: -rw-r--r-- 823 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
TUNCTL = $(shell [ -e /usr/include/linux/if_tun.h ] && echo tunctl)

SUBDIRS = lib jail jailtest humfsify mconsole moo port-helper $(TUNCTL) \
	uml_net uml_switch watchdog umlfs
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
	set -e ; for dir in $(SUBDIRS); do $(MAKE) -C $$dir $@; done

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