app=ace
version=1.4
build=1sml
homepage="https://www.delorie.com/store/ace/"
download="https://www.delorie.com/store/ace/ace-1.4.tar.gz"
desc="A set of Xorg solitaire games"
requires="guile"

build() {
  mkandenterbuilddir
  rm -rf $app-$version

  tar xf $srcdir/$app-$version.tar.?z*
  cd $app-$version
  fixbuilddirpermissions

  applypatch $srcdir/ace14_fixes.patch

  LDFLAGS="-lpng -lz -lm" \
  ./configure \
    --prefix="" \
    --disable-static \
    $builddist

  make
  make install DESTDIR=$pkg

  cp COPYING $pkgdocs/

  mkdir -p $pkg/share/applications
  cp $srcdir/*.desktop $pkg/share/applications/

  mkfinalpkg
}

sha512sums="
3be9ac04faa48e1464f1877553ff2717829ae5aa0398dd99d044fbf4a55f5a62e4443a3fc71f9a5f7ceb7a1bd02c126098b2f2b9f70c1315e86e465d3e556bec  ace-1.4.tar.lz
16fa23cd3d30c8044ba35244f75d7d234eb7f4baaf0904ccd3412d0cd084315fb0691f0ea4da1084482bd47875a21cc423b29f83f501c93249430f89c01c6a2d  ace14_fixes.patch
"
