LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 10-27-2008, 06:43 PM   #1
empcrono
Member
 
Registered: Jul 2008
Distribution: Slackware
Posts: 110

Rep: Reputation: 15
help w/ creating a SlackBuild for icecat


OK I am building a SlackBuild for icecat. This is proving much more challenging then the last SlackBuild script I wrote (with the aids of templates). I am attempting to write this one with the aid of templates as well. Fact is I am not all that skilled and have only written one SlackBuild. Yet I firmly get the idea. The below code is using the template provided by SlackBuild.org.

Any help would be liked.

I currently keep getting this error.

Code:
checking for cairo >= 1.6.0 freetype2 fontconfig... 
Requested 'cairo >= 1.6.0' but version of cairo is 1.4.14
configure: error: Library requirements 
(cairo >= 1.6.0 freetype2 fontconfig) 
not met; consider adjusting the PKG_CONFIG_PATH 
environment variable if your libraries are in 
a nonstandard prefix so pkg-config can find them.
I currently do not know how to proceed from here. Also I have looked at Firefox builds and they usualy have a patch. Well I realize icecat is Firefox without the non free branding etc. That is why I want to use icecat.

Thank you in advance.

Code:

PRGNAM=icecat
VERSION=${VERSION:-3.0.2-g1}
ARCH=${ARCH:-pentium4}
BUILD=${BUILD:-1}
TAG=${TAG:-_WGsIII}

CWD=$(pwd)
TMP=${TMP:-/tmp/WGsIII}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/home/empcrono/tmp/build}

if [ "$ARCH" = "i486" ]; then
  SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "pentium4" ]; then
  SLKCFLAGS="-O2 -march=pentium4"
elif [ "$ARCH" = "i686" ]; then
  SLKCFLAGS="-O2 -march=i686 -mtune=i686"
elif [ "$ARCH" = "x86_64" ]; then
  SLKCFLAGS="-O2 -fPIC"
fi

set -e # Exit on most errors
# If you prefer to do selective error checking with 
#   command || exit 1
# then that's also acceptable.

rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
find . \
 \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
 -exec chmod 755 {} \; -o \
 \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
 -exec chmod 644 {} \;

# Your application will probably need different configure flags;
# these are provided as an example only. 
# Be sure to build only shared libraries unless there's some need for
# static.
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
 --prefix=/usr \
 --sysconfdir=/etc \
 --localstatedir=/var \
 --libdir=/usr/lib \
 --with-system-nspr \
 --with-system-nss \
 --with-system-jpeg \
 --with-system-zlib \
 --with-pthreads \
 --enable-optimize="$SLKCFLAGS" \
 --enable-xinerama \
 --enable-default-toolkit=cairo-gtk2 \
 --enable-strip \
 --enable-pango \
 --enable-system-cairo \
 --enable-svg \
 --enable-canvas \
 --enable-startup-notification \
 --enable-safe-browsing \
 --with-branding=browser/branding/unofficial \

# Compile the application and install it into the $PKG directory
make
make install DESTDIR=$PKG

# Strip binaries and libraries - this can be done with 'make install-strip'
# in many source trees, and that's usually acceptable if so, but if not, 
# use this:
( cd $PKG
  find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
  find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
)


# Remove perllocal.pod and other special files that don't need to be installed,
# as they will overwrite what's already on the system.  If this is not needed, 
# remove it from the script.
( cd $PKG
  # Remove 'special' files
  find . -name perllocal.pod \
    -o -name ".packlist" \
    -o -name "*.bs" \
    | xargs rm -f
)

# Copy program documentation into the package
# The included documentation varies from one application to another, so be sure
# to adjust your script as needed
# Also, include the SlackBuild script in the documentation directory
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a <documentation> $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild

# Copy the slack-desc (and a custom doinst.sh if necessary) into ./install
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc

# Make the package; be sure to leave it in $OUTPUT
# If package symlinks need to be created during install *before*
# your custom contents of doinst.sh runs, then add the -p switch to
# the makepkg command below -- see makepkg(8) for details
cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
UPDATE:

I updated the code to reflect the current state of things

Last edited by empcrono; 10-28-2008 at 03:34 PM. Reason: see UPDATE
 
Old 10-27-2008, 07:05 PM   #2
Woodsman
Senior Member
 
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482

Rep: Reputation: 534Reputation: 534Reputation: 534Reputation: 534Reputation: 534Reputation: 534
The icecat package is dependent upon cairo 1.6.0 or greater. Slackware 12.1 provides version 1.4.14. Slackware Current provides version 1.6.4.
 
Old 10-28-2008, 03:26 PM   #3
empcrono
Member
 
Registered: Jul 2008
Distribution: Slackware
Posts: 110

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Woodsman View Post
The icecat package is dependent upon cairo 1.6.0 or greater. Slackware 12.1 provides version 1.4.14. Slackware Current provides version 1.6.4.
Duh! Thank you for taking the time for stating what should have seemed obvious but did not to me.



Any how can any one tell me what the differnce between
the configure options of
Code:
--enable-libxul
--enable-static
The compiler says that only one of those options are permitted.
 
Old 10-28-2008, 05:02 PM   #4
bgeddy
Senior Member
 
Registered: Sep 2006
Location: Liverpool - England
Distribution: slackware64 13.37 and -current, Dragonfly BSD
Posts: 1,810

Rep: Reputation: 227Reputation: 227Reputation: 227
Try running configure --help to see what the options are. I think they are probably to do with building the libxul.so shared library or compiling the functions statically but I'm not sure.

Just an idea but maybe it would be worth looking at an existing Firefox Slackbuild as a learning exercise. I believe Firefox can use .mozconfig configuration files to hold all the configuration options - it may be worth building one of these. You could create a here document from your Slackbuild script if you wanted to create this on the fly.
 
Old 10-28-2008, 05:10 PM   #5
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,772

Rep: Reputation: 478Reputation: 478Reputation: 478Reputation: 478Reputation: 478
I hate to dump ice on you(no pun intended), but I think that building icecat is way ambitious for your first few (hundred) SlackBuilds. First of all, to make it truly icecat, you'll need to apply the patches from debian and some of them are going to cause you heartaches. You could use the official Slackware SlackBuild for SeaMonkey as a starting point since it is the closest thing to that you can get. But still, some of the options used in the SlackBuild will be directly opposed to the essence of what icecat means to be. The Slackware build is an authorized build so it can use the OFFICIAL options which include the Mozilla Foundation branding materials. Most of the icecat modifications deal with removing the official branding icons and name. You'll have to study closely the different configure options used for icecat as opposed to seamonkey. I dare say that simply working with the regular Slackbuild for seamonkey and making *small* changes to that will be enough to convince you that you don't *really* want to fool around with compiling any mozilla stuff -it will drive you crazy very quickly. If you don't know what xul and static compiling are, you will quickly lose your way compiling any moz stuff. It doesn't help that it takes so long to test a compile abd find out if what you are trying is working. Ohhh, I get all bothered just thinking about compiling moz stuff. My God man, save yourself while you still can!
More to the point. libxul is a library which can't be compiled statically, so you have to decide whether you want static or libxul. BTW, getting a statically compiled moz product is the most maddening thing of all, and if you succeed, you'll find that the application needs about 500MB of RAM to run. It will start up a little quicker than a dynamically compiled version though.
My condolences to your family if you decide to proceed...
 
Old 10-28-2008, 11:31 PM   #6
empcrono
Member
 
Registered: Jul 2008
Distribution: Slackware
Posts: 110

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by gnashley
First of all, to make it truly icecat, you'll need to apply the patches from debian
Thank you for your very informative reply. However I am unsure as to why I would need to download a patch from Debian. I downloaded the icecat package from gnuzilla.

Also I had thought of using sea monkey SlackBuild as a reference. However since you brought it up I decided to look at it again. So I am trying to use it as a template instead. Still, since you say I could be at this for some time.... I 'll just give it a few more goes and call it good.


==========================================================================
Other thoughts:

I really do think its important to support the forked version. I am behind the free software movement 99% of the way. I'm no saint mind you. I do flash but aside from a few things here and there I do my best to use 100% free software. The more freedom we keep in our part of the park the better.

I do not care if its a nice dictator, (even though that is better then one who is not), a dictator is a dictator.
 
Old 10-29-2008, 04:33 AM   #7
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,772

Rep: Reputation: 478Reputation: 478Reputation: 478Reputation: 478Reputation: 478
I hadn't noticed that gnuzilla had an already patched version -that should make it easier rather than fooling with the debian patches. As I said, most of the patches(or differences from the original) deal with changing the 'brand' of the product. Still, debian no doubt includes other patches which add features or fix bugs -that's what all the trouble was about to begin with...
 
Old 10-29-2008, 04:43 PM   #8
empcrono
Member
 
Registered: Jul 2008
Distribution: Slackware
Posts: 110

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by gnashley View Post
I hadn't noticed that gnuzilla had an already patched version -that should make it easier rather than fooling with the debian patches. As I said, most of the patches(or differences from the original) deal with changing the 'brand' of the product. Still, debian no doubt includes other patches which add features or fix bugs -that's what all the trouble was about to begin with...
I see thanks a lot.


Despite you trying to warn me or even turn me away from creating a icecat package I succeeded. You were, in fact, very helpful. I used the SeaMonkey as a reference. Only one thing did not come out the way I had hoped, and so I am doing some research on the internet on how to proceed from here. The icons never made it. I do not get any of the icecat icons. I do not get any icons at all for that matter.

Thanks every one.


Edit:

Despite all what I wrote above I am beginning to see that this may still be more work.
Reason: Because I am wrestling with gnash & flash.


Other thoughts: It is blazing fast. But other things like very few icons in the actual browser it self. i.e. stop refresh etc.

Update:

I got it all working just one thing left to do. I do not have a icon. I have a full browser theme. I.e. I got stop icon refresh icon inside the browser ware before I did not. Only thing missing is that in the network section of the xfce menu has no icecat icon or entry (and I did put in the SlackBuild).Also I got flash working. I will try to switch over to Gnash but I was going back and forth between them just to see if I could get it working period. Alas With a little work I did get it working. I am currently using 100% free icecat for a web browser.

Last edited by empcrono; 10-30-2008 at 01:05 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
IceCat and Gnash Darth Cupcake Linux - Software 0 10-22-2008 11:47 PM
SlackBuild scripts stu_mueller Slackware 15 04-04-2008 02:03 AM
(Just curious) IceWeasel = IceCat? RodWC Debian 5 10-30-2007 04:29 PM
Slackbuild and Patches stormtracknole Slackware 4 03-30-2006 09:12 PM
SlackBuild CrEsPo Slackware 2 03-19-2006 02:58 PM


All times are GMT -5. The time now is 07:43 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration