2014-03-13 19:17:29 +00:00
|
|
|
# Template file for 'gnuplot'
|
2014-11-25 19:02:25 +00:00
|
|
|
pkgname=gnuplot
|
|
|
|
version=4.6.6
|
|
|
|
revision=2
|
|
|
|
configure_args="--with-readline=builtin"
|
|
|
|
hostmakedepends="pkg-config"
|
|
|
|
makedepends="zlib-devel libX11-devel gd-devel lua-devel"
|
|
|
|
depends="gnuplot-common>=${version}_${revision}"
|
|
|
|
replaces="gnuplot<4.6.6_1"
|
|
|
|
short_desc="Command-line driven graphing utility"
|
2014-11-24 12:20:46 +00:00
|
|
|
maintainer="Eivind Uggedal <eivind@uggedal.com>"
|
2014-03-13 19:01:44 +00:00
|
|
|
homepage="http://www.gnuplot.info/"
|
2014-11-24 12:20:46 +00:00
|
|
|
update_ignore="*rc*"
|
2014-11-25 19:02:25 +00:00
|
|
|
license="gnuplot"
|
|
|
|
distfiles="${SOURCEFORGE_SITE}/gnuplot/gnuplot/${version}/gnuplot-${version}.tar.gz"
|
2014-11-24 12:20:46 +00:00
|
|
|
checksum=1f19596fd09045f22225afbfec11fa91b9ad1d95b9f48406362f517d4f130274
|
|
|
|
|
2014-11-25 19:02:25 +00:00
|
|
|
subpackages="gnuplot-common"
|
|
|
|
if [ -z "$CROSS_BUILD" ]; then
|
|
|
|
makedepends+=" cairo-devel pango-devel wxGTK-devel qt-devel"
|
|
|
|
subpackages+=" gnuplot-wx gnuplot-qt"
|
|
|
|
fi
|
|
|
|
|
2014-11-24 12:20:46 +00:00
|
|
|
pre_configure() {
|
2014-11-25 19:02:25 +00:00
|
|
|
# fix fonts location
|
|
|
|
sed -i \
|
|
|
|
-e 's|/usr/X11R6/lib/X11/fonts/Type1|/usr/share/fonts/Type1|' \
|
|
|
|
-e 's|/usr/X11R6/lib/X11/fonts/truetype|/usr/share/fonts/TTF|' \
|
|
|
|
-e 's|$(X11ROOT)/X11R6/lib/X11/fonts/Type1|$(X11ROOT)/usr/share/fonts/Type1|' \
|
|
|
|
src/variable.c
|
|
|
|
|
2014-11-24 12:20:46 +00:00
|
|
|
if [ "$CROSS_BUILD" ]; then
|
|
|
|
sed -i 's|^\(SUBDIRS =.*\)demo |\1|' Makefile.in
|
|
|
|
sed -i 's|^\(CFLAGS =\).*|\1 -O0|' docs/Makefile.in
|
|
|
|
fi
|
2014-11-25 19:02:25 +00:00
|
|
|
|
|
|
|
mkdir -p x11
|
|
|
|
mv * x11 || true
|
|
|
|
if [ -z "$CROSS_BUILD" ]; then
|
|
|
|
cp -a x11 wx
|
|
|
|
cp -a x11 qt
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
do_configure() {
|
|
|
|
if [ -z "$CROSS_BUILD" ]; then
|
|
|
|
cd ${wrksrc}/x11
|
|
|
|
./configure ${configure_args} --without-qt --disable-wxwidgets --without-cairo --disable-wxt
|
|
|
|
cd ${wrksrc}/wx
|
|
|
|
./configure ${configure_args}
|
|
|
|
cd ${wrksrc}/qt
|
|
|
|
./configure ${configure_args} --enable-qt --disable-wxwidgets
|
|
|
|
else
|
|
|
|
cd ${wrksrc}/x11
|
|
|
|
./configure ${configure_args}
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
do_build() {
|
|
|
|
make -C x11 ${makejobs}
|
|
|
|
if [ -z "$CROSS_BUILD" ]; then
|
|
|
|
make -C wx ${makejobs}
|
|
|
|
make -C qt ${makejobs}
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
do_install() {
|
|
|
|
# install x11 and rename binary
|
|
|
|
make -C x11 DESTDIR=${DESTDIR} install
|
|
|
|
mv ${DESTDIR}/usr/bin/gnuplot{,-x11}
|
|
|
|
if [ -z "$CROSS_BUILD" ]; then
|
|
|
|
# install qt and rename binary
|
|
|
|
make -C qt DESTDIR=${DESTDIR} install
|
|
|
|
mv ${DESTDIR}/usr/bin/gnuplot{,-qt}
|
|
|
|
# install wx
|
|
|
|
make -C wx DESTDIR=${DESTDIR} install
|
|
|
|
fi
|
|
|
|
vlicense x11/Copyright LICENSE
|
|
|
|
}
|
|
|
|
|
|
|
|
gnuplot-common_package() {
|
|
|
|
replaces="gnuplot<4.6.6_1"
|
|
|
|
short_desc+=" - common files"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/PostScript
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/app-defaults
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/js
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/lua
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/*.gp
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/gnuplot.gih
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/gnuplotrc
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/gnuplot.pdf
|
|
|
|
vmove usr/share/licenses/gnuplot
|
|
|
|
vmove usr/share/man/man1/gnuplot.1
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
gnuplot-wx_package() {
|
|
|
|
replaces="gnuplot<4.6.6_1"
|
|
|
|
depends="gnuplot-common>=${version}_${revision}"
|
|
|
|
short_desc+=" - wxWidgets frontend"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/bin/gnuplot
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
gnuplot-qt_package() {
|
|
|
|
depends="gnuplot-common>=${version}_${revision}"
|
|
|
|
short_desc+=" - Qt frontend"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/bin/gnuplot-qt
|
|
|
|
vmove usr/libexec/gnuplot/${version%.*}/gnuplot_qt
|
|
|
|
vmove usr/share/gnuplot/${version%.*}/qt
|
|
|
|
}
|
2014-11-24 12:20:46 +00:00
|
|
|
}
|