Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
maron2000 committed Oct 7, 2023
1 parent fcf513f commit 3dc4cb2
Showing 1 changed file with 27 additions and 16 deletions.
43 changes: 27 additions & 16 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,20 +44,23 @@ jobs:
make dosbox-x.app
echo "install lib"
cd dosbox-x.app/Contents/MacOS
echo "get list of libraries required"
INSTALL_LIBS=($(otool -L dosbox-x | grep '¥w*@executable.*' - | sed -n -r 's#.+/(lib.*dylib).*#¥1#p'))
echo "get list of libraries required"
INSTALL_LIBS=($(otool -L dosbox-x | grep '\w*@executable.*' - | sed -n -r 's#.+/(lib.*dylib).*#\1#p'))
for i in ${INSTALL_LIBS[@]}
do
j=($(echo $i | sed -E 's|([^¥.^¥-]+).*dylib|¥1|p'))
#echo $j
FILE=($(find -H /usr/** -name $j*.*.dylib 2>/dev/null))
if [ -z "$FILE" ]
j=($(echo $i | sed -E 's|([^¥.^¥-]+).*dylib|\1|p'))
echo $j
FILE=($(find -H /usr/local/opt/** -name $j*.*.dylib 2>/dev/null))
if [ -z $FILE ]
then
FILE=($(find -H /usr/** -name $j*.*.dylib 2>/dev/null))
fi
if [ ! -z $FILE ]
then
FILE=($(find -H /System/** -name $j*.*.dylib 2>/dev/null))
echo ${FILE}
cp ${FILE} arm64/$i
#cp ${FILE} x86_64/$i #currently searches arm64 directory regardless of platform
fi
echo ${FILE}
cp ${FILE} arm64/$i
#cp ${FILE} x86_64/$i #currently searches arm64 directory regardless of platform
done
cd $top
mv dosbox-x.app $top/package/dosbox-x
Expand All @@ -72,14 +75,22 @@ jobs:
strip $top/src/dosbox-x
make dosbox-x.app
cd dosbox-x.app/Contents/MacOS
INSTALL_LIBS=($(otool -L dosbox-x | grep '¥w*@executable.*' - | sed -n -r 's#.+/(lib.*dylib).*#¥1#p')) for i in ${INSTALL_LIBS[@]}
INSTALL_LIBS=($(otool -L dosbox-x | grep '\w*@executable.*' - | sed -n -r 's#.+/(lib.*dylib).*#\1#p'))
for i in ${INSTALL_LIBS[@]}
do
j=($(echo $i | sed -E 's|([^¥.^¥-]+).*dylib|¥1|p'))
j=($(echo $i | sed -E 's|([^¥.^¥-]+).*dylib|\1|p'))
echo $j
FILE=($(find -H /usr/** -name $j*.*.dylib 2>/dev/null))
echo ${FILE}
cp ${FILE} arm64/$i
#cp ${FILE} x86_64/$i #currently searches arm64 directory regardless of platform
FILE=($(find -H /usr/local/opt/** -name $j*.*.dylib 2>/dev/null))
if [ -z $FILE ]
then
FILE=($(find -H /usr/** -name $j*.*.dylib 2>/dev/null))
fi
if [ ! -z $FILE ]
then
echo ${FILE}
cp ${FILE} arm64/$i
#cp ${FILE} x86_64/$i #currently searches arm64 directory regardless of platform
fi
done
cd $top
mv dosbox-x.app $top/package/dosbox-x-sdl2
Expand Down

0 comments on commit 3dc4cb2

Please sign in to comment.