2005-09-26 16:10:04 +02:00
|
|
|
source $stdenv/setup
|
2004-10-13 16:21:20 +02:00
|
|
|
|
2005-09-26 16:10:04 +02:00
|
|
|
unpackFile $src
|
|
|
|
ensureDir $out
|
2004-10-13 16:21:20 +02:00
|
|
|
mv eclipse $out/
|
2005-09-26 16:10:04 +02:00
|
|
|
|
2005-10-08 17:32:56 +02:00
|
|
|
# Set the dynamic linker and RPATH.
|
|
|
|
rpath=
|
|
|
|
for i in $libraries; do
|
|
|
|
rpath=$rpath${rpath:+:}$i/lib
|
|
|
|
done
|
|
|
|
find $out \( -type f -a -perm +0100 \) \
|
|
|
|
-print \
|
2006-10-27 14:43:32 +02:00
|
|
|
-exec patchelf --interpreter "$(cat $NIX_GCC/nix-support/dynamic-linker)" \
|
2005-10-08 17:32:56 +02:00
|
|
|
--set-rpath "$rpath" {} \;
|
|
|
|
|
|
|
|
# Make a wrapper script so that the proper JDK is found.
|
|
|
|
makeWrapper $out/eclipse/eclipse $out/bin/eclipse \
|
|
|
|
--prefix PATH ":" "$jdk/bin" \
|
|
|
|
--prefix LD_LIBRARY_PATH ":" "$rpath"
|
2005-11-08 00:02:17 +01:00
|
|
|
|
2006-02-25 01:44:02 +01:00
|
|
|
ensureDir plugin-working-dir
|
|
|
|
workingdir="$(pwd)/plugin-working-dir"
|
|
|
|
for plugin in $plugins; do
|
|
|
|
if test -e $plugin/install; then
|
|
|
|
cd $workingdir
|
|
|
|
$plugin/install "$out/eclipse"
|
|
|
|
rm -rf $workingdir/*
|
|
|
|
else
|
|
|
|
# assume that it is a file
|
|
|
|
cp $plugin $out/eclipse/plugins
|
2006-02-25 02:24:21 +01:00
|
|
|
fi
|
2006-02-25 01:44:02 +01:00
|
|
|
done
|