diff options
author | j.r | 2021-04-29 11:21:14 +0200 |
---|---|---|
committer | j.r | 2021-04-29 12:14:26 +0200 |
commit | c54234fb4041d48e18456cbc5768b2ae04288689 (patch) | |
tree | 211d8a43285854567a189bd4fa851d39ffe29d07 /PKGBUILD | |
parent | 263177fbb13fb89a7fb090eb0a7bfa0efaf5167c (diff) | |
download | aur-c54234fb4041d48e18456cbc5768b2ae04288689.tar.gz |
libtd: less RAM usage on build time
Many users reported the package needs enourmous ammounts of RAM to
build. This commit switches build to clang and splits source files
beforehand as recommended by their build instruction generator [1].
[1] https://tdlib.github.io/td/build.html
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 15 |
1 files changed, 9 insertions, 6 deletions
@@ -4,7 +4,7 @@ _pkgname=libtd pkgname=${_pkgname} pkgver=1.7.0 -pkgrel=1 +pkgrel=2 pkgdesc='TDLib (Telegram Database library) is a cross-platform library for building Telegram clients' arch=('x86_64') url='https://core.telegram.org/tdlib' @@ -15,12 +15,12 @@ depends=( ) makedepends=( 'git' - 'gcc>=4.9.2' + 'clang>=3.4' 'make' 'cmake>=3.0.2' 'gperf' 'php' - 'ninja' + 'gcc-libs' ) provides=('libtd') conflicts=('telegram-tdlib') @@ -32,9 +32,12 @@ build() { rm -rf build mkdir build cd build - CXXFLAGS="" - cmake -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH="$pkgdir/usr" .. - cmake --build . + CC=/usr/bin/clang + CXX=/usr/bin/clang++ + cmake -DCMAKE_BUILD_TYPE=None -DCMAKE_INSTALL_PREFIX:PATH="$pkgdir/usr" .. + cmake --build . --target prepare_cross_compiling + cd .. + php SplitSource.php } package() { |