Build xz from git on macOS.

This commit is contained in:
John Preston 2020-07-16 12:52:05 +04:00
parent 55bd469b2d
commit f64f1ea62e
4 changed files with 23 additions and 13 deletions

View file

@ -54,7 +54,7 @@ Go to ***BuildPath*** and run
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout 53ed295
git checkout 7df6fdd
cd ../
git clone https://github.com/xiph/opus

View file

@ -33,7 +33,7 @@ Open **x86 Native Tools Command Prompt for VS 2019.bat**, go to ***BuildPath***
cd ThirdParty
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout 53ed295
git checkout 7df6fdd
cd ../
git clone https://chromium.googlesource.com/external/gyp
cd gyp
@ -65,7 +65,7 @@ Open **x86 Native Tools Command Prompt for VS 2019.bat**, go to ***BuildPath***
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout 0ba67e2
git checkout 7df6fdd
cd ..
git clone https://github.com/desktop-app/lzma.git

View file

@ -12,8 +12,6 @@ You will require **api_id** and **api_hash** to access the Telegram API servers.
### Download libraries
Download [**xz-5.0.5**](http://tukaani.org/xz/xz-5.0.5.tar.gz) and unpack to ***BuildPath*/Libraries/xz-5.0.5**
Download [**libiconv-1.15**](http://www.gnu.org/software/libiconv/#downloading) and unpack to ***BuildPath*/Libraries/libiconv-1.15**
### Clone source code and prepare libraries
@ -35,7 +33,7 @@ Go to ***BuildPath*** and run
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout b08b497
git checkout 7df6fdd
cd ../
git clone https://chromium.googlesource.com/external/gyp
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
@ -52,14 +50,17 @@ Go to ***BuildPath*** and run
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout b08b497
git checkout 7df6fdd
cd ../
cd xz-5.0.5
CFLAGS="-mmacosx-version-min=10.10" LDFLAGS="-mmacosx-version-min=10.10" ./configure
git clone https://git.tukaani.org/xz.git
cd xz
git checkout v5.2.5
mkdir build
cd build
CFLAGS='-Werror=unguarded-availability-new' CPPFLAGS='-Werror=unguarded-availability-new' cmake -D CMAKE_OSX_DEPLOYMENT_TARGET:STRING=10.10 ..
make $MAKE_THREADS_CNT
sudo make install
cd ..
cd ../..
git clone https://github.com/desktop-app/zlib.git
cd zlib

View file

@ -29,7 +29,7 @@ Go to ***BuildPath*** and run
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout 53ed295
git checkout 7df6fdd
cd ../
git clone https://chromium.googlesource.com/external/gyp
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
@ -47,9 +47,18 @@ Go to ***BuildPath*** and run
git clone https://github.com/desktop-app/patches.git
cd patches
git checkout b08b497
git checkout 7df6fdd
cd ..
git clone https://git.tukaani.org/xz.git
cd xz
git checkout v5.2.5
mkdir build
cd build
CFLAGS="$UNGUARDED" CPPFLAGS="$UNGUARDED" cmake -D CMAKE_OSX_DEPLOYMENT_TARGET:STRING=10.12 -D CMAKE_INSTALL_PREFIX:STRING=/usr/local/macos ..
make $MAKE_THREADS_CNT
cd ../..
xz_ver=5.2.4
wget https://tukaani.org/xz/xz-$xz_ver.tar.gz
tar -xvzf xz-$xz_ver.tar.gz