xbps-src: find out the correct path for XBPS_DISTRIBUTIONDIR in the build process.

--HG--
rename : xbps-src/etc/xbps-src.conf => xbps-src/etc/xbps-src.conf.in
This commit is contained in:
Juan RP 2010-12-21 12:33:46 +01:00
parent de2065a257
commit 4616674b86
2 changed files with 12 additions and 1 deletions

View file

@ -1,12 +1,23 @@
include ../vars.mk
# Find out the real path for the xbps-src distribdir.
_CURDIR = $(shell dirname $(shell pwd))
ifeq ($(shell basename ${_CURDIR}), xbps-src)
DISTRIBDIR = $(subst /xbps-src,,${_CURDIR})
else
DISTRIBDIR = ${_CURDIR}
endif
CONF_FILE = xbps-src.conf
.PHONY: all
all:
sed -e "s|@@XBPS_DISTRIBDIR@@|${DISTRIBDIR}|" \
${CONF_FILE}.in > ${CONF_FILE}
.PHONY: clean
clean:
-rm -f ${CONF_FILE}
.PHONY: install
install:

View file

@ -6,7 +6,7 @@
# Directory where the xbps-src GIT repository is stored. This is
# required to be mounted in the chroot.
#
XBPS_DISTRIBUTIONDIR=$HOME/xbps-templates
XBPS_DISTRIBUTIONDIR=@@XBPS_DISTRIBDIR@@
#
# Chroot master directory.