NAME="gtkmm2"
DESC="C++ interface to GTK+ 2"
VERSION="2.24.5"
FILES=("https://download.gnome.org/sources/gtkmm/${VERSION%.*}/gtkmm-$VERSION.tar.xz")
HASHES=("0680a53b7bf90b4e4bf444d1d89e6df41c777e0bacc96e9c09fc4dd2f5fe6b72")
DEPENDS=("gtk2" "atkmm" "cairomm")

PACKAGE() {
  tar xf gtkmm-$VERSION.tar.xz
  cd gtkmm-$VERSION

  CXXFLAGS+=' -std=c++11'
  ./configure --prefix=/usr
  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
  sed -i -e 's/^doc_subdirs/#doc_subdirs/' Makefile
  make && make DESTDIR="$ROOTDIR" install

  cd .. && rm -r gtkmm-$VERSION
}
