summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Reding <[email protected]>2006-10-16 10:03:32 +0000
committerThierry Reding <[email protected]>2006-10-16 10:03:32 +0000
commit5cef6ca36a699a37d647da19b3d1746f1d6348c1 (patch)
tree015d397fa730a79c3348cced988d3d84a7c01d3d
parentbe2b518f7bd69197c9f71708893008e1ec8adc5e (diff)
Move the detection of architecture-specific configurations to the debian/rules
file. Add the configs target to debian/rules for checking whether the correct configurations will be built.
-rw-r--r--configs/debian-dri-arch13
-rw-r--r--configs/debian-swx11+glu-arch15
-rwxr-xr-xdebian/rules52
3 files changed, 34 insertions, 46 deletions
diff --git a/configs/debian-dri-arch b/configs/debian-dri-arch
deleted file mode 100644
index b5785409359..00000000000
--- a/configs/debian-dri-arch
+++ /dev/null
@@ -1,13 +0,0 @@
-# Configuration for building a version of the DRI drivers optimized for the
-# build architecture.
-
-ifneq ($(wildcard $(TOP)/configs/debian-dri-$(DEB_BUILD_ARCH)),)
- include $(TOP)/configs/debian-dri-$(DEB_BUILD_ARCH)
-else
- include $(TOP)/configs/debian-dri-any
-endif
-
-CONFIG_NAME = debian-dri-arch
-
-# vim: ft=make
-
diff --git a/configs/debian-swx11+glu-arch b/configs/debian-swx11+glu-arch
deleted file mode 100644
index 3c02fbe5819..00000000000
--- a/configs/debian-swx11+glu-arch
+++ /dev/null
@@ -1,15 +0,0 @@
-# Configuration for building a version of swx11 and libGLU optimized for the
-# build architecture.
-
-ifneq ($(wildcard $(TOP)/configs/debian-swx11+glu-$(DEB_BUILD_ARCH)),)
- include $(TOP)/configs/debian-swx11+glu-$(DEB_BUILD_ARCH)
-else
- include $(TOP)/configs/debian-swx11+glu-any
-endif
-
-CONFIG_NAME = debian-swx11+glu-arch
-
-override SRC_DIRS = mesa glu
-
-# vim: ft=make
-
diff --git a/debian/rules b/debian/rules
index 6abe4968d05..ef8b0fa31f0 100755
--- a/debian/rules
+++ b/debian/rules
@@ -26,45 +26,61 @@ DEB_BUILD_DIR ?= $(CURDIR)/obj-$(DEB_BUILD_GNU_TYPE)
export DEB_BUILD_ARCH
-# build the following configurations
-CONFIGS = debian-swx11+glu-arch \
- debian-dri-arch \
- debian-osmesa16 \
- debian-osmesa16-static \
- debian-osmesa32 \
- debian-osmesa32-static \
- debian-static
+# choose an architecture-specific configuration for building swx11 and GLU if
+# one exists
+ifneq ($(wildcard configs/debian-swx11+glu-$(DEB_BUILD_ARCH)),)
+ SWX11_GLU_CONFIGS := debian-swx11+glu-$(DEB_BUILD_ARCH)
+else
+ SWX11_GLU_CONFIGS := debian-swx11+glu-any
+endif
# additional configurations optimized for CPU's supported by the build
# architecture
ifeq ($(DEB_BUILD_ARCH), i386)
- CONFIGS += debian-i386-i686
+ SWX11_GLU_CONFIGS += debian-swx11+glu-i386-i686
endif
#ifeq ($(DEB_BUILD_ARCH), alpha)
-# CONFIGS += debian-alpha-ev5
+# SWX11_GLU_CONFIGS += debian-swx11+glu-alpha-ev5
#endif
#ifeq ($(DEB_BUILD_ARCH), powerpc)
-# CONFIGS += debian-powerpc-603
-#endif
-
-#ifeq ($(DEB_BUILD_ARCH), ppc64)
-# CONFIGS += debian-ppc64
+# SWX11_GLU_CONFIGS += debian-swx11+glu-powerpc-603
#endif
#ifeq ($(DEB_BUILD_ARCH), sparc)
-# CONFIGS += debian-sparc-ultrasparc
+# SWX11_GLU_CONFIGS += debian-swx11+glu-sparc-ultrasparc
#endif
# Use the following to automatically build all optimized configurations
# available for the build architecture. Use with caution =)
-#CONFIGS += $(subst configs/,,$(wildcard configs/debian-$(DEB_BUILD_ARCH)*))
+#SWX11_GLU_CONFIGS += $(subst configs/,,$(wildcard configs/debian-swx11+glu-$(DEB_BUILD_ARCH)-*))
+
+# choose an architecture-specific configuration for building the DRI-enabled
+# libGL if one exists
+ifneq ($(wildcard configs/debian-dri-$(DEB_BUILD_ARCH)),)
+ DRI_CONFIGS := debian-dri-$(DEB_BUILD_ARCH)
+else
+ DRI_CONFIGS := debian-dri-any
+endif
+
+# build the following configurations by default
+CONFIGS = $(SWX11_GLU_CONFIGS) \
+ $(DRI_CONFIGS) \
+ debian-osmesa16 \
+ debian-osmesa16-static \
+ debian-osmesa32 \
+ debian-osmesa32-static \
+ debian-static
STAMP = $(STAMP_DIR)/$(DEB_BUILD_GNU_TYPE)
BUILD_STAMPS = $(addprefix $(STAMP)-build-, $(CONFIGS))
INSTALL_STAMPS = $(addprefix $(STAMP)-install-, $(CONFIGS))
+# list the configurations that will built
+configs:
+ @echo Building the following configurations: $(CONFIGS)
+
$(STAMP_DIR):
dh_testdir
mkdir -p $@
@@ -127,5 +143,5 @@ binary-arch: build install
dh_builddeb
binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install configure
+.PHONY: configs build clean binary-indep binary-arch binary install configure