build/ports: only add aux.conf if packages step has not been executed
For hotfixes it will start to build go and rust even if it does not need it. For the cases where e.g. suricata rebuild requires rust use the non-packaged packages set or let rust build during dependecy build.
This commit is contained in:
parent
c3f66077b4
commit
553bf8a787
|
@ -684,14 +684,15 @@ check_packages()
|
|||
PACKAGESET=$(find ${SETSDIR} -name "packages-*-${PRODUCT_FLAVOUR}-${PRODUCT_ARCH}.tar")
|
||||
|
||||
if [ -z "${SELF}" -o -z "${PACKAGESET}" -o -n "${SKIP}" ]; then
|
||||
return
|
||||
return 1
|
||||
fi
|
||||
|
||||
DONE=$(tar tf ${PACKAGESET} | grep "^\./\.${SELF}_done\$" || true)
|
||||
if [ -n "${DONE}" ]; then
|
||||
echo ">>> Packages (${SELF}) are up to date"
|
||||
exit 0
|
||||
return 0
|
||||
fi
|
||||
|
||||
return 1
|
||||
}
|
||||
|
||||
extract_packages()
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Copyright (c) 2014-2020 Franco Fichtner <franco@opnsense.org>
|
||||
# Copyright (c) 2014-2021 Franco Fichtner <franco@opnsense.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
|
@ -31,7 +31,10 @@ SELF=core
|
|||
|
||||
. ./common.sh
|
||||
|
||||
check_packages ${SELF} ${@}
|
||||
if check_packages ${SELF} ${@}; then
|
||||
echo ">>> Step ${SELF} is up to date"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
git_branch ${COREDIR} ${COREBRANCH} COREBRANCH
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Copyright (c) 2015-2020 Franco Fichtner <franco@opnsense.org>
|
||||
# Copyright (c) 2015-2021 Franco Fichtner <franco@opnsense.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
|
@ -57,7 +57,10 @@ done
|
|||
)
|
||||
fi
|
||||
|
||||
check_packages ${SELF} ${@}
|
||||
if check_packages ${SELF} ${@}; then
|
||||
echo ">>> Step ${SELF} is up to date"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
git_branch ${PLUGINSDIR} ${PLUGINSBRANCH} PLUGINSBRANCH
|
||||
|
||||
|
|
|
@ -31,9 +31,21 @@ SELF=ports
|
|||
|
||||
. ./common.sh
|
||||
|
||||
if check_packages ${SELF} ${@}; then
|
||||
echo ">>> Step ${SELF} is up to date"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
PORTCONFIGS="${CONFIGDIR}/ports.conf"
|
||||
|
||||
# inject auxiliary ports only if not already removed
|
||||
if check_packages packages; then
|
||||
PORTCONFIGS="${CONFIGDIR}/aux.conf ${PORTCONFIGS}"
|
||||
fi
|
||||
|
||||
if [ -z "${PORTS_LIST}" ]; then
|
||||
PORTS_LIST=$(
|
||||
cat ${CONFIGDIR}/aux.conf ${CONFIGDIR}/ports.conf | while read PORT_ORIGIN PORT_IGNORE; do
|
||||
cat ${PORTCONFIGS} | while read PORT_ORIGIN PORT_IGNORE; do
|
||||
eval PORT_ORIGIN=${PORT_ORIGIN}
|
||||
if [ "$(echo ${PORT_ORIGIN} | colrm 2)" = "#" ]; then
|
||||
continue
|
||||
|
@ -58,8 +70,6 @@ done
|
|||
)
|
||||
fi
|
||||
|
||||
check_packages ${SELF} ${@}
|
||||
|
||||
git_branch ${SRCDIR} ${SRCBRANCH} SRCBRANCH
|
||||
git_branch ${PORTSDIR} ${PORTSBRANCH} PORTSBRANCH
|
||||
|
||||
|
|
Loading…
Reference in New Issue