source: trunk/athena/bin/machtype/debian/rules @ 23962

Revision 23962, 1.6 KB checked in by broder, 15 years ago (diff)
In machtype: * Remove some crufty (and likely incompatible) sysnames from the compatibility list.
  • Property svn:executable set to *
Line 
1#!/usr/bin/make -f
2
3DEB_AUTO_UPDATE_AUTOCONF = 2.50
4include /usr/share/cdbs/1/rules/debhelper.mk
5include /usr/share/cdbs/1/class/autotools.mk
6
7ATHENA_MAJOR_VERSION = 10
8ATHENA_MINOR_VERSION = 0
9
10DEBIAN_VERSION = $(shell dpkg-query --showformat='$${Version}' --show base-files)
11
12SYS_COMPAT=
13
14ifneq ($(shell dpkg --compare-versions $(DEBIAN_VERSION) '>=' '3.1' && echo y),y)
15    $(error Debian version $(DEBIAN_VERSION) is too old)
16endif
17
18ifeq ($(shell dpkg --compare-versions $(DEBIAN_VERSION) '>=' '4.0.4' && echo y),y)
19    ifeq ($(DEB_BUILD_ARCH),amd64)
20        SYS_COMPAT += amd64_deb50 i386_deb50
21    else
22        ifeq ($(DEB_BUILD_ARCH),i386)
23            SYS_COMPAT += i386_deb50
24        else
25            $(error Unrecognized architecture $(DEB_BUILD_ARCH))
26        endif
27    endif
28endif
29
30ifeq ($(shell dpkg --compare-versions $(DEBIAN_VERSION) '>=' '4' && echo y),y)
31    ifeq ($(DEB_BUILD_ARCH),amd64)
32        SYS_COMPAT += amd64_deb40 i386_deb40 i386_rhel4
33    else
34        ifeq ($(DEB_BUILD_ARCH),i386)
35            SYS_COMPAT += i386_deb40 i386_rhel4
36        else
37            $(error Unrecognized architecture $(DEB_BUILD_ARCH))
38        endif
39    endif
40endif
41
42SYS_COMPAT += i386_rhel3 i386_linux24
43
44ATHENA_SYS = $(word 1, $(SYS_COMPAT))
45ATHENA_SYS_COMPAT = $(patsubst %:,%,$(subst : ,:,$(patsubst %,%:,$(wordlist 2, $(words $(SYS_COMPAT)), $(SYS_COMPAT)))))
46
47DEB_CONFIGURE_EXTRA_FLAGS += lbindir=/bin \
48        ATHENA_SYS=$(ATHENA_SYS) \
49        ATHENA_SYS_COMPAT=$(ATHENA_SYS_COMPAT) \
50        ATHENA_MAJOR_VERSION=$(ATHENA_MAJOR_VERSION) \
51        ATHENA_MINOR_VERSION=$(ATHENA_MINOR_VERSION)
52
53clean::
54        rm -f configure
Note: See TracBrowser for help on using the repository browser.