plash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Plash] Building Plash (~1.16) from the source in svn in Ubuntu Breezy


From: Toby Murray
Subject: [Plash] Building Plash (~1.16) from the source in svn in Ubuntu Breezy
Date: Fri, 17 Mar 2006 00:59:11 +1030

I've just pulled down plash from the svn and it appears that a 1.16
release is very nigh. As such, it's probably worth ignoring my previous
two posts for help as these issues might very well be fixed in the new
release.

In the meanwhile, the new website looks great. (I'm viewing a local copy
generated from the source.) Very cool indeed.

The following is a rambling description of the process I used to build
plash from the tree I checked out of the subversion repository today. I
did this on a Ubuntu breezy system, which by default doesn't include a
whole heap of packages pre-installed. As such, this description mentions
packages that I had to install to get the build working, as well as some
minor tweaks I had to put in. All in all, it was incredibly simple.
Kudos to Mark for putting in place such a workable build process for
what is a non-trivial software composition. (Building glibc is never
fun.)

I had to install the 'imagemagick' package on breezy to get 'convert',
which is needed to build the website. Having done that, the 'make.pl'
script in the web-site/ subdir of the source ran fine.
NOTE: I had to manually copy in the large screenshot files to out/ which
didn't seem to be done by 'make.pl'.

[begin terminal output]

address@hidden:web-site $ ls out
contents.html     internals.html      protocols.html
copyright.html    issues.html         screenshot-gnumeric-small.png
download.html     logo-abc-trans.png  screenshot-inkscape-small.png
environment.html  methods.html        screenshots.html
examples.html     news.html           screenshot-xemacs-small.png
exec-objs.html    pola-run.html       styles.css
faq.html          pola-shell.html
index.html        powerbox.html
address@hidden:web-site $ cp screenshot-*.png out

[end terminal output]

To build plash from the svn source, I began with a
'make-source-package.pl' to generate me a source package. This was done
so I could then follow the "Build Plash and glibc from source"
instructions from the download.html page of the website. 

I had to install the 'docbook2x' package in order to allow
'make-source-package.pl' to work.

Also, the website links to glibc-2.3.5.tar.bz2 but to
glibc-linuxthreads-2.3.5.tar.gz. Mixing the .bz2 and .gz seems to
confuse the 'make-source-package.pl' script. I pulled down the
'glibc-linuxthreads-2.3.5.tar.bz2' from the same place that the .gz is
from and used it instead.

glibc-2.3.5 doesn't build on breezy with gcc-4.0 (4.0.2 20050808) or
gcc-3.4 (3.4.5 20050809). The release notes indicate that glibc-2.3.5 is
known not to build with gcc-4.0. I got an internal compiler error with
gcc-3.4 (which I didn't investigate). 

I had to install gcc-3.3 (3.3.6), since this was the newest (packaged)
version of gcc that worked for me. Having installed the 'gcc-3.3'
package, I modified the symlinks in /usr/bin/ (cpp, gcc, gccbug, gcov)
to point to the 3.3 binaries. 

(this script made the job of switching gcc versions much easier)

[begin 'change_gcc_links' script]

#!/bin/bash

# invoke me with the gcc version you want to switch the symlinks to
# eg. 'change_gcc_links 3.3' or 'change_gcc_links 4.0'
VERSION=$1

for filename in cpp gcc gccbug gcov; do
  ln -sf $filename-$VERSION /usr/bin/$filename;
done

[end 'change_gcc_links' script]

Having built glibc using gcc-3.3, I then built plash. 

'configure' seemed to want to use gcc-4.0 by default (despite my
symlinks pointing to gcc-3.3), so I used the following to ensure it was
configured with gcc-3.3. (Since glibc was built with this compiler
version I thought it only prudent to build plash with the same.)

./configure GLIBC_DIR=glibc-objs CC=gcc-3.3

Plash then built fine using 'make.sh'.

At this point, I removed the 'plash' package that was already installed
(this was the plash-1.15 debian package), before doing the install.

At first glance, all appears to be working OK. I can run leafpad and
gthumb no worries using a script somewhat like this. (modelled of the
stuff in examples.html).

[begin pola_app script]
#!/bin/bash

PB_SO=/usr/lib/plash/lib/powerbox-for-gtk.so

PROG=$1
EXECUTABLE=$(which $PROG)

if [ ! -f $EXECUTABLE ]; then
  echo "$PROG not found" >&2
  exit 1
fi

if [ $# -gt 1 ]; then
  EXTRA_ARGS=$( echo $* | cut -d' ' -f2- )
else
  EXTRA_ARGS=""
fi

rm -rf tmp/$PROG
mkdir -p tmp/$PROG


pola-run \
  --prog $EXECUTABLE \
  -B -fl /etc \
  -tw /tmp tmp/$PROG \
  -tw $HOME tmp/$PROG \
  --env LD_PRELOAD=$PB_SO -fl $PB_SO \
  --x11 --powerbox --pet-name $PROG \
  $EXTRA_ARGS


[end pola_app script]

This works like (for example) ./pola_app leafpad
or ./pola_run gthumb -fl ~/pictures (which grants gthumb access to just
my pictures/ subdir of my home directory).

The gthumb example is quite cool because gthumb has a pane that allows
you to browse the filesystem. This means, when running under plash, you
can browse the namespace that it's running in and get a feel for what it
is like.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]