-
-
Save joekiller/4144838 to your computer and use it in GitHub Desktop.
#!/bin/bash | |
# GTK+ and Firefox for Amazon Linux | |
# Written by Joseph Lawson 2012-06-03 | |
# http://joekiller.com | |
# http://joekiller.com/2012/06/03/install-firefox-on-amazon-linux-x86_64-compiling-gtk/ | |
# chmod 755 ./gtk-firefox.sh | |
# sudo ./gtk-firefox.sh | |
TARGET=/usr/local | |
function init() | |
{ | |
export installroot=$TARGET/src | |
export workpath=$TARGET | |
yum --assumeyes install make libjpeg-devel libpng-devel \ | |
libtiff-devel gcc libffi-devel gettext-devel libmpc-devel \ | |
libstdc++46-devel xauth gcc-c++ libtool libX11-devel \ | |
libXext-devel libXinerama-devel libXi-devel libxml2-devel \ | |
libXrender-devel libXrandr-devel libXt dbus-glib \ | |
libXdamage libXcomposite | |
mkdir -p $workpath | |
mkdir -p $installroot | |
cd $installroot | |
PKG_CONFIG_PATH="$workpath/lib/pkgconfig" | |
PATH=$workpath/bin:$PATH | |
export PKG_CONFIG_PATH PATH | |
bash -c " | |
cat << EOF > /etc/ld.so.conf.d/firefox.conf | |
$workpath/lib | |
$workpath/firefox | |
EOF | |
ldconfig | |
" | |
} | |
function finish() | |
{ | |
cd $workpath | |
wget -r --no-parent --reject "index.html*" -nH --cut-dirs=7 http://download.cdn.mozilla.net/pub/mozilla.org/firefox/releases/latest/linux-x86_64/en-US/ | |
tar xvf firefox* | |
cd bin | |
ln -s ../firefox/firefox | |
ldconfig | |
} | |
function install() | |
{ | |
wget $1 | |
FILE=`basename $1` | |
if [ ${FILE: -3} == ".xz" ] | |
then tar xvfJ $FILE | |
else tar xvf $FILE | |
fi | |
SHORT=${FILE:0:4}* | |
cd $SHORT | |
./configure --prefix=$workpath | |
make | |
make install | |
ldconfig | |
cd .. | |
} | |
init | |
install ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.69.tar.xz | |
install http://download.savannah.gnu.org/releases/freetype/freetype-2.4.9.tar.gz | |
install http://www.freedesktop.org/software/fontconfig/release/fontconfig-2.9.0.tar.gz | |
install http://ftp.gnome.org/pub/gnome/sources/glib/2.32/glib-2.32.3.tar.xz | |
install http://cairographics.org/releases/pixman-0.26.0.tar.gz | |
install http://cairographics.org/releases/cairo-1.12.2.tar.xz | |
install http://ftp.gnome.org/pub/gnome/sources/pango/1.30/pango-1.30.0.tar.xz | |
install http://ftp.gnome.org/pub/gnome/sources/atk/2.4/atk-2.4.0.tar.xz | |
install http://ftp.gnome.org/pub/GNOME/sources/gdk-pixbuf/2.26/gdk-pixbuf-2.26.1.tar.xz | |
install http://ftp.gnome.org/pub/gnome/sources/gtk+/2.24/gtk+-2.24.10.tar.xz | |
finish | |
# adds the /usr/local/bin to your path by updating your .bashrc file. | |
cat << EOF >> ~/.bashrc | |
PATH=/usr/local/bin:\$PATH | |
export PATH | |
EOF |
Out-dated. Dont use the script, use Amazon Linux firefox-compat package instead:
Installing the EPLL yum repository:
https://lambda-linux.io/#getting-started
Installing Firefox on Amazon Linux:
https://lambda-linux.io/blog/2015/01/28/announcing-firefox-browser-support-for-amazon-linux/
any one can install libgtk-x11-2.0.so.0 in Amazon Linux yet?
Can confirm that the firefox-compat package which @basilmusa mentioned works like a charm with the last version of 45 ESR.
However, I'm in the situation that I need a newer version of firefox (52 would be great). Has anybody had success with anything beyond 45?
--2017-10-19 05:21:35-- http://download.cdn.mozilla.net/pub/mozilla.org/firefox/releases/latest/linux-x86_64/en-US/
Распознаётся download.cdn.mozilla.net (download.cdn.mozilla.net)… 52.84.23.224
Подключение к download.cdn.mozilla.net (download.cdn.mozilla.net)|52.84.23.224|:80... соединение установлено.
HTTP-запрос отправлен. Ожидание ответа… 302 Moved Temporarily
Адрес: http://download-origin.cdn.mozilla.net/pub/firefox/releases/latest/linux-x86_64/en-US/ [переход]
--2017-10-19 05:21:35-- http://download-origin.cdn.mozilla.net/pub/firefox/releases/latest/linux-x86_64/en-US/
Распознаётся download-origin.cdn.mozilla.net (download-origin.cdn.mozilla.net)… 54.230.147.70
Подключение к download-origin.cdn.mozilla.net (download-origin.cdn.mozilla.net)|54.230.147.70|:80... соединение установлено.
HTTP-запрос отправлен. Ожидание ответа… 404 Not Found
:(
failed with error:
--2020-06-23 10:09:40-- http://download.cdn.mozilla.net/pub/mozilla.org/firefox/releases/latest/linux-x86_64/en-US/
Resolving download.cdn.mozilla.net (download.cdn.mozilla.net)... 104.110.245.57, 2600:9000:21ca:a800:1d:f899:9cc6:5981, 2600:9000:21ca:ca00:1d:f899:9cc6:5981, ...
Connecting to download.cdn.mozilla.net (download.cdn.mozilla.net)|104.110.245.57|:80... connected.
HTTP request sent, awaiting response... 302 Moved Temporarily
Location: http://productdeliveryorigin-default.prod.mozaws.net/pub/firefox/releases/latest/linux-x86_64/en-US/ [following]
--2020-06-23 10:09:40-- http://productdeliveryorigin-default.prod.mozaws.net/pub/firefox/releases/latest/linux-x86_64/en-US/
Resolving productdeliveryorigin-default.prod.mozaws.net (productdeliveryorigin-default.prod.mozaws.net)... 34.195.60.137, 34.198.213.241, 34.239.61.227, ...
Connecting to productdeliveryorigin-default.prod.mozaws.net (productdeliveryorigin-default.prod.mozaws.net)|34.195.60.137|:80... connected.
HTTP request sent, awaiting response... 404 Not Found
2020-06-23 10:09:41 ERROR 404: Not Found.
tar: firefox*: Cannot open: No such file or directory
tar: Error is not recoverable: exiting now
I'm also encountering the same issue, and after i installed from the latest firefox version.
I am getting this error-
firefox: symbol lookup error: /lib64/libgtk-3.so.0: undefined symbol: g_log_structured_standard
XPCOMGlueLoad error for file /opt/firefox-38.0/libxul.so:
libgtk-x11-2.0.so.0: cannot open shared object file: No such file or directory
Couldn't load XPCOM.
RPM for libgtk-x11-2.0.so.0 library is gtk2-2.24.23-6.el6.i686, which is not present on Amazon Linux. Its present on CentOS base repo.
I am still not able to fix it... any help much appreciated.