# Description: GNOME Chemistry Utilities # URL: http://download.savannah.gnu.org/releases/gchemutils # Maintainer: Petar Petrov, slackalaxy at gmail dot com # Depends on: bodr brotli chemical-mime-data graphite2 gtkglext libxml210 openbabel pango-querymodules # Optional: gnumeric-gtk2 abiword name=gchemutils version=0.12.13 release=5 source=(http://download.savannah.gnu.org/releases/gchemutils/0.12/gnome-chemistry-utils-0.12.13.tar.xz $name.directory $name.menu stream.patch) build() { export CC=gcc-5 export CPP=cpp-5 export CXX=g++-5 export PKG_CONFIG_PATH="/usr/lib/libxml210/pkgconfig:$PKG_CONFIG_PATH" export CPPFLAGS="-I/usr/include/libxml210/" export LDFLAGS="-L/usr/lib/libxml210 $LDFLAGS" export PATH="/usr/lib/libxml210/bin:$PATH" cd gnome-chemistry-utils-$version #https://techoverflow.net/2020/06/17/how-to-fix-c-c-error-call-of-overloaded-absuint32_t-is-ambiguous/ #https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=812164 patch -p1 -i $SRC/stream.patch CPPFLAGS="-I/usr/include/libxml210/" \ LDFLAGS="-L/usr/lib/libxml210 $LDFLAGS" \ CFLAGS="$CFLAGS -fpermissive -Wl,-rpath,/usr/lib/libxml210" \ CXXFLAGS="$CXXFLAGS -fpermissive -std=c++11 -Wl,-rpath,/usr/lib/libxml210" \ ./configure \ --prefix=/usr \ --sysconfdir=/usr/etc \ --disable-scrollkeeper \ --disable-update-databases \ --disable-nls CPPFLAGS="-I/usr/include/libxml210/" \ LDFLAGS="-L/usr/lib/libxml210 $LDFLAGS" \ CFLAGS="$CFLAGS -fpermissive -Wl,-rpath,/usr/lib/libxml210" \ CXXFLAGS="$CXXFLAGS -fpermissive -std=c++11 -Wl,-rpath,/usr/lib/libxml210" \ make make install DESTDIR=$PKG mkdir -p $PKG/usr/etc/xdg/menus/applications-merged cp $SRC/$name.menu $PKG/usr/etc/xdg/menus/applications-merged mkdir -p $PKG/usr/share/desktop-directories cp $SRC/$name.directory $PKG/usr/share/desktop-directories sed -i "s:Categories=:#Categories=:g" $PKG/usr/share/applications/*.desktop rm -rf $PKG/usr/share/{locale,gnome,omf} rm -f $PKG/{,usr/}lib/*.la }