name=pcmanfm
version=1.3.2
release=1
desc="The LXDE file manager"
url="https://lxde.org/"
license="GPL-2.0-or-later"
depend="glibc gtk3 libfm"
makedepend=""
source="https://downloads.sourceforge.net/pcmanfm/pcmanfm-1.3.2.tar.xz"
sha256="SKIP"

build() {
	export CFLAGS="$CFLAGS -fcommon -Wno-incompatible-pointer-types -Wno-int-conversion"
	cd "pcmanfm-1.3.2"
	_opts="--prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=/usr/lib"
	_help=$(./configure --help 2>/dev/null)
	case "$_help" in *--disable-static*)  _opts="$_opts --disable-static" ;; esac
	case "$_help" in *--disable-nls*)     _opts="$_opts --disable-nls" ;; esac
	case "$_help" in *--with-gtk*) _opts="$_opts --with-gtk=3" ;; esac
	./configure $_opts
	make -j"$JOBS"
}

package() {
	cd "pcmanfm-1.3.2"
	make DESTDIR="$pkgdir" install
}
