1SUMMARY="Programs to create, check and label file systems of the FAT family"
2DESCRIPTION="mkfs, checkfs, and fatlabel for FAT partitions."
3HOMEPAGE="https://github.com/dosfstools/dosfstools"
4COPYRIGHT="1991 Linus Torvalds
51992-1993 Remy Card
61993-1994 David Hudson
71999-2005 Roman Hodek
81999-2005 Werner Almesberger
91999-2005 Roman Hodek
102008-2014 Daniel Baumann
112015-2016 Andreas Bombe"
12LICENSE="GNU GPL v3"
13REVISION="1"
14SOURCE_URI="https://github.com/dosfstools/dosfstools/releases/download/v$portVersion/dosfstools-$portVersion.tar.xz"
15CHECKSUM_SHA256="e6b2aca70ccc3fe3687365009dd94a2e18e82b688ed4e260e04b7412471cc173"
16
17ARCHITECTURES="all !x86_gcc2 ?x86 !ppc !m68k"
18SECONDARY_ARCHITECTURES="x86"
19
20PROVIDES="
21	dosfstools$secondaryArchSuffix = $portVersion
22	cmd:fatlabel
23	cmd:fsck.fat
24	cmd:mkfs.fat
25	"
26REQUIRES="
27	haiku$secondaryArchSuffix
28	lib:libiconv$secondaryArchSuffix
29	"
30
31BUILD_REQUIRES="
32	haiku${secondaryArchSuffix}_devel
33	devel:libiconv$secondaryArchSuffix
34	"
35BUILD_PREREQUIRES="
36	cmd:awk
37	cmd:gcc$secondaryArchSuffix
38	cmd:make
39	"
40
41BUILD()
42{
43	# FIXME only works for little-endian architectures
44	export CFLAGS="-Dhtole32\(x\)=x -Dhtole16\(x\)=x -Dle32toh\(x\)=x -Dle16toh\(x\)=x"
45	export LDFLAGS=-liconv
46	runConfigure --omit-dirs binDir,sbinDir ./configure --bindir=$prefix/bin --sbindir=$prefix/bin
47	make $jobArgs
48}
49
50INSTALL()
51{
52	make install
53}
54