blob: b0fa4a416be3bfe28dce69c619c2b570022799ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
# Maintainer: Lukas Jirkovsky <l.jirkovsky@gmail.com>
pkgname=codeviz
pkgver=1.0.12
_pkgver=8e597959959c4e812742e9d68c1ea4c4db63a39d
_gccver=4.6.4
pkgrel=1
pkgdesc="A call graph generation utility for C/C++"
arch=('i686' 'x86_64')
url="https://github.com/petersenna/codeviz"
license=('GPL2')
depends=('perl' 'graphviz')
# unset the C(XX)FLAGS because they would break the compilation if they contained
# options not supported in $_gccver
options=('!buildflags')
source=("https://github.com/petersenna/codeviz/archive/$_pkgver.zip"
ftp://ftp.gnu.org/pub/gnu/gcc/gcc-$_gccver/gcc-${_gccver}.tar.gz)
noextract=(gcc-${_gccver}.tar.gz)
install=codeviz.install
md5sums=('5538e066a1c18fd7d49bfe8a9df92e68'
'a8f15fc233589924ccd8cc8140b0ca3c')
build() {
cd "$srcdir/$pkgname-$_pkgver"
# disable problematic flags, solution by ftschindler from gcc46
CPPFLAGS=${CPPFLAGS//-D_FORTIFY_SOURCE=?/}
export CPPFLAGS
CFLAGS=${CFLAGS//-fstack-protector-strong/-fstack-protector}
export CFLAGS
CXXFLAGS=${CXXFLAGS//-fstack-protector-strong/-fstack-protector}
export CXXFLAGS
# update for gcc 4.6.4 instead of 4.6.2
find . -type f -exec sed -i 's|4\.6\.2|4\.6\.4|g' '{}' ';'
mv compilers/install_gcc-4.6.2.sh compilers/install_gcc-${_gccver}.sh
mv compilers/gcc-patches/gcc-4.6.2-cdepn.diff compilers/gcc-patches/gcc-${_gccver}-cdepn.diff
# link the downloaded sources so the configure script doesn't download them again
ln -sf "$SRCDEST/gcc-${_gccver}.tar.gz" compilers/gcc-${_gccver}.tar.gz
./configure --gcc=4.6.4 --prefix=/usr --gccgraph=/opt/gccgraph
make
}
package() {
cd "$srcdir/$pkgname-$_pkgver"
make DESTDIR="$pkgdir" install
}
# vim:set ts=2 sw=2 et:
|