summaryrefslogtreecommitdiffstats
path: root/package/x11r7/xproto_xproto
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2009-07-18 00:16:48 +0200
committerPeter Korsgaard <jacmet@sunsite.dk>2009-07-18 00:16:48 +0200
commitd0f902e82ed70db599325894d3ab58428164ef08 (patch)
tree45a2ca9bab5100f39f65492bfe437e0a9107be7c /package/x11r7/xproto_xproto
parentadfd17b0bcc43124e13d869e8ffd186e30232b03 (diff)
downloadbuildroot-novena-d0f902e82ed70db599325894d3ab58428164ef08.tar.gz
buildroot-novena-d0f902e82ed70db599325894d3ab58428164ef08.zip
mesa3d: compile makedepend (and in turn xproto) for the host
The mesa3d build needs makedepend on the host, so compile one in $HOST_DIR. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package/x11r7/xproto_xproto')
-rw-r--r--package/x11r7/xproto_xproto/xproto_xproto.mk43
1 files changed, 43 insertions, 0 deletions
diff --git a/package/x11r7/xproto_xproto/xproto_xproto.mk b/package/x11r7/xproto_xproto/xproto_xproto.mk
index 9d4faf4f6..d46743e09 100644
--- a/package/x11r7/xproto_xproto/xproto_xproto.mk
+++ b/package/x11r7/xproto_xproto/xproto_xproto.mk
@@ -12,3 +12,46 @@ XPROTO_XPROTO_INSTALL_STAGING = YES
XPROTO_XPROTO_INSTALL_TARGET = NO
$(eval $(call AUTOTARGETS,package/x11r7,xproto_xproto))
+
+# xproto_xproto for the host
+XPROTO_XPROTO_HOST_DIR:=$(BUILD_DIR)/xproto_xproto-$(XPROTO_XPROTO_VERSION)-host
+
+$(DL_DIR)/$(XPROTO_XPROTO_SOURCE):
+ $(call DOWNLOAD,$(XPROTO_XPROTO_SITE),$(XPROTO_XPROTO_SOURCE))
+
+$(STAMP_DIR)/host_xproto_xproto_unpacked: $(DL_DIR)/$(XPROTO_XPROTO_SOURCE)
+ mkdir -p $(XPROTO_XPROTO_HOST_DIR)
+ $(INFLATE$(suffix $(XPROTO_XPROTO_SOURCE))) $< | \
+ $(TAR) $(TAR_STRIP_COMPONENTS)=1 -C $(XPROTO_XPROTO_HOST_DIR) $(TAR_OPTIONS) -
+ touch $@
+
+$(STAMP_DIR)/host_xproto_xproto_configured: $(STAMP_DIR)/host_xproto_xproto_unpacked
+ (cd $(XPROTO_XPROTO_HOST_DIR); rm -rf config.cache; \
+ $(HOST_CONFIGURE_OPTS) \
+ CFLAGS="$(HOST_CFLAGS)" \
+ LDFLAGS="$(HOST_LDFLAGS)" \
+ ./configure \
+ --prefix="$(HOST_DIR)/usr" \
+ --sysconfdir="$(HOST_DIR)/etc" \
+ )
+ touch $@
+
+$(STAMP_DIR)/host_xproto_xproto_compiled: $(STAMP_DIR)/host_xproto_xproto_configured
+ $(HOST_MAKE_ENV) $(MAKE) -C $(XPROTO_XPROTO_HOST_DIR)
+ touch $@
+
+$(STAMP_DIR)/host_xproto_xproto_installed: $(STAMP_DIR)/host_xproto_xproto_compiled
+ $(MAKE) -C $(XPROTO_XPROTO_HOST_DIR) install
+ touch $@
+
+host-xproto_xproto: $(STAMP_DIR)/host_xproto_xproto_installed
+
+host-xproto_xproto-source: xproto_xproto-source
+
+host-xproto_xproto-clean:
+ rm -f $(addprefix $(STAMP_DIR)/host_xproto_xproto_,unpacked configured compiled installed)
+ -$(MAKE) -C $(XPROTO_XPROTO_HOST_DIR) uninstall
+ -$(MAKE) -C $(XPROTO_XPROTO_HOST_DIR) clean
+
+host-xproto_xproto-dirclean:
+ rm -rf $(XPROTO_XPROTO_HOST_DIR)