mirror of
https://github.com/raz0red/wii7800.git
synced 2024-05-15 19:34:43 -04:00
Updated dist to build in specified directory
Avoids any issues from building via mount
This commit is contained in:
parent
48c2788266
commit
28816bd98d
2
.github/workflows/main.yml
vendored
2
.github/workflows/main.yml
vendored
|
@ -12,7 +12,7 @@ jobs:
|
|||
with:
|
||||
submodules: recursive
|
||||
- run: docker run raz0red/devkitppc /opt/devkitpro/pacman/bin/pacman -Q
|
||||
- run: docker run -v $(pwd):/source raz0red/devkitppc /source/dist.sh
|
||||
- run: docker run -v $(pwd):/source raz0red/devkitppc /source/dist.sh /tmp/wii7800
|
||||
- uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: dist
|
||||
|
|
23
dist.sh
23
dist.sh
|
@ -22,6 +22,29 @@ function fail() {
|
|||
exit 1
|
||||
}
|
||||
|
||||
#
|
||||
# Build in directory specified (if applicable)
|
||||
#
|
||||
if [ ! -z $1 ]; then
|
||||
BUILD_DIR=$1
|
||||
echo "Building in: $BUILD_DIR..."
|
||||
rm -rf $BUILD_DIR \
|
||||
|| { fail 'Unable to delete build directory.'; }
|
||||
cp -R $SCRIPTPATH $BUILD_DIR \
|
||||
|| { fail 'Unable to copy files to build directory.'; }
|
||||
find $BUILD_DIR -type f \
|
||||
\( -name "*.o" -or -name "*.a" -or -name "*.dol" -or -name "*.elf" \) \
|
||||
-exec rm {} + \
|
||||
|| { fail 'Unable to delete previous build output files.'; }
|
||||
$BUILD_DIR/dist.sh \
|
||||
|| { fail 'Error running dist script.'; }
|
||||
rm -rf $DIST_DIR \
|
||||
|| { fail 'Unable to remove dist directory.'; }
|
||||
cp -R $BUILD_DIR/dist $DIST_DIR \
|
||||
|| { fail 'Unable to copy files to final dist directory.'; }
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Build wii-emucommon
|
||||
echo "Building wii-emucommon..."
|
||||
$EMUCOMMON_DIR/dist.sh || { fail 'Error building wii-emucommon.'; }
|
||||
|
|
Loading…
Reference in a new issue