LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Upgrading Firefox from 1.0.4 to 1.5.0 (http://www.linuxquestions.org/questions/linux-software-2/upgrading-firefox-from-1-0-4-to-1-5-0-a-437305/)

xbill311x 04-20-2006 10:34 PM

Upgrading Firefox from 1.0.4 to 1.5.0
 
Hi all :)

I have Fedora Core 4 and I am using Firefox 1.0.4 that came with the distribution. I would like to upgrade it with 1.5.0 using "firefox-1.5.0.1.tar.gz". I would also like to keep all my current settings, bookmarks, etc. Is there an easy way to do this? I've finally gotten decent at installing new software, but upgrading exsisting software still gives me problems. Yes, still a newbie :(

Thanks :)

Bill

debasish_5849 04-20-2006 11:01 PM

Quote:

Originally Posted by xbill311x
Hi all :)

I have Fedora Core 4 and I am using Firefox 1.0.4 that came with the distribution. I would like to upgrade it with 1.5.0 using "firefox-1.5.0.1.tar.gz". I would also like to keep all my current settings, bookmarks, etc. Is there an easy way to do this? I've finally gotten decent at installing new software, but upgrading exsisting software still gives me problems. Yes, still a newbie :(

Thanks :)

Bill

Yah sure. Just untar the package in /usr/lib (that's where the firefox installed.) delete the old firefox direcotry or simply rename it to something that does not start with firefox, for example ...firefox and NOT firefox.... use the command "which firefox" that will show you the location of the firefox script. It will probably be /usr/bin/firefox. Type "gedit /usr/bin/firefox" or "vi /usr/bin/firefox" (as root of course)and change every instance of "firefox-1.0.4" to "firefox" not including the quotes. Save the file and you are done. All settings including bookmarks will be preserved because they are kept in ~/.firefox directory. However you will have to reinstall the themes (if you have installed them and you just cannot live without them)

debasish_5849 04-20-2006 11:31 PM

Hope the tip helps. Actually I'm currently using firefox 1.5.0 on fedora core 4. I just told you what I did.

xbill311x 04-20-2006 11:51 PM

Dude, awesome. I appriciate the quick repsonse. I shall tackle this chore tomorrow and let ya know what happens, lol :)

Appriciate the help tons :)

Thanks,

Bill

xbill311x 05-04-2006 12:35 PM

Hi debasish_5849,

I did as you said, I untarred the package in /usr/lib, then I changed the instances of firefox-1.0.4 in /usr/bin/firefox. I renamed the old firefox folder from /usr/lib/firefox-1.0.4 to /usr/lib/xxxfirefox-1.0.4. But now, when I try to run firefox from the command line or the icon, it just hangs for about 20 seconds and doesn't run. Can you look at my /usr/bin/firefox file to see if I'm missing anything?

------------

#!/bin/sh
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
#

##
## Usage:
##
## $ mozilla
##
## This script is meant to run a mozilla program from the mozilla
## rpm installation.
##
## The script will setup all the environment voodoo needed to make
## mozilla work.

cmdname=`basename $0`

##
## Variables
##
MOZ_LIB_DIR="/usr/lib"
if [ -x "/usr/lib64/firefox/firefox-bin" ]
then
MOZ_LIB_DIR="/usr/lib64"
fi
MOZ_DIST_BIN="$MOZ_LIB_DIR/firefox"
MOZ_PROGRAM="$MOZ_DIST_BIN/firefox"
MOZ_CLIENT_PROGRAM="$MOZ_DIST_BIN/mozilla-xremote-client"
MOZ_CLIENT_PROGRAM_PARAM="-a firefox"

##
## Set MOZILLA_FIVE_HOME
##
MOZILLA_FIVE_HOME="$MOZ_DIST_BIN"

export MOZILLA_FIVE_HOME

##
## Set LD_LIBRARY_PATH
##
if [ "$LD_LIBRARY_PATH" ]
then
LD_LIBRARY_PATH=$MOZ_DIST_BIN:$MOZ_DIST_BIN/plugins:$LD_LIBRARY_PATH
else
LD_LIBRARY_PATH=$MOZ_DIST_BIN:$MOZ_DIST_BIN/plugins
fi

export LD_LIBRARY_PATH

##
## Make sure that we set the plugin path for backwards compatibility
##
if [ "$MOZ_PLUGIN_PATH" ]
then
MOZ_PLUGIN_PATH=$MOZ_PLUGIN_PATH:$MOZ_LIB_DIR/mozilla/plugins:$MOZ_DIST_BIN/plugins
else
MOZ_PLUGIN_PATH=$MOZ_LIB_DIR/mozilla/plugins:$MOZ_DIST_BIN/plugins
fi
export MOZ_PLUGIN_PATH

##
## Set FONTCONFIG_PATH for Xft/fontconfig
##
FONTCONFIG_PATH="/etc/fonts:${MOZILLA_FIVE_HOME}/res/Xft"
export FONTCONFIG_PATH

##
## Set MOZ_ENABLE_PANGO is no longer used because Pango is enabled by default
## you may use MOZ_DISABLE_PANGO=1 to force disabling of pango
##
#MOZ_DISABLE_PANGO=1
#export MOZ_DISABLE_PANGO

function check_running() {
$MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM 'ping()' 2>/dev/null >/dev/null
RETURN_VAL=$?
if [ "$RETURN_VAL" -eq "2" ]; then
echo 0
return 0
else
echo 1
return 1
fi
}

function open_mail() {
if [ "${ALREADY_RUNNING}" -eq "1" ]; then
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM 'xfeDoCommand(openInbox)' \
2>/dev/null >/dev/null
else
exec $MOZ_PROGRAM $*
fi
}

function open_compose() {
if [ "${ALREADY_RUNNING}" -eq "1" ]; then
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM 'xfeDoCommand(composeMessage)' \
2>/dev/null >/dev/null
else
exec $MOZ_PROGRAM $*
fi
}

# OK, here's where all the real work gets done

# check to see if there's an already running instance or not
ALREADY_RUNNING=`check_running`

# If there is no command line argument at all then try to open a new
# window in an already running instance.
if [ "${ALREADY_RUNNING}" -eq "1" ] && [ -z "$1" ]; then
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM "xfeDoCommand(openBrowser)" 2>/dev/null>/dev/null
fi

# check system locale
MOZARGS=
MOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*|-\1|g"`
[ -f $MOZILLA_FIVE_HOME/chrome/$MOZLOCALE.jar ] && MOZARGS="-UILocale $MOZLOCALE"


# if there's no command line argument and there's not a running
# instance then just fire up a new copy of the browser
if [ -z "$1" ]; then
exec $MOZ_PROGRAM $MOZARGS 2>/dev/null >/dev/null
fi

unset RETURN_VAL

# If there's a command line argument but it doesn't begin with a -
# it's probably a url. Try to send it to a running instance.

USE_EXIST=0
opt="$1"
case "$opt" in
-mail)
open_mail ${1+"$@"}
;;
-compose)
open_compose ${1+"$@"}
;;
-*) ;;
*) USE_EXIST=1 ;;
esac

if [ "${USE_EXIST}" -eq "1" ] && [ "${ALREADY_RUNNING}" -eq "1" ]; then
# check to make sure that the command contains at least a :/ in it.
echo $opt | grep -e ':/' 2>/dev/null > /dev/null
RETURN_VAL=$?
if [ "$RETURN_VAL" -eq "1" ]; then
# if it doesn't begin with a '/' and it exists when the pwd is
# prepended to it then append the full path
echo $opt | grep -e '^/' 2>/dev/null > /dev/null
if [ "${RETURN_VAL}" -ne "0" ] && [ -e "`pwd`/$opt" ]; then
opt="`pwd`/$opt"
fi
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM "openurl($opt)" 2>/dev/null >/dev/null
fi
# just pass it off if it looks like a url
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM "openurl($opt)" 2>/dev/null >/dev/null
fi

exec $MOZ_PROGRAM $MOZARGS ${1+"$@"}

----------------

Not sure where to go at this point. If you could help, I would greatly appriciate it :)

Thanks again :)

Bill

sleekmason 05-04-2006 02:43 PM

This may be a dumb question, but why not just use the latest rpm instead? I believe it is 15.0.2. If there is a reason this won't work, please let me know for my future reference. thanx

xbill311x 05-04-2006 03:21 PM

Well, I would have used an rpm, but Firefox's website only has the gz file. Plus, I have dialup and I'd rather not wait again, lol.

What I was gonna do was just rename the new firefox folder in /usr/lib to firefox-1.0.4 and see if it would run, but I can't remember what lines in /usr/bin/firefox I changed. I should have made a backup, I just figured it would work :( I know I only changed two instances of "firefox-1.0.4" to "firefox", but I can't remember one of them. I just want this to work, but I'm patient :)

Any input?

Thanks :)

Bill

sleekmason 05-04-2006 07:10 PM

http://rpmfind.net/linux/rpm2html/se...&system=&arch= This is the site for the rpm . . . This is the main page of the same site http://rpmfind.net/linux/RPM/index.html I hope this help you. The rest of the site is great for findi
ng what you need.

xbill311x 05-04-2006 10:40 PM

Ok, I'm going to try the rpm. But I would still like to learn how to fix this problem using the .gz file, just to know how to do it, you know?

Bill

sleekmason 05-04-2006 10:57 PM

I'm new myself. If the common commands for upgrade and/or replace dont work, I would be stuck. Read everything and don't give up. My big problem right now is that I cant get 3d to work because my graphics card bites, but , , , , , , , a week, a month, . . . .

xbill311x 05-04-2006 11:20 PM

Man, do I know where you are coming from. I'm the same way, seems like the simplest things (like upgrading firefox) are so difficult cause the common commands don't apply. But I'm still learning. Waiting for the RPM to download now, so we'll see what happens :-D

Also, if anyone knows what the problem is with upgrading from the gz file, let me know :-D It's gonna bug me, lol.

ylliB

xbill311x 05-05-2006 01:44 AM

Hooray, failed dependencies from the rpm. As usual. Lol, sometimes I hate Linux...

Tried yumming, but no avail. Any suggestions anyone?

Thanks for any help anyone can give me, I appriciate it:)

Bill

jlo_sandog 05-06-2006 06:30 AM

the first thing you needed to do was to uninstall the old firefox.
rpm -e firefox
then, install the tar package (since you already have it).

debasish_5849 05-06-2006 02:13 PM

Quote:

Originally Posted by xbill311x
Hi debasish_5849,

I did as you said, I untarred the package in /usr/lib, then I changed the instances of firefox-1.0.4 in /usr/bin/firefox. I renamed the old firefox folder from /usr/lib/firefox-1.0.4 to /usr/lib/xxxfirefox-1.0.4. But now, when I try to run firefox from the command line or the icon, it just hangs for about 20 seconds and doesn't run. Can you look at my /usr/bin/firefox file to see if I'm missing anything?

------------

#!/bin/sh
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
#

##
## Usage:
##
## $ mozilla
##
## This script is meant to run a mozilla program from the mozilla
## rpm installation.
##
## The script will setup all the environment voodoo needed to make
## mozilla work.

cmdname=`basename $0`

##
## Variables
##
MOZ_LIB_DIR="/usr/lib"
if [ -x "/usr/lib64/firefox/firefox-bin" ]
then
MOZ_LIB_DIR="/usr/lib64"
fi
MOZ_DIST_BIN="$MOZ_LIB_DIR/firefox"
MOZ_PROGRAM="$MOZ_DIST_BIN/firefox"
MOZ_CLIENT_PROGRAM="$MOZ_DIST_BIN/mozilla-xremote-client"
MOZ_CLIENT_PROGRAM_PARAM="-a firefox"

##
## Set MOZILLA_FIVE_HOME
##
MOZILLA_FIVE_HOME="$MOZ_DIST_BIN"

export MOZILLA_FIVE_HOME

##
## Set LD_LIBRARY_PATH
##
if [ "$LD_LIBRARY_PATH" ]
then
LD_LIBRARY_PATH=$MOZ_DIST_BIN:$MOZ_DIST_BIN/plugins:$LD_LIBRARY_PATH
else
LD_LIBRARY_PATH=$MOZ_DIST_BIN:$MOZ_DIST_BIN/plugins
fi

export LD_LIBRARY_PATH

##
## Make sure that we set the plugin path for backwards compatibility
##
if [ "$MOZ_PLUGIN_PATH" ]
then
MOZ_PLUGIN_PATH=$MOZ_PLUGIN_PATH:$MOZ_LIB_DIR/mozilla/plugins:$MOZ_DIST_BIN/plugins
else
MOZ_PLUGIN_PATH=$MOZ_LIB_DIR/mozilla/plugins:$MOZ_DIST_BIN/plugins
fi
export MOZ_PLUGIN_PATH

##
## Set FONTCONFIG_PATH for Xft/fontconfig
##
FONTCONFIG_PATH="/etc/fonts:${MOZILLA_FIVE_HOME}/res/Xft"
export FONTCONFIG_PATH

##
## Set MOZ_ENABLE_PANGO is no longer used because Pango is enabled by default
## you may use MOZ_DISABLE_PANGO=1 to force disabling of pango
##
#MOZ_DISABLE_PANGO=1
#export MOZ_DISABLE_PANGO

function check_running() {
$MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM 'ping()' 2>/dev/null >/dev/null
RETURN_VAL=$?
if [ "$RETURN_VAL" -eq "2" ]; then
echo 0
return 0
else
echo 1
return 1
fi
}

function open_mail() {
if [ "${ALREADY_RUNNING}" -eq "1" ]; then
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM 'xfeDoCommand(openInbox)' \
2>/dev/null >/dev/null
else
exec $MOZ_PROGRAM $*
fi
}

function open_compose() {
if [ "${ALREADY_RUNNING}" -eq "1" ]; then
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM 'xfeDoCommand(composeMessage)' \
2>/dev/null >/dev/null
else
exec $MOZ_PROGRAM $*
fi
}

# OK, here's where all the real work gets done

# check to see if there's an already running instance or not
ALREADY_RUNNING=`check_running`

# If there is no command line argument at all then try to open a new
# window in an already running instance.
if [ "${ALREADY_RUNNING}" -eq "1" ] && [ -z "$1" ]; then
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM "xfeDoCommand(openBrowser)" 2>/dev/null>/dev/null
fi

# check system locale
MOZARGS=
MOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*|-\1|g"`
[ -f $MOZILLA_FIVE_HOME/chrome/$MOZLOCALE.jar ] && MOZARGS="-UILocale $MOZLOCALE"


# if there's no command line argument and there's not a running
# instance then just fire up a new copy of the browser
if [ -z "$1" ]; then
exec $MOZ_PROGRAM $MOZARGS 2>/dev/null >/dev/null
fi

unset RETURN_VAL

# If there's a command line argument but it doesn't begin with a -
# it's probably a url. Try to send it to a running instance.

USE_EXIST=0
opt="$1"
case "$opt" in
-mail)
open_mail ${1+"$@"}
;;
-compose)
open_compose ${1+"$@"}
;;
-*) ;;
*) USE_EXIST=1 ;;
esac

if [ "${USE_EXIST}" -eq "1" ] && [ "${ALREADY_RUNNING}" -eq "1" ]; then
# check to make sure that the command contains at least a :/ in it.
echo $opt | grep -e ':/' 2>/dev/null > /dev/null
RETURN_VAL=$?
if [ "$RETURN_VAL" -eq "1" ]; then
# if it doesn't begin with a '/' and it exists when the pwd is
# prepended to it then append the full path
echo $opt | grep -e '^/' 2>/dev/null > /dev/null
if [ "${RETURN_VAL}" -ne "0" ] && [ -e "`pwd`/$opt" ]; then
opt="`pwd`/$opt"
fi
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM "openurl($opt)" 2>/dev/null >/dev/null
fi
# just pass it off if it looks like a url
exec $MOZ_CLIENT_PROGRAM $MOZ_CLIENT_PROGRAM_PARAM "openurl($opt)" 2>/dev/null >/dev/null
fi

exec $MOZ_PROGRAM $MOZARGS ${1+"$@"}

----------------

Not sure where to go at this point. If you could help, I would greatly appriciate it :)

Thanks again :)

Bill


issue the command "whereis firefox" in your command prompt and give me the output

xbill311x 05-06-2006 04:41 PM

Hi debasish_5849 :)

Well, I just yummed update firefox (which took FOREVER!) but it only updated to 1.0.8. Here is my whereis now:

[root@localhost bill]# whereis firefox
firefox: /usr/bin/firefox /usr/lib/firefox /usr/share/man/man1/firefox.1.gz
[root@localhost bill]#

Since I yummed, it is running once again, so that is good, I guess it updated the /usr/bin/firefox script and fixed the mistake I made in it.

I would still like to have 1.5.0, and still have the gz file for it, but I'm getting ready to give it up.

Are all upgrades for Linux this difficult? Lol...

Bill


All times are GMT -5. The time now is 05:38 AM.