alarm/kodi-rpi: fix assignment of *FLAGS

This commit is contained in:
graysky 2022-05-08 09:01:48 -04:00
parent a9cd4e6433
commit f88534895c

View file

@ -116,22 +116,20 @@ build() {
# uses here so unset them and redefine below # uses here so unset them and redefine below
unset CFLAGS CXXFLAGS unset CFLAGS CXXFLAGS
CFLAGS="-O2 -pipe -fstack-protector-strong -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection"
CXXFLAGS="${CFLAGS} -Wp,-D_GLIBCXX_ASSERTIONS"
if [[ $CARCH = "armv7h" ]]; then if [[ $CARCH = "armv7h" ]]; then
# we use -mcpu=cortex-a53 rather than cortex-a72 to maximize RPi 3B and RPi 4B/400 compatibility # we use -mcpu=cortex-a53 rather than cortex-a72 to maximize RPi 3B and RPi 4B/400 compatibility
# in a single package which is consistent with how LibreELEC is currently built, see: # in a single package which is consistent with how LibreELEC is currently built, see:
# https://github.com/LibreELEC/LibreELEC.tv/commit/8e6605f6da56f25a00272b1cbacb93d40200153f#commitcomment-46341034 # https://github.com/LibreELEC/LibreELEC.tv/commit/8e6605f6da56f25a00272b1cbacb93d40200153f#commitcomment-46341034
export CFLAGS+=" -mcpu=cortex-a53 -mfpu=neon-fp-armv8 -mfloat-abi=hard" CFLAGS="-mcpu=cortex-a53 -mfpu=neon-fp-armv8 -mfloat-abi=hard"
export CXXFLAGS="${CFLAGS}"
elif [[ $CARCH = "aarch64" ]]; then elif [[ $CARCH = "aarch64" ]]; then
# note that we use a value of cortex-a53 here to allow RPi3 and RPi4 to use the same package # note that we use a value of cortex-a53 here to allow RPi3 and RPi4 to use the same package
# consistent with rationale of previous comment # consistent with rationale of previous comment
export CFLAGS+=" -mcpu=cortex-a53" CFLAGS="-mcpu=cortex-a53"
export CXXFLAGS="${CFLAGS}"
fi fi
export CFLAGS+=" -O2 -pipe -fstack-protector-strong -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection"
export CXXFLAGS+="${CFLAGS} -Wp,-D_GLIBCXX_ASSERTIONS"
_args=( _args=(
-DCMAKE_BUILD_TYPE=Release -DCMAKE_BUILD_TYPE=Release
-DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_PREFIX=/usr