Merge pull request #1387 from MilhouseVH/absolute_paths_extra

buildsystem: Create unpack stamps for packages without sources
This commit is contained in:
Christian Hewitt 2017-02-28 09:09:42 +04:00 committed by GitHub
commit eacd31e221
6 changed files with 152 additions and 155 deletions

View File

@ -34,10 +34,6 @@ PKG_CMAKE_SCRIPT="$(get_build_dir $MEDIACENTER)/tools/depends/native/JsonSchemaB
PKG_CMAKE_OPTS_HOST="-Wno-dev"
pre_build_host() {
$SCRIPTS/clean $PKG_NAME
}
makeinstall_host() {
mkdir -p $TOOLCHAIN/bin
cp JsonSchemaBuilder $TOOLCHAIN/bin

View File

@ -35,10 +35,6 @@ PKG_CMAKE_SCRIPT="$(get_build_dir $MEDIACENTER)/tools/depends/native/TexturePack
PKG_CMAKE_OPTS_HOST="-Wno-dev"
pre_build_host() {
$SCRIPTS/clean $PKG_NAME
}
pre_configure_host() {
export CXXFLAGS="$CXXFLAGS -std=c++11 -DTARGET_POSIX -DTARGET_LINUX -D_LINUX -I$(get_build_dir $MEDIACENTER)/xbmc/linux"
}

View File

@ -23,6 +23,7 @@ PKG_LICENSE="GPL"
PKG_SITE="http://www.kodi.tv"
PKG_URL=""
PKG_DEPENDS_TARGET="toolchain kodi"
PKG_NEED_UNPACK="$ROOT/packages/mediacenter/$MEDIACENTER/package.mk"
PKG_SECTION="mediacenter"
PKG_SHORTDESC="kodi-theme-Estuary: Kodi Mediacenter default theme"
PKG_LONGDESC="Kodi Media Center (which was formerly named Xbox Media Center and XBMC) is a free and open source cross-platform media player and home entertainment system software with a 10-foot user interface designed for the living-room TV. Its graphical user interface allows the user to easily manage video, photos, podcasts, and music from a computer, optical disk, local network, and the internet using a remote control."

View File

@ -388,7 +388,6 @@ if [ ! -f $STAMP ]; then
PKG_DEEPMD5=$(find $STAMP_DEPENDS -exec md5sum {} \; 2>/dev/null | sort | md5sum | cut -d" " -f1)
for i in PKG_NAME PKG_DEEPMD5; do
eval val=\$$i
echo "STAMP_$i=\"$val\"" >> $STAMP
echo "STAMP_$i=\"${!i}\"" >> $STAMP
done
fi

View File

@ -29,19 +29,21 @@ clean_package() {
return
fi
for i in $BUILD/$1-*; do
if [ -d $i -a -f "$i/.libreelec-unpack" ] ; then
. "$i/.libreelec-unpack"
STAMP=$PKG_BUILD/.libreelec-unpack
if [ -d "$PKG_BUILD" ]; then
if [ -f "$STAMP" ] ; then
. "$STAMP"
if [ "$STAMP_PKG_NAME" = "$1" ]; then
printf "%${BUILD_INDENT}c ${boldred}*${endcolor} ${red}Removing $i ...${endcolor}\n" ' '>&$SILENT_OUT
rm -rf $i
printf "%${BUILD_INDENT}c ${boldred}*${endcolor} ${red}Removing $PKG_BUILD ...${endcolor}\n" ' '>&$SILENT_OUT
rm -rf "$PKG_BUILD"
fi
else
# force clean if no stamp found (previous unpack failed)
printf "%${BUILD_INDENT}c * Removing $i ...\n" ' '>&$SILENT_OUT
rm -rf $i
printf "%${BUILD_INDENT}c * Removing $PKG_BUILD ...\n" ' '>&$SILENT_OUT
rm -rf "$PKG_BUILD"
fi
fi
done
rm -f $STAMPS/$1/build_*
}

View File

@ -36,14 +36,12 @@ STAMP=$PKG_BUILD/.libreelec-unpack
mkdir -p $BUILD
[ ! -d "$SOURCES/$1" -a ! -d "$PKG_DIR/sources" ] && exit 0
STAMP_DEPENDS="$PKG_DIR $PKG_NEED_UNPACK $PROJECT_DIR/$PROJECT/patches/$PKG_NAME"
[ -n "$DEVICE" ] && STAMP_DEPENDS="$STAMP_DEPENDS $PROJECT_DIR/$PROJECT/devices/$DEVICE/patches/$PKG_NAME"
for i in $BUILD/$1-*; do
if [ -d $i -a -f "$i/.libreelec-unpack" ] ; then
. "$i/.libreelec-unpack"
if [ -d "$PKG_BUILD" ]; then
if [ -f "$STAMP" ] ; then
. "$STAMP"
if [ "$STAMP_PKG_NAME" = "$1" ]; then
PKG_DEEPMD5=$(find $STAMP_DEPENDS -exec md5sum {} \; 2>/dev/null | sort | md5sum | cut -d" " -f1)
if [ ! "$PKG_DEEPMD5" = "$STAMP_PKG_DEEPMD5" ] ; then
@ -51,7 +49,7 @@ for i in $BUILD/$1-*; do
fi
fi
fi
done
fi
if [ -d "$PKG_BUILD" -a ! -f "$STAMP" ]; then
# stale pkg build dir
@ -60,6 +58,7 @@ fi
[ -f "$STAMP" ] && exit 0
if [ -d "$SOURCES/$1" -o -d "$PKG_DIR/sources" ]; then
printf "%${BUILD_INDENT}c ${boldcyan}UNPACK${endcolor} $1\n" ' '>&$SILENT_OUT
export BUILD_INDENT=$((${BUILD_INDENT:-1}+$BUILD_INDENT_SIZE))
@ -184,21 +183,25 @@ if [ "$(type -t post_patch)" = "function" ]; then
post_patch
fi
for config in `find $BUILD/$1* -name config.guess | sed 's/config.guess//'`; do
if [ ! "$PKG_NAME" == "configtools" ] ; then
for config in `find $PKG_BUILD -name config.guess | sed 's/config.guess//'`; do
printf "%${BUILD_INDENT}c ${boldyellow}FIXCONFIG${endcolor} $config\n" ' '
[ -f "$config/config.guess" -a -f $TOOLCHAIN/configtools/config.guess ] && \
cp -f $TOOLCHAIN/configtools/config.guess $config
[ -f "$config/config.sub" -a -f $TOOLCHAIN/configtools/config.sub ] && \
cp -f $TOOLCHAIN/configtools/config.sub $config
fi
done
fi
fi
if [ "$PKG_SECTION" != "virtual" ]; then
mkdir -p $PKG_BUILD
rm -f $STAMPS/$1/build_*
PKG_DEEPMD5=$(find $STAMP_DEPENDS -exec md5sum {} \; 2>/dev/null | sort | md5sum | cut -d" " -f1)
for i in PKG_NAME PKG_DEEPMD5; do
eval val=\$$i
echo "STAMP_$i=\"$val\"" >> $STAMP
echo "STAMP_$i=\"${!i}\"" >> $STAMP
done
fi