Skip to content

Commit

Permalink
xCFrameworks fix
Browse files Browse the repository at this point in the history
  • Loading branch information
danoli3 committed Aug 3, 2024
1 parent f308e46 commit 05443c9
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 11 deletions.
11 changes: 4 additions & 7 deletions apothecary/apothecary
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,8 @@ trapError() {
while getopts t:a:b:d:s:j:m:c:hgvxfpewy opt ; do
case "$opt" in
t) # set the library build type
export TYPE="$OPTARG" ;;
export TYPE="$OPTARG";;
#export TARGET=$TYPE
a) # set the architecture
export ARCH=$OPTARG
if [ -z "${ARCH+x}" ]; then
Expand Down Expand Up @@ -1547,10 +1548,8 @@ function frameworkFormula() {

if [ ! -e "$LIBS_DIR/$1" ] ; then
echoVerbose " Nothing to create framework from to merge in lib dest dir: \"$1\""
exit 0;
elif [ $1 == "pkg-config" ] ; then
elif [ $1 == "pkg-config" ] || [ $1 == "kiss" ]; then
echoVerbose " No need to create framework for: \"$1\""
exit 0;
else
rm -rf $LIBS_DIR_REAL/$1/lib/$TYPE/*.xcframework

Expand Down Expand Up @@ -1831,10 +1830,8 @@ function xframeworkFormula() {

if [ ! -e "$LIBS_DIR/$1" ] ; then
echoVerbose " Nothing to create framework from to merge in lib dest dir: \"$1\""
exit 0;
elif [ $1 == "pkg-config" ] ; then
elif [[ "$1" =~ ^(kiss|portaudio|pkg-config|videoInput)$ ]]; then
echoVerbose " No need to create framework for: \"$1\""
exit 0;
else
# rm -rf $LIBS_DIR_REAL/$1/lib/$TYPE/*.xcframework

Expand Down
4 changes: 2 additions & 2 deletions scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ function travis_nanoseconds() {
}

if [ -z ${PARALLEL+x} ]; then
if [ "$TARGET" == "osx" ]; then
if [ "$TARGET" == "osx" ] || [ "$TARGET" == "macos" ]; then
PARALLEL=4
elif [ "$TARGET" == "ios" ] || [ "$TARGET" == "tvos" ]; then
PARALLEL=2
Expand Down Expand Up @@ -222,7 +222,7 @@ if type "ccache" > /dev/null; then
fi

if [ "$TARGET" == "linux" ]; then
TARGET="linux64"
export TARGET="linux64"
if [ "$OPT" == "gcc5" ]; then
export CC="gcc-5"
export CXX="g++-5 -std=c++11"
Expand Down
39 changes: 37 additions & 2 deletions scripts/calculate_formulas.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ FORMULAS=(
)

# Seperate in bundles on osx
if [[ "$TARGET" =~ ^(osx|ios|tvos|xros|catos|watchos)$ ]]; then
if [[ "$TARGET" =~ ^(osx|macos|ios|tvos|xros|catos|watchos)$ ]]; then
if [ "$BUNDLE" == "1" ]; then

FORMULAS=(
Expand Down Expand Up @@ -72,7 +72,7 @@ if [ "$BUNDLE" == "1" ]; then

)
elif [ "$BUNDLE" == "2" ]; then
if [[ "$TARGET" =~ ^(osx)$ ]]; then
if [[ "$TARGET" =~ ^(osx|macos)$ ]]; then
FORMULAS=(
"glm"
"json"
Expand All @@ -97,6 +97,41 @@ if [ "$BUNDLE" == "1" ]; then
"curl"
# "poco"
)
else
FORMULAS=(
"pixman"
"pkg-config"
"zlib"
"utf8"
"libpng"
"brotli"
"pugixml"
"freetype"
"libxml2"
"svgtiny"
"FreeImage"
"assimp"
"glew"
"json"
"zlib"
"glfw"
"opencv"
"portaudio"
"libusb"
"fmod"
"glm"
"json"
"opencv"
"videoInput"
"rtAudio"
"tess2"
"uriparser"
"cairo"
"fmt"
"openssl"
"curl"
# "poco"
)
fi

elif [ "$TARGET" == "vs" ]; then
Expand Down

0 comments on commit 05443c9

Please sign in to comment.