CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
chromium: updated to 45.0.2454.85
[ports/opt-arm.git] / chromium / Pkgfile
CommitLineData
0826c9bd
JB
1# Description: Open source version of Google Chrome web browser.
2# URL: http://chromium.org/
3# Arch Maintainer: CRUX-ARM System Team, devel at crux-arm dot nu
4# Maintainer: Jose V Beneyto, sepen at crux dot nu
5# Packager: Tadeusz Sosnierz, tadzikes gmail com
e78af32e 6# Depends on: ninja dbus-glib gtk libevent nss xorg-libxscrnsaver xorg-libxtst libgcrypt xorg-libxdamage yasm xorg-libxt gperf speech-dispatcher libdrm libexif pciutils
0826c9bd
JB
7
8name=chromium
ee744317 9version=45.0.2454.85
0826c9bd 10release=1
6a3c14de
VM
11source=(http://commondatastorage.googleapis.com/$name-browser-official/$name-$version.tar.xz \
12 $name.sh $name.desktop)
0826c9bd
JB
13
14build() {
15 cd $name-$version
16
0826c9bd
JB
17 export CFLAGS="$CFLAGS $(pkg-config --cflags nspr)"
18 export LDFLAGS="$LDFLAGS $(pkg-config --libs nspr)"
19
20 # determine some flags depending on SOC
21 USE_ARMV7=0; USE_ARM_THUMB=0; USE_ARM_NEON=0
22 case $(uname -m) in
23 armv7*) USE_ARMV7=1; USE_ARM_THUMB=1;;
24 esac
25 for flag in $CFLAGS; do
26 case $flag in
27 -mfpu=neon*) USE_ARM_NEON=1;;
28 esac
29 done
30
6a3c14de 31 build/gyp_chromium build/all.gyp --depth=. \
6570d746 32 -Dtarget_arch=arm \
0826c9bd
JB
33 -Darm_float_abi=hard \
34 -Darmv7=$USE_ARMV7 \
35 -Darm_thumb=$USE_ARM_THUMB \
36 -Darm_neon=$USE_ARM_NEON \
37 -Dv8_target_arch=arm \
38 -Dv8_use_arm_eabi_hardfloat=1 \
39 -Dsysroot= \
6a3c14de 40 -Dclang=0 \
6570d746
JB
41 -Dpython_ver="2.7" \
42 -Dno_strict_aliasing=1 \
43 -Dwerror= \
6a3c14de 44 -Dlinux_sandbox_path=/usr/lib/$name/chrome-sandbox \
6570d746 45 -Dlinux_strip_binary=1 \
0826c9bd
JB
46 -Dlinux_use_gold_binary=0 \
47 -Dlinux_use_gold_flags=0 \
0826c9bd
JB
48 -Drelease_extra_cflags="$CFLAGS" \
49 -Dproprietary_codecs=1 \
50 -Dffmpeg_branding=Chrome \
6a3c14de 51 -Dlibspeechd_h_prefix=speech-dispatcher/ \
6570d746
JB
52 -Duse_system_libjpeg=1 \
53 -Duse_system_libxslt=1 \
54 -Duse_system_libxml=1 \
55 -Duse_system_bzip2=1 \
56 -Duse_system_zlib=0 \
57 -Duse_system_libpng=0 \
58 -Duse_system_ffmpeg=0 \
6a3c14de 59 -Duse_system_yasm=1 \
6570d746
JB
60 -Duse_system_libevent=1 \
61 -Duse_system_sqlite=0 \
6a3c14de 62 -Duse_system_ssl=0 \
6570d746
JB
63 -Dremove_webcore_debug_symbols=1 \
64 -Duse_gconf=0 \
65 -Duse_cups=0 \
66 -Duse_gnome_keyring=0 \
0826c9bd
JB
67 -Duse_kerberos=0 \
68 -Duse_pulseaudio=0 \
6570d746 69 -Dlinux_link_gnome_keyring=0 \
0826c9bd
JB
70 -Dlinux_link_libpci=1 \
71 -Dlinux_link_libspeechd=1 \
6570d746 72 -Denable_webrtc=1 \
6a3c14de
VM
73 -Ddisable_nacl=1 \
74 -Dicu_use_data_file_flag=0
0826c9bd 75
6a3c14de 76 ninja -C out/Release chrome chrome_sandbox
0826c9bd 77
6a3c14de
VM
78 install -m 0755 -D out/Release/chrome $PKG/usr/lib/$name/$name
79 install -m 4755 -o root -g root -D out/Release/chrome_sandbox $PKG/usr/lib/$name/chrome-sandbox
80 install -m 0644 -D out/Release/*.pak $PKG/usr/lib/$name
6a3c14de
VM
81 install -d $PKG/usr/lib/$name/locales
82 install -m 0644 out/Release/locales/en-US.pak $PKG/usr/lib/$name/locales
83 cp -a out/Release/resources $PKG/usr/lib/$name
84 install -m 0644 -D out/Release/chrome.1 $PKG/usr/man/man1/$name.1
0826c9bd 85
6a3c14de
VM
86 # fix v8 natives
87 cp -a out/Release/{natives,snapshot}_blob.bin $PKG/usr/lib/$name
0826c9bd
JB
88
89 for size in 22 24 48 128 256; do
6a3c14de
VM
90 install -m 0644 -D chrome/app/theme/$name/product_logo_${size}.png \
91 $PKG/usr/share/icons/hicolor/${size}x${size}/apps/$name.png
0826c9bd
JB
92 done
93
6a3c14de
VM
94 install -d $PKG/usr/share/pixmaps
95 ln -sf /usr/share/icons/hicolor/48x48/apps/$name.png $PKG/usr/share/pixmaps/$name.png
96 install -m 0644 -D $SRC/$name.desktop $PKG/usr/share/applications/$name.desktop
97 install -m 0755 -D $SRC/$name.sh $PKG/usr/bin/$name
0826c9bd 98}