Switch libjson-c back to upstream and fix some build issues with it.
This commit is contained in:
		
							
								
								
									
										2
									
								
								platform-darwin/External/libjson-c
									
									
									
									
										vendored
									
									
								
							
							
								
								
								
								
								
							
						
						
									
										2
									
								
								platform-darwin/External/libjson-c
									
									
									
									
										vendored
									
									
								
							 Submodule platform-darwin/External/libjson-c updated: f554039946...95dff31951
									
								
							@@ -5,7 +5,7 @@ cd "${BASH_SOURCE%/*}/../External/libjson-c"
 | 
			
		||||
[[ -d libjson-c-ios ]] && exit
 | 
			
		||||
 | 
			
		||||
# Prepare
 | 
			
		||||
autoreconf -Iautoconf-archive/m4 --verbose --install --symlink --force 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
autoreconf -Iautoconf-archive/m4 --verbose --install --symlink 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
rm -rf "${prefix=$PWD/libjson-c-ios}"
 | 
			
		||||
mkdir -p "$prefix/lib" \
 | 
			
		||||
    "${prefix_i386=$prefix/tmp/i386}" \
 | 
			
		||||
@@ -19,10 +19,10 @@ mkdir -p "$prefix/lib" \
 | 
			
		||||
    ## ARCH: i386
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk iphonesimulator)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk iphonesimulator)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-arch i386 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch i386 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -flto $LDFLAGS"
 | 
			
		||||
    export CFLAGS="-arch i386 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch i386 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} $LDFLAGS"
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s clean
 | 
			
		||||
    [[ -e Makefile ]] && make -s really-clean
 | 
			
		||||
    ./configure --host=i686-apple --disable-shared --prefix="$prefix_i386"
 | 
			
		||||
    make -j3 install
 | 
			
		||||
)
 | 
			
		||||
@@ -30,10 +30,10 @@ mkdir -p "$prefix/lib" \
 | 
			
		||||
    ## ARCH: x86_64
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk iphonesimulator)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk iphonesimulator)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-arch x86_64 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch x86_64 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -flto $LDFLAGS"
 | 
			
		||||
    export CFLAGS="-arch x86_64 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch x86_64 -isysroot $SDKROOT -mios-simulator-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} $LDFLAGS"
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s clean
 | 
			
		||||
    [[ -e Makefile ]] && make -s really-clean
 | 
			
		||||
    ./configure --host=x86_64-apple --disable-shared --prefix="$prefix_x86_64"
 | 
			
		||||
    make -j3 install
 | 
			
		||||
)
 | 
			
		||||
@@ -41,10 +41,10 @@ mkdir -p "$prefix/lib" \
 | 
			
		||||
    ## ARCH: armv7
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk iphoneos)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk iphoneos)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-mthumb -arch armv7 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-mthumb -arch armv7 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -flto $LDFLAGS"
 | 
			
		||||
    export CFLAGS="-mthumb -arch armv7 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-mthumb -arch armv7 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} $LDFLAGS"
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s clean
 | 
			
		||||
    [[ -e Makefile ]] && make -s really-clean
 | 
			
		||||
    ./configure --host=x86_64-apple --target=arm-apple --disable-shared --prefix="$prefix_armv7"
 | 
			
		||||
    make -j3 install
 | 
			
		||||
)
 | 
			
		||||
@@ -52,10 +52,10 @@ mkdir -p "$prefix/lib" \
 | 
			
		||||
    ## ARCH: armv7s
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk iphoneos)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk iphoneos)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-mthumb -arch armv7s -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-mthumb -arch armv7s -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -flto $LDFLAGS"
 | 
			
		||||
    export CFLAGS="-mthumb -arch armv7s -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-mthumb -arch armv7s -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} $LDFLAGS"
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s clean
 | 
			
		||||
    [[ -e Makefile ]] && make -s really-clean
 | 
			
		||||
    ./configure --host=x86_64-apple --target=arm-apple --disable-shared --prefix="$prefix_armv7s"
 | 
			
		||||
    make -j3 install
 | 
			
		||||
)
 | 
			
		||||
@@ -63,10 +63,10 @@ mkdir -p "$prefix/lib" \
 | 
			
		||||
    ## ARCH: arm64
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk iphoneos)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk iphoneos)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-mthumb -arch arm64 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-mthumb -arch arm64 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -flto $LDFLAGS"
 | 
			
		||||
    export CFLAGS="-mthumb -arch arm64 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} -O2 -g $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-mthumb -arch arm64 -isysroot $SDKROOT -mios-version-min=${IPHONEOS_DEPLOYMENT_TARGET:-8.0} $LDFLAGS"
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s clean
 | 
			
		||||
    [[ -e Makefile ]] && make -s really-clean
 | 
			
		||||
    ./configure --host=x86_64-apple --target=arm-apple --disable-shared --prefix="$prefix_arm64"
 | 
			
		||||
    make -j3 install
 | 
			
		||||
)
 | 
			
		||||
@@ -83,4 +83,4 @@ mv -f -- "$prefix_arm64/include" "$prefix/"
 | 
			
		||||
 | 
			
		||||
# Cleanup
 | 
			
		||||
rm -rf -- "$prefix/tmp"
 | 
			
		||||
make -s clean
 | 
			
		||||
make -s really-clean
 | 
			
		||||
 
 | 
			
		||||
@@ -5,23 +5,23 @@ cd "${BASH_SOURCE%/*}/../External/libjson-c"
 | 
			
		||||
[[ -d libjson-c-osx ]] && exit
 | 
			
		||||
 | 
			
		||||
# Prepare
 | 
			
		||||
autoreconf -Iautoconf-archive/m4 --verbose --install --symlink --force 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
autoreconf -Iautoconf-archive/m4 --verbose --install --symlink 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
rm -rf "${prefix=$PWD/libjson-c-osx}"
 | 
			
		||||
mkdir -p "$prefix"
 | 
			
		||||
 | 
			
		||||
# SDK: macOS
 | 
			
		||||
sdkPath="$(xcrun --show-sdk-path --sdk macosx)"
 | 
			
		||||
platformPath="$(xcrun --show-sdk-platform-path --sdk macosx)"
 | 
			
		||||
# Targets
 | 
			
		||||
(
 | 
			
		||||
    ## ARCH: x86_64
 | 
			
		||||
    export PATH="$platformPath/usr/bin:$platformPath/usr/sbin:$PATH"
 | 
			
		||||
    export CFLAGS="-arch x86_64 -isysroot $sdkPath -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-"10.8"} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch x86_64 -isysroot $sdkPath -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-"10.8"} -flto $LDFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s clean #distclean
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk macosx)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk macosx)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-arch x86_64 -isysroot $SDKROOT -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-10.8} -O2 -g $CFLAGS" # -flto
 | 
			
		||||
    export LDFLAGS="-arch x86_64 -isysroot $SDKROOT -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-10.8} $LDFLAGS" # -flto
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s really-clean
 | 
			
		||||
    ./configure --disable-shared --prefix="$prefix"
 | 
			
		||||
    make -j3 #check
 | 
			
		||||
    make -j3 check
 | 
			
		||||
    make -j3 install
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
# Cleanup
 | 
			
		||||
make -s clean #distclean
 | 
			
		||||
make -s really-clean
 | 
			
		||||
 
 | 
			
		||||
@@ -5,7 +5,7 @@ cd "${BASH_SOURCE%/*}/../External/libsodium"
 | 
			
		||||
[[ -d libsodium-ios ]] && exit
 | 
			
		||||
 | 
			
		||||
# Prepare
 | 
			
		||||
autoreconf --verbose --install --symlink --force 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
autoreconf --verbose --install --symlink 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
rm -rf "${prefix=$PWD/libsodium-ios}"
 | 
			
		||||
mkdir -p "$prefix/lib" \
 | 
			
		||||
    "${prefix_i386=$prefix/tmp/i386}" \
 | 
			
		||||
 
 | 
			
		||||
@@ -6,18 +6,18 @@ cd "${BASH_SOURCE%/*}/../External/libsodium"
 | 
			
		||||
 | 
			
		||||
# Inspired by libsodium/dist-build/osx.sh
 | 
			
		||||
# Prepare
 | 
			
		||||
autoreconf --verbose --install --symlink --force 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
autoreconf --verbose --install --symlink 2>&1 | sed 's/^\([^:]*\):[0-9]\{1,\}: /\1: /'
 | 
			
		||||
rm -rf "${prefix=$PWD/libsodium-osx}"
 | 
			
		||||
mkdir -p "$prefix"
 | 
			
		||||
 | 
			
		||||
# SDK: macOS
 | 
			
		||||
sdkPath="$(xcrun --show-sdk-path --sdk macosx)"
 | 
			
		||||
platformPath="$(xcrun --show-sdk-platform-path --sdk macosx)"
 | 
			
		||||
# Targets
 | 
			
		||||
(
 | 
			
		||||
    ## ARCH: x86_64
 | 
			
		||||
    export PATH="$platformPath/usr/bin:$platformPath/usr/sbin:$PATH"
 | 
			
		||||
    export CFLAGS="-arch x86_64 -isysroot $sdkPath -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-"10.8"} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch x86_64 -isysroot $sdkPath -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-"10.8"} -flto $LDFLAGS"
 | 
			
		||||
    export SDKROOT="$(xcrun --show-sdk-path --sdk macosx)"
 | 
			
		||||
    export PATH="$(xcrun --show-sdk-platform-path --sdk macosx)/usr/bin:$PATH"
 | 
			
		||||
    export CFLAGS="-arch x86_64 -isysroot $SDKROOT -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-10.8} -O2 -g -flto $CFLAGS"
 | 
			
		||||
    export LDFLAGS="-arch x86_64 -isysroot $SDKROOT -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET:-10.8} -flto $LDFLAGS"
 | 
			
		||||
    export CPPFLAGS="$CFLAGS $CPPFLAGS"
 | 
			
		||||
    [[ -e Makefile ]] && make -s distclean
 | 
			
		||||
    ./configure --disable-shared --prefix="$prefix"
 | 
			
		||||
    make -j3 check
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user