build: fix issue with "make update-portsref"
... which is only used with "make skim". Since HBSD moves to another git server soon this seems like a good idea to fix.
This commit is contained in:
parent
ba113bc6db
commit
379bf96c4a
7
Makefile
7
Makefile
|
@ -85,10 +85,11 @@ UPLOADDIR?= .
|
|||
_VERSION!= date '+%Y%m%d%H%M'
|
||||
VERSION?= ${_VERSION}
|
||||
STAGEDIRPREFIX?=/usr/obj
|
||||
# XXX GITBASE modifier
|
||||
PORTSREFBASE?= https://github.com/hardenedbsd
|
||||
|
||||
PORTSREFURL?= https://github.com/hardenedbsd/hardenedbsd-ports
|
||||
PORTSREFDIR?= /usr/hardenedbsd-ports
|
||||
PORTSREFBRANCH?=master
|
||||
|
||||
PLUGINSENV?= PLUGIN_PHP=${PHP} PLUGIN_ABI=${SETTINGS} \
|
||||
PLUGIN_PYTHON=${PYTHON3}
|
||||
PLUGINSDIR?= /usr/plugins
|
||||
|
@ -153,7 +154,7 @@ ${STEP}: lint-steps
|
|||
-H "${COREENV}" -u "${UEFI:tl}" -U "${SUFFIX}" \
|
||||
-V "${ADDITIONS}" -O "${GITBASE}" -r "${SERVER}" \
|
||||
-q "${VERSIONS}" -h "${PLUGINSENV}" -I "${UPLOADDIR}" \
|
||||
-D "${DEVELBRANCH}" ${${STEP}_ARGS}
|
||||
-D "${DEVELBRANCH}" -A "${PORTSREFURL}" ${${STEP}_ARGS}
|
||||
.endfor
|
||||
|
||||
.for SCRIPT in ${SCRIPTS}
|
||||
|
|
|
@ -186,7 +186,7 @@ Updating all or individual repositories can be done as follows:
|
|||
|
||||
# make update[-<repo1>[,...]]
|
||||
|
||||
Available update options are: core, plugins, ports, src, tools
|
||||
Available update options are: core, plugins, ports, portsref, src, tools
|
||||
|
||||
Regression tests
|
||||
----------------
|
||||
|
|
|
@ -28,10 +28,13 @@
|
|||
|
||||
set -e
|
||||
|
||||
OPTS="a:B:b:C:c:D:d:E:e:F:f:G:g:H:h:I:K:k:L:l:m:n:O:o:P:p:q:R:r:S:s:T:t:U:u:v:V:"
|
||||
OPTS="A:a:B:b:C:c:D:d:E:e:F:f:G:g:H:h:I:K:k:L:l:m:n:O:o:P:p:q:R:r:S:s:T:t:U:u:v:V:"
|
||||
|
||||
while getopts ${OPTS} OPT; do
|
||||
case ${OPT} in
|
||||
A)
|
||||
export PORTSREFURL=${OPTARG}
|
||||
;;
|
||||
a)
|
||||
export PRODUCT_TARGET=${OPTARG%%:*}
|
||||
export PRODUCT_ARCH=${OPTARG##*:}
|
||||
|
@ -315,7 +318,13 @@ git_clone()
|
|||
|
||||
echo ">>> Cloning ${1}:"
|
||||
|
||||
git clone "${PRODUCT_GITBASE}/$(basename ${1})" ${1}
|
||||
URL=${2}
|
||||
|
||||
if [ -z "${URL}" ]; then
|
||||
URL=${PRODUCT_GITBASE}/$(basename ${1})
|
||||
fi
|
||||
|
||||
git clone "${URL}" ${1}
|
||||
}
|
||||
|
||||
git_pull()
|
||||
|
|
|
@ -37,6 +37,8 @@ if [ -z "${ARGS}" ]; then
|
|||
fi
|
||||
|
||||
for ARG in ${ARGS}; do
|
||||
URL=
|
||||
|
||||
case ${ARG} in
|
||||
core)
|
||||
BRANCHES="${DEVELBRANCH} ${COREBRANCH}"
|
||||
|
@ -51,10 +53,9 @@ for ARG in ${ARGS}; do
|
|||
DIR=${PORTSDIR}
|
||||
;;
|
||||
portsref)
|
||||
# XXX needs GITBASE=https://github.com/hardenedbsd
|
||||
BRANCHES=${PORTSREFBRANCH}
|
||||
DIR=${PORTSREFDIR}
|
||||
ACCOUNT=hardenedbsd
|
||||
URL=${PORTSREFURL}
|
||||
;;
|
||||
src)
|
||||
BRANCHES=${SRCBRANCH}
|
||||
|
@ -69,7 +70,7 @@ for ARG in ${ARGS}; do
|
|||
;;
|
||||
esac
|
||||
|
||||
git_clone ${DIR}
|
||||
git_clone ${DIR} "${URL}"
|
||||
git_fetch ${DIR}
|
||||
for BRANCH in ${BRANCHES}; do
|
||||
git_pull ${DIR} ${BRANCH}
|
||||
|
|
Loading…
Reference in New Issue