build: don't copy packages to output directory for targets without opkg
Fixes #1126
This commit is contained in:
parent
a7ea424214
commit
ad91ab1be7
@ -30,6 +30,10 @@ sysupgrade() {
|
||||
:
|
||||
}
|
||||
|
||||
no_opkg() {
|
||||
:
|
||||
}
|
||||
|
||||
|
||||
unknown_devices="$DEVICES"
|
||||
|
||||
|
@ -19,6 +19,8 @@ factory_suffix=
|
||||
sysupgrade_ext=
|
||||
sysupgrade_suffix=
|
||||
|
||||
no_opkg=
|
||||
|
||||
|
||||
mkdir -p "${GLUON_IMAGEDIR}/factory" "${GLUON_IMAGEDIR}/sysupgrade"
|
||||
|
||||
@ -146,10 +148,15 @@ sysupgrade() {
|
||||
fi
|
||||
}
|
||||
|
||||
no_opkg() {
|
||||
no_opkg=1
|
||||
}
|
||||
|
||||
|
||||
. targets/"$1"; copy
|
||||
|
||||
# Copy opkg repo
|
||||
if [ -z "$DEVICES" ]; then
|
||||
if [ -z "$no_opkg" -a -z "$DEVICES" ]; then
|
||||
rm -f "$GLUON_PACKAGEDIR"/*/"$LEDE_BINDIR"/*
|
||||
rmdir -p "$GLUON_PACKAGEDIR"/*/"$LEDE_BINDIR" 2>/dev/null || true
|
||||
mkdir -p "${GLUON_PACKAGEDIR}/${PACKAGE_PREFIX}/${LEDE_BINDIR}"
|
||||
|
18
scripts/target_config.inc.sh
Normal file
18
scripts/target_config.inc.sh
Normal file
@ -0,0 +1,18 @@
|
||||
site_packages() {
|
||||
MAKEFLAGS= make print PROFILE="$1" --no-print-directory -s -f - <<'END_MAKE'
|
||||
include $(GLUON_SITEDIR)/site.mk
|
||||
|
||||
print:
|
||||
echo '$(GLUON_$(PROFILE)_SITE_PACKAGES)'
|
||||
END_MAKE
|
||||
}
|
||||
|
||||
|
||||
. scripts/common.inc.sh
|
||||
|
||||
|
||||
no_opkg() {
|
||||
config '# CONFIG_SIGNED_PACKAGES is not set'
|
||||
config 'CONFIG_CLEAN_IPKG=y'
|
||||
packages '-opkg'
|
||||
}
|
@ -14,16 +14,6 @@ profile_packages=
|
||||
LEDE_CONFIG_TARGET="${LEDE_TARGET//-/_}"
|
||||
|
||||
|
||||
site_packages() {
|
||||
MAKEFLAGS= make PROFILE="$1" --no-print-directory -s -f - <<'END_MAKE'
|
||||
include $(GLUON_SITEDIR)/site.mk
|
||||
|
||||
all:
|
||||
echo '$(GLUON_$(PROFILE)_SITE_PACKAGES)'
|
||||
END_MAKE
|
||||
}
|
||||
|
||||
|
||||
emit() {
|
||||
[ "${output}" ] || return 0
|
||||
want_device "${output}" || return 0
|
||||
@ -39,7 +29,7 @@ emit() {
|
||||
}
|
||||
|
||||
|
||||
. scripts/common.inc.sh
|
||||
. scripts/target_config.inc.sh
|
||||
|
||||
config() {
|
||||
echo "$1"
|
||||
|
@ -14,16 +14,6 @@ ret=0
|
||||
LEDE_CONFIG_TARGET="${LEDE_TARGET//-/_}"
|
||||
|
||||
|
||||
site_packages() {
|
||||
MAKEFLAGS= make PROFILE="$1" --no-print-directory -s -f - <<'END_MAKE'
|
||||
include $(GLUON_SITEDIR)/site.mk
|
||||
|
||||
all:
|
||||
echo '$(GLUON_$(PROFILE)_SITE_PACKAGES)'
|
||||
END_MAKE
|
||||
}
|
||||
|
||||
|
||||
fail() {
|
||||
local message="$1"
|
||||
|
||||
@ -49,7 +39,7 @@ check_package() {
|
||||
}
|
||||
|
||||
|
||||
. scripts/common.inc.sh
|
||||
. scripts/target_config.inc.sh
|
||||
|
||||
config() {
|
||||
local config="$1"
|
||||
|
@ -1,6 +1,5 @@
|
||||
config '# CONFIG_SIGNED_PACKAGES is not set'
|
||||
config 'CONFIG_CLEAN_IPKG=y'
|
||||
packages '-opkg' '-uboot-envtools' '-kmod-usb-core' '-kmod-usb-ohci' '-kmod-usb2' '-kmod-usb-ledtrig-usbport'
|
||||
no_opkg
|
||||
packages '-uboot-envtools' '-kmod-usb-core' '-kmod-usb-ohci' '-kmod-usb2' '-kmod-usb-ledtrig-usbport'
|
||||
|
||||
|
||||
# D-Link
|
||||
|
Loading…
Reference in New Issue
Block a user