1
0
mirror of https://github.com/bertptrs/aur.git synced 2025-12-27 13:30:31 +01:00

Fix conflicts and relro issues.

This commit is contained in:
2019-09-02 16:42:45 +02:00
parent 7ad8d5a3d9
commit 3d100f43e4
2 changed files with 11 additions and 8 deletions

View File

@@ -1,12 +1,13 @@
pkgbase = bloaty pkgbase = bloaty
pkgdesc = a size profiler for binaries pkgdesc = a size profiler for binaries
pkgver = 1.0 pkgver = 1.0
pkgrel = 1 pkgrel = 2
url = https://github.com/google/bloaty url = https://github.com/google/bloaty
arch = x86_64 arch = x86_64
license = Apache license = Apache
makedepends = cmake makedepends = cmake
depends = gcc-libs depends = gcc-libs
options = !emptydirs
source = https://github.com/google/bloaty/releases/download/v1.0/bloaty-1.0.tar.bz2 source = https://github.com/google/bloaty/releases/download/v1.0/bloaty-1.0.tar.bz2
sha256sums = e1cf9830ba6c455218fdb50e7a8554ff256da749878acfaf77c032140d7ddde0 sha256sums = e1cf9830ba6c455218fdb50e7a8554ff256da749878acfaf77c032140d7ddde0

View File

@@ -1,19 +1,23 @@
# Maintainer: Bert Peters <bert@bertptrs.nl> # Maintainer: Bert Peters <bert@bertptrs.nl>
pkgname=bloaty pkgname=bloaty
pkgver=1.0 pkgver=1.0
pkgrel=1 pkgrel=2
pkgdesc="a size profiler for binaries" pkgdesc="a size profiler for binaries"
arch=(x86_64) arch=(x86_64)
url="https://github.com/google/bloaty" url="https://github.com/google/bloaty"
license=('Apache') license=('Apache')
depends=(gcc-libs zlib) depends=(gcc-libs)
makedepends=(cmake) makedepends=(cmake)
options=(!emptydirs)
source=("https://github.com/google/bloaty/releases/download/v$pkgver/bloaty-$pkgver.tar.bz2") source=("https://github.com/google/bloaty/releases/download/v$pkgver/bloaty-$pkgver.tar.bz2")
sha256sums=('e1cf9830ba6c455218fdb50e7a8554ff256da749878acfaf77c032140d7ddde0') sha256sums=('e1cf9830ba6c455218fdb50e7a8554ff256da749878acfaf77c032140d7ddde0')
build() { build() {
cd "$pkgname-$pkgver" cd "$pkgname-$pkgver"
cmake -DCMAKE_INSTALL_PREFIX=/usr . # Bloaty doesn't allow using an empty build type.
# Unfortunately, this breaks RELRO, so we need to fix that
cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_EXE_LINKER_FLAGS_RELEASE="$LDFLAGS" -Wno-dev .
make make
} }
@@ -26,9 +30,7 @@ build() {
package() { package() {
cd "$pkgname-$pkgver" cd "$pkgname-$pkgver"
make DESTDIR="$pkgdir/" install make DESTDIR="$pkgdir/" install
# Prevent a conflict with regular protobuf
rm "$pkgdir/usr/bin/protoc"*
# Don't cause conflicts with our static libraries # Prevent package conflicts
rm -rf "$pkgdir/usr/"{include,lib64} "$pkgdir/usr/lib/libre2.a" rm -r "$pkgdir/usr/"{include,bin/protoc*,lib64,lib/*.a,lib/pkgconfig/protobuf*,lib/cmake/protobuf}
} }