code:
[mirrors]
http://s3.amazonaws.com/json-c_releases/releases/json-c-0.12-nodoc.tar.gz

[vars]
filesize=390179
sha512=44c6ed9df44e5cf92d008491f07e22de51024b4ac09c50b17389d87da1ee9dc1b4506a8c11f8e427521a843e4864128fafb493d659a34cfc60a95aaaa82e6ea5
uchkurl=http://s3.amazonaws.com/json-c_releases
tardir=json-c-0.12

[deps]

[build]
cp -f "$K"/config.sub .
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"
sed -i 's@Werror @Wall @' Makefile.in
CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/json-c


code:
[vars]
filesize=446563
sha512=478f5489534d109fa2ac0c5f6ae783cfdb1a8ac6df9d67bb09e11708e9a578bd1a5306916c33b98447c29b551aec593f6defa8a5a2ea70acb35c8f72da8dbbc3
tardir=jupp

[mirrors]
http://www.mirbsd.org/MirOS/dist/jupp/joe-3.1jupp26.tgz

[build]
chmod +x configure
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure --prefix="$butch_prefix" $xconfflags \
  --sysconfdir=/etc \
  --disable-dependency-tracking \
  --disable-termidx &&
make V=1 -j $MAKE_THREADS &&
make DESTDIR="$butch_install_dir" install

repo_name: aarf/bkauler

path: pkg/jupp

license: unknown


code:
[mirrors]
http://joewing.net/projects/jwm/snapshots/jwm-1524.tar.xz

[vars]
filesize=270756
sha512=f7ad34923cf22193dd4087482b5f8a010ae1f4858586b8d9d14e6a084b11fa818926a599562d563eaff0e46a939ab7ca4237c6da7821d3d37497c4f850ac25ac
desc="JWM is a window manager for the X11 Window System"

[deps]
libx11
fribidi
libpng
libjpeg
librsvg
cairo
libxft
libxpm

[build]
CFLAGS="$optcflags"
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib -liconv" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-confirm

#build failing in 'po' folder. do a quick hack for now...
sed -i '/\$(MAKE) -C po /d' Makefile

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

dest="$butch_install_dir""$butch_prefix"
mkdir -p $dest/share/doc/nls/jwm
cp -a -f po/jwm.pot $dest/share/doc/nls/jwm/

path: pkg/jwm


code:
[mirrors]
http://ftp.kernel.org/pub/linux/utils/kbd/kbd-1.15.3.tar.xz
http://ftp.cc.uoc.gr/mirrors/ftp.kernel.org/pub/linux/utils/kbd/kbd-1.15.3.tar.xz

[vars]
filesize=761072
sha512=19dba103f4941b975f547e229d1b03c8d355cd59871e4dfe6db32235a7983b2d8f52e6c7a674d07bdef8bf3a557eefaf731eb47128c3db02f43e91192faea03c

[deps]
bison
gcc4

[build]
# fix build errors on non-glibc (first patch) and other things as described by LFS
# see http://www.linuxfromscratch.org/lfs/view/stable/chapter07/console.html
# for further reference on how this package is supposed to be used, we only use it
# to strip the keymaps off.
for p in kbd kbd-1.15.3-upstream_fixes-1 kbd-1.15.3-backspace-1 kbd-1.15.3-busyboxkmap ; do
	patch -p1 < "$K"/$p.patch
done

#fix bug in spanish transl.
sed -i '/guardado\ el/s/\(^.*en\ %\)\(.*\)/\14\$\2/' po/es.po

# prevent autoconf to be run again because of an invalid timestamp
sed -i 's/\(RESIZECONS_PROGS=\)yes/\1no/' configure &&
sed -i 's/resizecons.8 //' man/man8/Makefile.in &&
touch -d '2011-05-07 08:30' configure.ac

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"

CFLAGS="-D_GNU_SOURCE -DSIGIOT=SIGABRT $optcflags" \
LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" \
  --disable-nls $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

#http://hg.slitaz.org/wok/file/3f989c266063/kbd-base/stuff/keymaps-path.list
slitaz_set=`cat << EOF
azerty/be-latin1.map.gz
azerty/fr-latin1.map.gz
dvorak/dvorak.map.gz
dvorak/dvorak-r.map.gz
dvorak/dvorak-l.map.gz
qwerty/br-abnt2.map.gz
qwerty/cf.map.gz
qwerty/cz-lat2.map.gz
qwerty/dk-latin1.map.gz
qwerty/es.map.gz
qwerty/fi-latin1.map.gz
qwerty/it.map.gz
qwerty/is-latin1.map.gz
qwerty/jp106.map.gz
qwerty/nl2.map.gz
qwerty/no-latin1.map.gz
qwerty/pl2.map.gz
qwerty/pt-latin1.map.gz
qwerty/ru.map.gz
qwerty/se-lat6.map.gz
qwerty/tr_q-latin5.map.gz
qwerty/trq.map.gz
qwerty/uk.map.gz
qwerty/us-acentos.map.gz
qwerty/us.map.gz
qwertz/croat.map.gz
qwertz/de_CH-latin1.map.gz
qwertz/de-latin1.map.gz
qwertz/de-latin1-nodeadkeys.map.gz
qwertz/fr_CH-latin1.map.gz
qwertz/hu.map.gz
qwertz/sg-latin1.map.gz
qwertz/slovene.map.gz
EOF
`
# slitaz installs only these files to save space.
# so do we
# see http://hg.slitaz.org/wok/file/3f989c266063/kbd-base/receipt

fs=$butch_install_dir$butch_prefix
# generate busybox loadkmap compatible keymaps from the gnu ones.
# taken from http://hg.slitaz.org/wok/file/3f989c266063/kbd-busybox/receipt
mkdir -p "$fs"/share/kmap
for i in $slitaz_set ; do
	k=$(basename $i)
	k=${k%.map.gz} # strips off .map.gz from $k
	"$fs"/bin/loadkeys -b "$fs"/share/keymaps/i386/$i > "$fs"/share/kmap/$k.kmap || echo "ERROR: loadkeys...$i"
done

replace_stuff=true

if $replace_stuff ; then

# we can rm the original keymaps now to save space,
# and everything else, except of "$fs"/share/kmap
for i in bin share/consolefonts share/consoletrans share/keymaps share/man share/unimaps ; do
	rm -rf "$fs"/"$i"
done

# slitaz comes with a user friendly keyboard switched script: http://trixarian.net/paste/9abcb
# (/sbin/tazkeymap). this can serve as a template. for now, just use loadkmap < /share/kmap/layout.kmap

mkdir -p "$fs"/bin
cat << EOF > "$fs"/bin/loadkeys
#!/bin/sh
echo 'use loadkmap < /share/kmap/layout.kmap to change keyboard layout'
echo "available keyboard layouts are:"
find /share/kmap -name '*.kmap' | sort
exit 1
EOF
chmod +x "$fs"/bin/loadkeys

fi

path: pkg/kbd


code:
[vars]
filesize=256988
sha512=3cef1df57138264dac9802cc4074bc58f82609c6ef859e238108d9ad1ac3a720b991d91f61ca47ea48c56019b465e7e6b37bcbe0b519d1999126255a7d879d54

[mirrors]
http://xorg.freedesktop.org/releases/individual/proto/kbproto-1.0.6.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/kbproto


code:
[deps.host]
gcc4

[deps]
kernel-tarball
kernel-patches

[vars]
LINUX_VER=$(cat "$K"/kernel.version)
tarball=linux-"$LINUX_VER".tar.xz

[build]
# get into menuconfig using
# make HOSTCFLAGS="-D_GNU_SOURCE" HOSTLDFLAGS=-lncurses menuconfig

# install regulatory domain database into kernel tree
# we build it fixed into the kernel so we don't need the bloated "crda" tool
# to change regulatory domains with iw set reg.
cp -f "$K"/linux-regdb.txt net/wireless/db.txt

dopatch() {
	echo "applying patch $1"
	if ! patch -p1 < "$1" ; then
		echo "patch failed!"
		exit 1
	fi
}

for p in $(cat "$K"/kernel.patches) ; do
	kpatch="$C"/kernel-patch-"$p".xz
	[ -e "$kpatch" ] || {
		echo "error: kernel patch $kpatch not found"
		exit 1
	}
	xzcat "$C"/kernel-patch-"$p".xz | patch -p 1
done

# work around mismatch between devicename and channel name in 9p virtfs code
# p9_virtio_create gets something like "/dev/chan" and the channel name is "chan"
dopatch "$K"/linux-virtio9p.patch

# patches to support busybox trap and sed with strict musl BRE engine
dopatch "$K"/linux-3.18-posix_sed.patch
# linux 4.3 broke monitor mode on ralink wireless chips
# https://bugs.kali.org/view.php?id=3028
dopatch "$K"/linux-4.3-ralink-monitor.patch

export ARCH=$A
linux_config="$K"/linux.config

if [ -z "$HOSTCC" ] ; then
	HOSTCC="$CC"
fi

if [ "$A" = arm ] ; then
	[ -z "$ARM_ARCH" ] && (echo "error: need to set ARM_ARCH to 4-7" ; exit 1)
	linux_config="$linux_config $K/linux.config.armv${ARM_ARCH}l"
fi

cat "$linux_config" > my.config

make V=1 ARCH=$A allnoconfig HOSTCFLAGS="-D_GNU_SOURCE" \
  KCONFIG_ALLCONFIG=my.config DISABLE_PAX_PLUGINS=y

make V=1 -j$MAKE_THREADS CC="$CC" ARCH=$A HOSTCC="$HOSTCC" \
  HOSTCFLAGS=-D_GNU_SOURCE DISABLE_PAX_PLUGINS=y

mkdir -p $butch_root_dir/boot $butch_root_dir/lib/modules/$LINUX_VER \
         $butch_root_dir/lib/firmware

egrep -q '\=m$' my.config && got_modules=true || got_modules=false

$got_modules && \
make INSTALL_MOD_PATH=$butch_root_dir DISABLE_PAX_PLUGINS=y modules_install

cp -f System.map $butch_root_dir/boot/

if [ "$A" = arm ] ; then
	kpath="arch/arm/boot/zImage"
else
	kpath="arch/x86/boot/bzImage"
fi
cp -f $kpath $butch_root_dir/boot/vmlinuz

# "build" headers into dest/
# we need to build them after the kernel because grsec assumes this order
# otherwise some generated headers won't be found
make V=1 ARCH=$A HOSTCFLAGS=-D_GNU_SOURCE INSTALL_HDR_PATH=dest \
  DISABLE_PAX_PLUGINS=y headers_install

# remove junk from kernel headers
find dest/include \( -name .install -o -name ..install.cmd \) -delete

$got_modules && depmod "$LINUX_VER"

exit 0

path: pkg/kernel


code:
[mirrors]
http://distro.ibiblio.org/quirky/quirky6/sources/alphabetical/a/aufs4-4.4-20160413.tar.gz

[vars]
filesize=1382928
sha512=25330737e51d408a85e23d2fea8fe79114f375b2142e7617653c56789915770cb00cf6b9a13895e56825d4ac8f94e337902a42548bb10f594c468c305ff610d4
desc="Kernel module for Aufs layered filesystem"

[deps]

[build]
#extract the patches. Later, 'kernel' recipe will apply them.
#note, got the source from here: git clone git://github.com/sfjro/aufs4-standalone.git aufs4
# cd aufs4
# git branch -a
# git checkout origin/aufs4.4

#dest="$butch_install_dir""$butch_prefix"
#no, hard-code it...
dest="$R"/opt/kernel-aufs
mkdir -p "$R"/opt/kernel-aufs

cp -f aufs4-base.patch "$dest"/
cp -f aufs4-kbuild.patch "$dest"/
cp -f aufs4-standalone.patch "$dest"/
cp -f aufs4-mmap.patch "$dest"/

cp -a -f fs "$dest"/
cp -a -f Documentation "$dest"/
cp -f include/uapi/linux/aufs_type.h "$dest"/

cat> "$dest"/aufs-allow-sfs.patch <<'EOFMKR'
diff -rupN aufs2.1-32-git100511-orig//fs/aufs/loop.c aufs2.1-32-git100511/fs/aufs/loop.c
--- aufs2.1-32-git100511-orig/fs/aufs/loop.c	2011-05-11 11:27:21.922000014 +0200
+++ aufs2.1-32-git100511/fs/aufs/loop.c	2011-05-11 11:28:00.310000011 +0200
@@ -28,6 +28,9 @@
  */
 int au_test_loopback_overlap(struct super_block *sb, struct dentry *h_adding)
 {
+	/* allow Squashfs file systems to be used as Aufs branches */
+	return 0;
+
 	struct super_block *h_sb;
 	struct loop_device *l;

EOFMKR

exit 0

path: pkg/kernel-aufs


code:
[mirrors]
http://ftp.barfooze.de/pub/sabotage/tarballs/kernel-headers-3.12.6-5.tar.xz
http://foss.aueb.gr/mirrors/linux/sabotage/tarballs/kernel-headers-3.12.6-5.tar.xz
http://codu.org/~rofl/tarballs/kernel-headers-3.12.6-5.tar.xz
http://dl.2f30.org/mirrors/sabotage/tarballs/kernel-headers-3.12.6-5.tar.xz

[vars]
filesize=757200
sha512=f6a8eff1c93556aced47c0ac962b8356c3394ad9b25dcfe425a87d26f35391608a9d06f7f5010c1146fa4959c2093ca01ab251b2215f6c21298827ab0fc01032

[build]
make ARCH="$A" prefix="$butch_prefix" DESTDIR="$butch_install_dir" install \

dest="$butch_install_dir""$butch_prefix"
#fix ext2 header...
cp -f "$K"/ext2_fs.h "$dest"/include/linux/

path: pkg/kernel-headers


code:
[deps]
kernel-patch-442-3
kernel-patch-443-4
kernel-patch-444-5
kernel-patch-445-6
kernel-patch-446-7
kernel-patch-447-8
kernel-patch-448-9
kernel-patch-449-10

path: pkg/kernel-patches


code:
[mirrors]
http://www.kismetwireless.net/code/kismet-2013-03-R1b.tar.xz

[vars]
filesize=699968
sha512=37b81dd89ba3c02af12e55ebddf86901dbe58123bf9b6928339803d80d01c2351b5376e829292859ecc89539cebd4e1db6aa0d104142ccb289696405a8b2c783
desc='a passive WLAN sniffer/detector'

[deps]
curses
libnl-tiny
libpcap

[build]
# Makefile tries to force user name, which breaks cross compilation
sed -i -e 's@\$(INSTALL).*-m @install -D -m @g' -e 's/555/755/g' Makefile.in
patch -p1 < "$K"/kismet-kernelheader.patch
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
libnl20_CFLAGS=-I$butch_root_dir$butch_prefix/include/libnl-tiny \
libnl20_LIBS=-lnl-tiny \
CPPFLAGS="-I$butch_root_dir$butch_prefix/include/libnl-tiny" \
LIBS="-lnl-tiny -lcurses -lterminfo" \
CFLAGS="-D_GNU_SOURCE $optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/kismet


code:
[mirrors]
ftp://ftp.kernel.org/pub/linux/utils/kernel/kmod/kmod-15.tar.xz
http://cdn.kernel.org/pub/linux/utils/kernel/kmod/kmod-15.tar.xz

[vars]
filesize=1453996
sha512=67a03cabe9d81c14eb0bef20f3c8ff4614418cb2b2c3e1428d8a57399372ecdce6e403399a578d2f62a1ae4b61c83713edd1ad1e31533ea35503c5b11b92c223

[deps]
zlib
xz

[build]

for i in kmod kmod-test-stdout kmod-test-glibc-assumption kmod-static-assert ; do
	patch -p1 < "$K"/"$i".patch
done

[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --with-zlib --disable-manpages --with-xz --enable-tools

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

#need symlinks...
dest="$butch_install_dir""$butch_prefix"
ln -s kmod "$dest"/bin/lsmod
ln -s kmod "$dest"/bin/depmod
ln -s kmod "$dest"/bin/insmod
ln -s kmod "$dest"/bin/modinfo
ln -s kmod "$dest"/bin/modprobe
ln -s kmod "$dest"/bin/rmmod

path: pkg/kmod


code:
[mirrors]
http://sourceforge.net/projects/lame/files/lame/3.99/lame-3.99.5.tar.gz

[vars]
filesize=1445348
sha512=ce62d7eb9fc8c53c343374ded30f11153a296910f0be7e649197bca7412c6660aad1aa6143d56b750f866229eb492cf7bb4f682535c383fb4aa57d7077d8b4d8

[deps]
curses

[build]
[ -n "$CROSS_COMPILE" ] && \
xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
LIBS="-lcurses -lterminfo" \
CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/lame


code:
[deps]
apache
mysql
php

path: pkg/lamp


code:
[mirrors]
http://downloads.sourceforge.net/lcms/lcms2-2.7.tar.gz

[vars]
filesize=6497867
sha512=9e69ec30efa9d50474808c6ae3d9afb0c5798eaabca0052f82d54efecdc2b58ab40434ee6dee9cd80028597d79a07f6b3b1a73f5293fc444343274eac3e32fd4

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install


code:
[mirrors]
http://download.savannah.gnu.org/releases/leafpad/leafpad-0.8.18.tar.gz

[vars]
filesize=289079
sha512=315f5541dfe8d519ea832ad8b13b034a5ac173f8b9c0de7e3f774780b4ef42f2fab29e3ef847a1c15daf544f85308b14f53a79d568ca4e89f5840ce8bd675bc4
desc='minimalistic GTK+ text editor. useful to copy text terminal <-> GUI apps'

[deps]
gtk+2

[build]
patch -p1 < "$K"/leafpad-savebug.patch
patch -p1 < "$K"/leafpad-taskbar-icon.patch
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="-D_GNU_SOURCE $optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-nls

for i in po ; do
	printf 'all:\n\ttrue\ninstall:\n\ttrue\clean:\n\ttrue\n' > "$i"/Makefile
done

chmod +x install-sh
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/leafpad


code:
[mirrors]
http://www.greenwoodsoftware.com/less/less-471.tar.gz

[vars]
filesize=316133
sha512=4c6d43a031cea38eb79e88a1aa40f737869d2ab879bd6feb89adb8d2bdb6561471f9013aa083cdbbf142fcdbade367b1b4552ff26c0b710890c9be53815f75e9

[deps]
curses

[build]
#configure is missing some includes... which lead to implicit declarations
patch -p1 < "$K"/less.patch
patch -p1 < "$K"/less-implicit.patch

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags"\
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/less


code:
[mirrors]
https://github.com/pavouk/lgi/archive/0.8.0.tar.gz

[vars]
filesize=282052
sha512=9998b544210d006ea5be162d052031599837bfb2c22433193d4f6761cd7d1e19e69252dd9fea0c3fee94efadaa354d80e2be13db578b3a2b71a9b56a7f07cbe9
tardir=lgi-0.8.0
tarball=lgi-0.8.0.tar.gz

[deps]
gobject-introspection
lua

[build]
# depends on lua-5.2.
# lua-5.3 doesn't work yet with lgi-0.8.0!

make V=1 -j$MAKE_THREADS

make \
    LUA_LIBDIR="$butch_root_dir""$butch_prefix"/lib/lua/5.2 \
    LUA_SHAREDIR="$butch_root_dir""$butch_prefix"/share/lua/5.2 \
    DESTDIR="$butch_install_dir" install

path: pkg/lgi


code:
[mirrors]
http://dl.sourceforge.jp/lha/22231/lha-1.14i-ac20050924p1.tar.gz

[vars]
filesize=285518
sha512=efe43d407d273f8f724f7b205223bd122c76adac4b67ad5e9811e88cae03f1f3c3af4297aa6f24951a02558975bbafacf697e97ab0da578b4e0115b89237566f
desc='extractor for the lha compression used mainly by amiga software'

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/lha


code:
[mirrors]
http://downloads.xiph.org/releases/ao/libao-1.2.0.tar.gz

[vars]
filesize=464596
sha512=9456953826c188d67129ad78366bb86d6243499f2cd340d20d61366f7e40a33f3f8ab601c7f18ce9e24aa22f898093b482b2415b7e428c1486ef7e5ac27b3ee4

[deps]
alsa-lib

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libao


code:
[deps]
xz
zlib

[vars]
filesize=1502828
sha512=f4248f7b8d93e25e3223afe0c3b19467ab9071f9fd0a341dae0b6da028c13af46b768b95c2a86fba92dda93df5d1b410996978ea9e74f32d6d18a0afb68faa7f

[mirrors]
http://libarchive.googlecode.com/files/libarchive-2.8.4.tar.gz

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CFLAGS="$optcflags -D_BSD_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
    --with-pic \
    --without-openssl \
    --without-xml2 \
    --without-expat \
    --enable-shared --enable-static
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libarchive


code:
[mirrors]
https://github.com/libass/libass/releases/download/0.13.2/libass-0.13.2.tar.xz

[vars]
filesize=348444
sha512=71d495c02ea478b8632c177cef8605d23377e2da2c56dd3a1fa59f9a2d01cc642d4d9dc383083ef1dee8ccf2a6e6f25a4ad9bb7dff3618e7646161731b7312c7

[deps]
libpng
fontconfig
fribidi

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir --disable-asm"
CFLAGS="-D_BSD_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libass


code:
[mirrors]
https://www.gnupg.org/ftp/gcrypt/libassuan/libassuan-2.4.2.tar.bz2
http://mirror.tje.me.uk/pub/mirrors/ftp.gnupg.org/libassuan/libassuan-2.4.2.tar.bz2

[vars]
filesize=587631
sha512=175f9807b7c960750d8177bc879be1476b7948c9af17cce48a60e8ef35cf1f62dc0909fe6c53898d0ac0b991aa22d6aa0720bfbc48894a89775d32f287ea9f7b

[deps]
libgpg-error

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir \
  --with-gpg-error-prefix=$butch_root_dir$butch_prefix"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libassuan


code:
[vars]
filesize=465710
sha512=3a431e038db2961612bd22ba632a60618a72a62bb724a1e603adf670711ea389d9e0b6233017b1394d8ebf8b372dc250fc6958f026df225911b901179ea24e6b

[mirrors]
http://www.ivmaisoft.com/_bin/atomic_ops//libatomic_ops-7.4.2.tar.gz

[build]
sed -i 's#pkgdata#doc#g' doc/Makefile.in Makefile.in
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags \
            --enable-shared  \
            --disable-static \
            --docdir="$butch_prefix"/share/doc/libatomic_ops-7.4.2

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libatomic-ops


code:
[vars]
tarball=util-linux-$(cat "$K"/util-linux.version).tar.xz

[deps]
util-linux-tarball

[build]
patch -p1 < "$K"/util-linux.patch
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="-static $optldflags" \
  ./configure -C --prefix="$butch_prefix" --without-ncurses --disable-shared  \
                 --disable-nls --disable-rpath --disable-tls --disable-libuuid \
                 --disable-libmount --disable-mount --disable-losetup \
                 --disable-cytune --disable-fsck --disable-partx \
                 --disable-uuidd --disable-mountpoint --disable-fallocate \
                 --disable-unshare --disable-nsenter --disable-setpriv \
                 --disable-eject --disable-agetty --disable-cramfs --disable-bfs \
                 --disable-fdformat --disable-hwclock --disable-wdctl \
                 --disable-switch_root --disable-pivot_root --disable-kill \
                 --disable-utmpdump --disable-raw --disable-rename \
                 --disable-chfn-chsh-password --disable-chsh-only-listed \
                 --disable-login --disable-sulogin --disable-su --disable-runuser \
                 --disable-ul --disable-more --disable-pg --disable-setterm \
                 --disable-schedutils --disable-wall --disable-bash-completion \
                 --disable-pg-bell --disable-use-tty-group \
                 --disable-makeinstall-chown --disable-makeinstall-setuid \
                 --enable-libblkid --enable-partx $xconfflags
make -j$MAKE_THREADS libblkid.la libblkid/blkid.pc
dest="$butch_install_dir""$butch_prefix"
install -D -m 644 .libs/libblkid.a "$dest"/lib/libblkid.a
install -D -m 644 .libs/libblkid.la "$dest"/lib/libblkid.la
install -D -m 644 libblkid/blkid.pc "$dest"/lib/pkgconfig/blkid.pc
install -D -m 644 libblkid/src/blkid.h "$dest"/include/blkid/blkid.h

path: pkg/libblkid


code:
[mirrors]
http://ftp.de.debian.org/debian/pool/main/libc/libcap2/libcap2_2.22.orig.tar.gz

[vars]
filesize=67432
sha512=b66cd3e233cab9c35334c3ed824f2b6207a46b7320be0a29f5290a32cbf4ea7c4fbf22125541cfa25fdd7466d9c14373ff5f68b53fe44036af6763d3ff1cb398
tardir=libcap-2.22

[deps]
attr

[deps.host]
perl

[build]
sed -i 's@/bin/bash@/bin/sh@g' progs/capsh.c
make -j$MAKE_THREADS prefix="$butch_prefix" lib=lib \
  CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  BUILD_CC="$HOSTCC" CC="$CC"

make RAISE_SETFCAP=no FAKEROOT="$butch_install_dir" prefix="$butch_prefix" lib=lib install
LIBDIR=$butch_install_dir$butch_prefix/lib
SBINDIR=$butch_install_dir$butch_prefix/sbin

LD_LIBRARY_PATH=${LIBDIR} ${SBINDIR}/setcap cap_setfcap=i ${SBINDIR}/setcap || echo \
  "there was an error setting caps, you may want to investigate this"


code:
[mirrors]
http://distro.ibiblio.org/quirky/quirky6/sources/t2/april/libcddb-1.3.2.tar.bz2

[vars]
filesize=352909
sha512=0e07e7d37f2013164d75b530a5528f54847271fd20f3b7bedb192a05d1f61dcf006d10dc2927efe155a01eddcc57b940bc31d8ac88d5dfc4f1a09771caa84e0a
desc="Libcddb is a C library to access data on a CDDB server"

[deps]

[build]
CFLAGS="$optcflags" \
  LDFLAGS="$optldflags" \
    ./configure --prefix="$butch_prefix" $xconfflags \
      --enable-shared --disable-static
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libcddb


code:
[mirrors]
http://ftp.gnu.org/gnu/libcdio/libcdio-0.93.tar.bz2

[vars]
filesize=1871349
sha512=c28feba1d2489dd4a3e5985d3edb064e4d94ccca09c96279086b172ece0ab649cbce06304c65f37b30efbdcdf6cb5616efa48a937d8d9a371c79b1731a142b45
desc="A CD-ROM reading and control library"

[deps]
libcddb

[build]
CFLAGS="$optcflags" \
  LDFLAGS="$optldflags" \
    ./configure --prefix="$butch_prefix" $xconfflags \
      --enable-shared --disable-static
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libcdio


code:
[mirrors]
http://ftp.gnu.org/gnu/libcdio/libcdio-paranoia-10.2+0.93+1.tar.bz2

[vars]
filesize=557271
sha512=b21b71243b1afe9ac9c31ea7f1acb3f61e9069bb640f0052e39f3774886d0be2fa3844abe92cccc519a9e3e14d3df76a3326f5a5e9ecb5e96462edfee01b55e8
desc="CD-ripper library, replacement for cdparanoia package."

[deps]
libcdio

[build]
CFLAGS="$optcflags" \
  LDFLAGS="$optldflags" \
    ./configure --prefix="$butch_prefix" $xconfflags \
      --enable-shared --disable-static
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

[ -f $butch_install_dir/bin/cd-paranoia ] && ln -s cd-paranoia $butch_install_dir/bin/cdparanoia

path: pkg/libcdio-paranoia


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libcroco/0.6/libcroco-0.6.11.tar.xz

[vars]
filesize=477312
sha512=441b9c6d9b6acd4ff908100573c6f24bcf46a20ec94360bdcf4765e37a7d45dc59e6a0889917f3486503b274d05cd79a63178e74d029209c16b8e3351a1160da

[deps]
glib
libxml2

[build]
#patch -p1 < "$K"/some.patch

[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libcroco


code:
[vars]
filesize=249426
sha512=1efbe4ff2d7bf1716547c9377a8eefefd5392ce9fa62ee07bc948fc5b8832cefeecebf655a40e49eefe4ec857978dfee5a66a0439e36e4440e0ec472e2226ddb

[mirrors]
http://downloads.sourceforge.net/project/libcue/libcue/1.4.0/libcue-1.4.0.tar.bz2

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libcue


code:
[mirrors]
http://0pointer.de/lennart/projects/libdaemon/libdaemon-0.14.tar.gz

[vars]
filesize=340474
sha512=a96b25c09bd63cc192c1c5f8b5bf34cc6ad0c32d42ac14b520add611423b6ad3d64091a47e0c7ab9a94476a5e645529abccea3ed6b23596567163fba88131ff2
desc="A lightweight C library which eases the writing of UNIX daemons"

[deps]

[build]
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure --prefix="$butch_prefix" $xconfflags \
  --disable-lynx --disable-examples

make -j$MAKE_THREADS || exit 1

make V=1 DESTDIR="$butch_install_dir" install

path: pkg/libdaemon


code:
[deps]
lvm

path: pkg/libdevmapper


code:
[deps]
dmxproto
xproto
libx11

[vars]
filesize=290859
sha512=551cbba06e87ddc6f9a1f4567de4b8c592a4b6f6b6c27970c67c644ffe5c7f396e3c64c6df564d83a73f1b3842ba0a29a2463580fc0a264c552d76fbcba5a021

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libdmx-1.1.3.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libdmx


code:
[mirrors]
http://dri.freedesktop.org/libdrm/libdrm-2.4.60.tar.bz2

[vars]
filesize=581786
sha512=d0cee293c222e9b45cb12999b45bec1d94f7faf662f011f70252df7efdda95706fb2da6805e0957f4e4c12c79974cf21233f1109a607c67cd27aab5fde27e801

[deps]
libpciaccess
libpthread-stubs

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-cairo-tests
make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libdrm


code:
[mirrors]
http://heanet.dl.sourceforge.net/project/dumb/dumb/0.9.3/dumb-0.9.3.tar.gz
http://surfnet.dl.sourceforge.net/project/dumb/dumb/0.9.3/dumb-0.9.3.tar.gz
http://switch.dl.sourceforge.net/project/dumb/dumb/0.9.3/dumb-0.9.3.tar.gz

[vars]
filesize=167379
sha512=9ecdea460858b7e6ad7ca2534ecb3581397e6c1fa904459affe19ce49f528e580e143b42b13413b292ae7b57901a8008e6a9ee3821824f6ff7914b136f75c658

[deps]
allegro4

[build]
patch -p1 < "$K"/dumb-Makefile-DESTDIR.patch

cat << EOF > make/config.txt
include make/unix.inc
ALL_TARGETS := core core-examples core-headers
ALL_TARGETS += allegro allegro-examples allegro-headers
PREFIX := $butch_prefix
DESTDIR := $butch_install_dir
EOF

dest="$butch_install_dir""$butch_prefix"
mkdir -p "$dest/bin"
mkdir -p "$dest/lib"
mkdir -p "$dest/include"

mkdir -p bin
printf "#!/bin/sh\necho -lalleg -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib\n" > bin/allegro-config
chmod +x bin/allegro-config
export PATH="$PWD/bin:$PATH"

make -j$MAKE_THREADS CC="$CC"
make DESTDIR="$butch_install_dir" install

path: pkg/libdumb


code:
[mirrors]
http://www.prevanders.net/libdwarf-20130729.tar.gz

[vars]
filesize=1533828
sha512=f9d25cfd6c6b15bebf6cd63c7014ecf4123798fce637c0da103008758d6a9d5705c3797216a8d1ab3e210c4235f199ab19d7ed0bf6c3582f49eacba1629c5cc0
tardir=dwarf-20130729

[deps]
libelf

[build]
patch -p1 < "$K"/libdwarf-xcompile.patch
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

for dir in libdwarf dwarfdump ; do
echo XXX entering dir $dir
[ -n "$CROSS_COMPILE" ] && [ $dir = dwarfdump ] && continue
cd $dir
cp ../config.cache .

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
# the make target of dwarfdump is broken for concurrent build
[ $dir = dwarfdump ] && MAKE_THREADS=1
make -j$MAKE_THREADS
cd ..
done

# libdwarf lacks make install
dest="$butch_install_dir""$butch_prefix"
install -D -m 755 libdwarf/libdwarf.a "$dest"/lib/libdwarf.a
install -D -m 755 libdwarf/libdwarf.h "$dest"/include/libdwarf.h
install -D -m 755 libdwarf/dwarf.h "$dest"/include/dwarf.h
[ -n "$CROSS_COMPILE" ] || install -D -m 755 dwarfdump/dwarfdump "$dest"/bin/dwarfdump
[ -n "$CROSS_COMPILE" ] || install -D -m 755 dwarfdump/dwarfdump.1 "$dest"/share/man/man1/dwarfdump.1

path: pkg/libdwarf


code:
[mirrors]
http://www.thrysoee.dk/editline/libedit-20121213-3.0.tar.gz

[vars]
filesize=473665
sha512=06420df987429bdec6aea216046548cb7d1e1ed004e140c01692625dfb9149cc42ad98755a467c8b26734caff19284cb581bf64d58e49f683445ea01625d146b

[deps]
curses

[build]
patch -p1 < "$K"/libedit_readlineh.patch

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"

CFLAGS="-D_GNU_SOURCE -D_BSD_SOURCE -D__STDC_ISO_10646__ $optcflags" \
  ./configure -C --prefix="$butch_prefix" --enable-widec $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

# use libedit as a readline drop-in replacement (it has 10 KLOC less, 20 instead of 30)
dest="$butch_install_dir""$butch_prefix"
ln -sf libedit.a "$dest"/lib/libreadline.a
ln -sf libedit.so "$dest"/lib/libreadline.so
mkdir -p "$dest"/include/readline
touch "$dest"/include/readline/history.h
touch "$dest"/include/readline/tilde.h
ln -sf ../editline/readline.h "$dest"/include/readline/readline.h

path: pkg/libedit


code:
[mirrors]
http://codu.org/~rofl/tarballs/libelf-compat-0.152c001.tar.bz2
http://ftp.barfooze.de/pub/sabotage/tarballs/libelf-compat-0.152c001.tar.bz2
http://foss.aueb.gr/mirrors/linux/sabotage/tarballs/libelf-compat-0.152c001.tar.bz2
http://dl.2f30.org/mirrors/sabotage/tarballs/libelf-compat-0.152c001.tar.bz2

[vars]
filesize=122231
sha512=442ec322d3751f1e755a18c852ca5ade745387fb6b8526f40c451a8459eb31ac3bec091aceae5feddf91ded9deda5c359d83e92122bde6789b5324bdc47f6deb

[deps]

[build]
[ "$A" = "mips" ] && sed -i 's@__thread@@' src/elf_error.c
# ^ tls is not crucial for libelf, as gcc is single threaded and the only user of it
# having it there makes the build fail with gcc 3.4.6 mips

echo "CFLAGS += $optcflags" > config.mak
sed -i 's@HEADERS = src/libelf.h@HEADERS = src/libelf.h src/gelf.h@' Makefile
make -j$MAKE_THREADS
make prefix="$butch_prefix" DESTDIR="$butch_install_dir" install

path: pkg/libelf


code:
[vars]
tardir=libepoxy-1.2
filesize=267110
sha512=1104fc7e6cbb4bb95e422e7801491067806df6849690be4068b5eec33a5fc84672a5bb4666357e9a46d2fae436f83b37402b6cc0c4ee69627e48d48a4d32a2ed

[mirrors]
http://ftp.cc.uoc.gr/mirrors/linux/lfs/LFS/conglomeration/libepoxy/libepoxy-1.2.tar.gz

[deps]
libx11
mesalib

[deps.host]
autoconf
automake
libtool
python

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

autoreconf -i
CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libepoxy


code:
[mirrors]
http://libestr.adiscon.com/files/download/libestr-0.1.9.tar.gz
[vars]
filesize=330114
sha512=17e1a62d2d4cb7e33dc14d4368b507fff1676c5a2cb24001078ff2a6f15236f9674dc47a599900c94ae2bd0e58dbe56b084d01d5a17174e5a54884d1f4c7616c

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure --prefix="$butch_prefix" $xconfflags \
     ac_cv_func_malloc_0_nonnull=yes \
     ac_cv_func_realloc_0_nonnull=yes

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libestr


code:
[mirrors]
http://dist.schmorp.de/libev/Attic/libev-4.15.tar.gz

[vars]
filesize=513919
sha512=bb3ab98d92e565bf2273d71c9004b84ad3b305c4e883482392fe6c701949344731bb4e391ac77578f71d9a80f0ec4b6afc2ae5449d4093cdcbee26d7dc17929d

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags &&
make -j$MAKE_THREADS && make DESTDIR="$butch_install_dir" install
rm "$butch_install_dir""$butch_prefix"/include/event.h

path: pkg/libev


code:
[mirrors]
http://prdownloads.sourceforge.net/levent/libevent-2.0.22-stable.tar.gz
http://kent.dl.sourceforge.net/project/levent/libevent/libevent-2.0/libevent-2.0.22-stable.tar.gz
http://switch.dl.sourceforge.net/project/levent/libevent/libevent-2.0/libevent-2.0.22-stable.tar.gz

[vars]
filesize=854987
sha512=990637f12e890bfa7f86c194c8b112701436e92b60afb829194879efb85d558b986261e6508fe29bde73981feada874438e2d442cec8ea5730c889954f9bc907
uchkurl=https://github.com/libevent/libevent/releases

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CFLAGS="-D_GNU_SOURCE -D_BSD_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libevent


code:
[vars]
filesize=1368435
sha512=4e0fe2abe85d1c95b41cb3abe1f6333dc3a9eb69dba106a674a78d74a4d5b9c5a19647118fa1cc2d72b98a29853394f1519eda9e2889eb28d3be26b21c7cfc35

[mirrors]
http://downloads.sf.net/sourceforge/libexif/libexif-0.6.21.tar.bz2

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libexif


code:
[mirrors]
ftp://mirrors.kernel.org/sources.redhat.com/libffi/libffi-3.0.13.tar.gz
http://mirrors.kernel.org/sources.redhat.com/libffi/libffi-3.0.13.tar.gz

[vars]
filesize=845747
sha512=fc47f5d25197c631754efe05a349edb556d072807ecef19b41f17c1a8f39c95221be64926fbd05b1f8439181df1ddff8fc01462ce3a26005b75159ddc27e6f6a
desc='foreign function interface lib. used by script langs to interface with C.'

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-libtool-sysroot=$butch_root_dir"
CFLAGS=-D_GNU_SOURCE ./configure -C \
  --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install
dest="$butch_install_dir""$butch_prefix"
if [ "$A" = x86_64 ] ; then
	mv "$dest"/lib64/* "$dest"/lib/ || true
	sed -i 's,/lib/../lib64,/lib,' "$dest"/lib/libffi.la
fi

path: pkg/libffi


code:
[mirrors]
http://downloads.xiph.org/releases/flac/flac-1.3.1.tar.xz

[vars]
filesize=941848
sha512=923cd0ffe2155636febf2b4633791bc83370d57080461b97ebb69ea21a4b1be7c0ff376c7fc8ca3979af4714e761112114a24b49ff6c80228b58b929db6e96d5

[deps]

[build]
# apply patch to prevent CFLAGS manipulation in ./configure
patch -p1 -l < "$K"/libflac-prevent-cflag-manipulation.patch
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
testlib() {
	printf "int main() {}\n" > test_lib.c
	$CC test_lib.c -l$1 >/dev/null 2>&1
}
testlib ogg && \
  oggflags="--with-ogg-libraries=$butch_root_dir$butch_prefix/lib --with-ogg-includes=$butch_root_dir$butch_prefix/include" || \
  oggflags="--disable-ogg"

CFLAGS="$optcflags -D_GNU_SOURCE" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags $oggflags

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
# build only libFLAC and not all the C++ crap
make -j$MAKE_THREADS -C src/libFLAC
make DESTDIR="$butch_install_dir" -C src/libFLAC install

echo installing headers
make -j$MAKE_THREADS -C include
make DESTDIR="$butch_install_dir" -C include install

path: pkg/libflac


code:
[mirrors]
http://ftp.barfooze.de/pub/sabotage/tarballs/libfm-1.0rc1.tar.gz
http://foss.aueb.gr/mirrors/linux/sabotage/tarballs/libfm-1.0rc1.tar.gz
http://dl.2f30.org/mirrors/sabotage/tarballs/libfm-1.0rc1.tar.gz

[vars]
filesize=985089
sha512=12af732321a99320ea05e2692877c9d9631a83394ceecf559ab84874599f6d7646d353595288e2260ae0af83ae6faa1f5f33247e3eba80da6185e8168102629a

[deps]
gtk+2
menu-cache

[deps.host]
pkgconf
perl
perl5-XML-Parser
intltool

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')  --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

for i in po ; do
	printf 'all:\n\ttrue\ninstall:\n\ttrue\clean:\n\ttrue\n' > "$i"/Makefile
done

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libfm


code:
[deps.host]
pkgconf

[deps]
xproto

[vars]
filesize=294884
sha512=e0905592b7ef65acb8298b9807f90e68d18eddf3112c6232c1c774603c95ca7ec7f6db161e133dadc00d8791c5f76d4c3d65aa95544a1500c0767b88fdb52f45

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libfontenc-1.1.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libfontenc


code:
[deps]
xproto
libx11

[vars]
filesize=303806
sha512=21d3ba66b33eeffdcbe4e963235dcab1cc510686f9f2f616c25b44028faee66f1a12e087f27c53a4bc495f34c60949dfe834977a14ca12ec48c5be818abe1f94

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libFS-1.0.5.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libfs


code:
[mirrors]
http://www.hboehm.info/gc/gc_source/gc-7.2d.tar.gz

[vars]
filesize=1263064
sha512=5b342754a1efeef0cf78983b7a0e48a36495beac04fc881ab356b26dc153b343e940ec7af070f4fc875be44adc559f7be995919fe9229f68d2e0237cdbeaabcc
tardir=gc-7.2

[build]
patch -p0 < "$K"/libgc-configure.patch
patch -p1 < "$K"/libgc-os_dep.patch

# -DUSE_PROC_FOR_LIBRARIES

touch include/execinfo.h

[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CFLAGS="-D_GNU_SOURCE -DNO_GETCONTEXT -DSEARCH_FOR_DATA_START -DUSE_MMAP \
-DHAVE_DL_ITERATE_PHDR $optcflags" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --enable-cplusplus \
  --enable-threads=pthreads \

#  --disable-threads \

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libgc


code:
[mirrors]
ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.7.0.tar.bz2
http://ftp.heanet.ie/mirrors/ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.7.0.tar.bz2
http://mirrors.dotsrc.org/gcrypt/libgcrypt/libgcrypt-1.7.0.tar.bz2
http://dbg.download.sourcemage.org/mirror/libgcrypt-1.7.0.tar.bz2

[vars]
filesize=2840453
sha512=658eca9161d104b81c249dc47d9e4f2df58f26c63bd28ee9ad7a642fd84f09faddbde51e070bc923bfd54fb5785acf8ff2f0da244e6b497b57407f5f67c3574b

[deps]
libgpg-error

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"
printf '#!/bin/sh\n[ "$1" = --version ] && echo 1.19 || echo -lgpg-error\n' \
  > gpg-error-config
chmod +x gpg-error-config
export PATH="$PWD:$PATH"

CPPFLAGS=-D_GNU_SOURCE  CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-asm $xconfflags
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libgcrypt


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libglade/2.6/libglade-2.6.4.tar.bz2

[vars]
filesize=356119
sha512=b725842febaf4c1f0d305a629ae1c61ea2de24dd6f41937e806c078fada2cea483195ef40f5238ce2045e47130c92559e984f677de667b840dd7fff0f8559735

[deps]
gtk+2
libxml2

[build]
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > tests/Makefile.in
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="-D_GNU_SOURCE $optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libglade


code:
[mirrors]
ftp://ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.19.tar.bz2
http://luci.subsignal.org/~trondah/tree/dl/libgpg-error-1.19.tar.bz2
http://x.vm0.ru/wl500g-repo/sources-mirror/libgpg-error-1.19.tar.bz2
http://mirrors.dotsrc.org/gcrypt/libgpg-error/libgpg-error-1.19.tar.bz2
http://ftp.heanet.ie/mirrors/ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.19.tar.bz2

[vars]
filesize=761622
sha512=24ac1799260611f6fe3d0931fbb735f6e7e9d3a794190fba71c71d0324230f635655db96db134a1ddf56ea9c46654feb4ea2649c31e6ee31c9fd1ca41e86b56b

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CPPFLAGS=-D_GNU_SOURCE CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-nls
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libgpg-error


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libgsf/1.14/libgsf-1.14.33.tar.xz

[vars]
filesize=608364
sha512=9dbda65a610f3e6efaf40bb51ed9ebabe485e0c2c9c8d0ff155ae39fa1aa3074df8094f51d9b0f27eb251b1aed4b4faa77ffce4d6dc16ef7c99c5b697528be5f

[deps]
libxml2
glib
intltool
gdk-pixbuf

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
cp -f "$K"/config.sub .
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
CPPFLAGS=-D_GNU_SOURCE \
  ./configure -C --prefix="$butch_prefix" $xconfflags

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

for i in po ; do
	printf 'all:\n\ttrue\ninstall:\n\ttrue\clean:\n\ttrue\n' > "$i"/Makefile
done

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libgsf


code:
[vars]
filesize=257528
sha512=682e08f1a406bd323a59268d9d2fde9efd015a7e0cd5958c5c4e0bc94b593d071a9b824c8b9dfc104c93e555342b1a74a63da91834e10558a9646c9195ef6fbd

[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libgudev/230/libgudev-230.tar.xz

[deps]
glib
eudev

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libgudev


code:
[deps.host]
pkgconf

[deps]
xproto
xtrans

[vars]
filesize=365762
sha512=eac189813df84c0d1b5a4f59855a147c945cb6960bb91dd3d94b2fbe909609a3da1d250bea4a0c8090b4dc64b4f64eb548b67a39de719ebddce19c6c1394532e

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libICE-1.0.8.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libice


code:
[mirrors]
http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.14.tar.gz

[vars]
filesize=4984397
sha512=b96774fefc4fa1d07948fcc667027701373c34ebf9c4101000428e048addd85a5bb5e05e59f80eb783a3054a3a8a3c0da909450053275bbbf3ffde511eb3f387
desc="Library converting between character encodings"

[deps]

[build]
CFLAGS="$optcflags" \
  LDFLAGS="$optldflags" \
    ./configure --prefix="$butch_prefix" $xconfflags \
      --enable-shared --disable-static
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libiconv


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libIDL/0.8/libIDL-0.8.14.tar.bz2

[vars]
filesize=427149
sha512=906dde087908acd64b209fe466a89ae52a6ea23601cb30092063a6e062b1b6640fc2d5f422efcdd52b2b36ce20e6c244da6205fde0bdcec787fe64058be7adac

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  libIDL_cv_long_long_format=ll
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libidl


code:
[mirrors]
http://www.ijg.org/files/jpegsrc.v8d.tar.gz

[vars]
filesize=991456
sha512=7a8b4cff5b1caf6a7281c5dce4e1efa1b68360bd64dd2e619b60c9e1d49f22624bc8780b681bfab073e7b1d4b7f41008a464a58f0eeeacb0a40ff996d7eb5753
tardir=jpeg-8d

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure --prefix="$butch_prefix" \
    --disable-dso --enable-shared --with-pic $xconfflags

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libjpeg


code:
[mirrors]
http://mirror.tje.me.uk/pub/mirrors/ftp.gnupg.org/libksba/libksba-1.3.0.tar.bz2

[vars]
filesize=624704
sha512=51023119346fb7ffa31eee205376b7efb0fab42dee73c669c3174c2ebf4100008d3f508f8d49da27b1ea865c46d407b430c47ce503a8d63c069f59132ee638d9

[deps]
libgpg-error

[build]
CFLAGS=-D_GNU_SOURCE ./configure -C --prefix="$butch_prefix"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libksba


code:
[mirrors]
http://sourceforge.net/projects/lcms/files/lcms/1.19/lcms-1.19.tar.gz

[vars]
filesize=927752
sha512=85a55ad0673f0df2aaa80d18caa50314319f8da5ee4d84eed919059d0dad9861d684ef6353ce0ec6f9892a4603ce8e8e12f84d46858e23f52846b8aefd3cf449

[deps]
libjpeg
libtiff

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CPPFLAGS=-D_GNU_SOURCE \
CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/liblcms


code:
[mirrors]
http://leptonica.com/source/leptonica-1.73.tar.gz

[vars]
filesize=10894175
sha512=4808474d5941a91fbf542a22fed26ddc33f9c4baf2699096acf5e894b7e4e84889d165373b7d1df391a68cda8176113cf122f15203a9e38d3059e17140efc575
uchkurl=http://leptonica.com/download.html

[deps]
zlib
libpng
libjpeg
libtiff
giflib

[build]
patch -p1 < "$K"/liblepton_pngio.patch
patch -p1 < "$K"/liblepton-endianness.patch
#CFLAGS=-D_GNU_SOURCE ./configure -C --prefix="$butch_prefix"
cd src

sed -i 's/HAVE_LIBGIF/1/' gifio.c

make -j$MAKE_THREADS -f makefile.static CC="$CC -ansi -D_BSD_SOURCE -DANSI"

# installing headers
dest="$butch_install_dir/include/leptonica"
mkdir -p "$dest"
cp *.h "$dest"/

#installing lib
dest="$butch_install_dir/lib"
mkdir -p "$dest"
cp ../lib/nodebug/liblept.a "$dest"/

#make DESTDIR="$butch_install_dir" -f makefile.static install

path: pkg/liblepton


code:
[mirrors]
http://download.rsyslog.com/liblogging/liblogging-1.0.1.tar.gz

[vars]
filesize=524168
sha512=843c1a99f89835fde9352974df3bd217409a0093a6df8777499a0c5e605fc5722b150b505dc45c2bf15e8d20d5eeb7cbab14475a7112fe7401d5f2b398cd17eb

[build]
cp -f "$K"/config.sub .
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/liblogging


code:
[mirrors]
http://heanet.dl.sourceforge.net/project/mad/libmad/0.15.1b/libmad-0.15.1b.tar.gz
http://surfnet.dl.sourceforge.net/project/mad/libmad/0.15.1b/libmad-0.15.1b.tar.gz
http://switch.dl.sourceforge.net/project/mad/libmad/0.15.1b/libmad-0.15.1b.tar.gz

[vars]
filesize=502379
sha512=2cad30347fb310dc605c46bacd9da117f447a5cabedd8fefdb24ab5de641429e5ec5ce8af7aefa6a75a3f545d3adfa255e3fa0a2d50971f76bc0c4fc0400cc45

[deps]

[build]
# patch from debian: http://patch-tracker.debian.org/package/libmad
patch -p1 < "$K"/libmad-mips-asm.patch
cp -f "$K"/config.sub .

# there are other debian patches that may be interesting, also:
# http://m.baert.free.fr/contrib/docs/libmad/ (documentation patch)
# AVR32 patch http://www.mars.org/pipermail/mad-dev/2010-March/001410.html

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
CPPFLAGS=-D_GNU_SOURCE \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libmad


code:
[mirrors]
http://downloads.sourceforge.net/project/mikmod/libmikmod/3.3.6/libmikmod-3.3.6.tar.gz

[vars]
filesize=1288510
sha512=708008d162bac1a17b090a3a56e3078bb3ce42cb0d54b1e57963881d060198e841654ec7a72212aa9dc0e5c8bd95ec1c41ddd58e2db8c6e91a29d22d7bf363a0

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install
rm "$butch_install_dir""$butch_prefix"/bin/libmikmod-config

path: pkg/libmikmod


code:
[mirrors]
http://heanet.dl.sourceforge.net/project/libmng/libmng-devel/1.0.10/libmng-1.0.10.tar.gz

[vars]
filesize=1093337
sha512=302d792af76140d8511ac2f88b5c2a8de01261bbbcd21c83903d94d3f20f1e84a0658827e78ae863499d8f1b466c26641b714dc7e11d06366e64a9966fb18ba1

[deps]
libpng
liblcms

[build]
#CFLAGS=-D_GNU_SOURCE ./configure -C --prefix="$butch_prefix"
cp "$K"/libmng.Makefile Makefile
echo prefix=$butch_prefix > config.mak
make CC="$CC" -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libmng


code:
[mirrors]
http://downloads.sourceforge.net/project/libnet-dev/libnet-1.2-rc3.tar.gz

[vars]
filesize=676205
sha512=4f1c5c1a72e2c35ca3add772cb1af63e8245bb5c127e4a74fb9f619f987a4ea047bf17caaa292e9b7fa7642635773b90975d013644be0383dca93d688ca8430d

[deps]

[build]
patch -p1 < "$K"/libnet-kernelheaders.patch

[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libnet


code:
[mirrors]
http://ftp.gnu.org/gnu/nettle/nettle-3.1.1.tar.gz

[vars]
filesize=1851876
sha512=b0a52e1569ff11d871165a689fdc2a0b2f478bcc3122f39df9751b7b1c915d4240ec57d22e98034cf2b5130dddcf5dc57fe26278a2f41c15f669f65814768de1

[deps]
gmp

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"
CPPFLAGS=-D_GNU_SOURCE \
CFLAGS="$optcflags -fPIC" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install
dest="$butch_install_dir""$butch_prefix"
sed -i 's@#.*$@@g' "$dest"/lib/pkgconfig/hogweed.pc

path: pkg/libnettle


code:
[mirrors]
http://downloads.sourceforge.net/project/libnids/libnids/1.24/libnids-1.24.tar.gz

[vars]
filesize=151021
sha512=2046900023e853d7dbd7061c9f47d8a8ba26320991ca34198249019c1b9a6f75010574f9f022d02976272a384cf769394c4cc3ae536fc6164716cadc4770bb53

[deps]
libpcap
libnet
glib

[build]
patch -p1 < "$K"/libnids-xcompile.patch
patch -p1 < "$K"/libnids-DESTDIR.patch

[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libnids


code:
[mirrors]
http://ftp.barfooze.de/pub/sabotage/tarballs/libnl-tiny-1.0.1.tar.xz
http://foss.aueb.gr/mirrors/linux/sabotage/tarballs/libnl-tiny-1.0.1.tar.xz
http://dl.2f30.org/mirrors/sabotage/tarballs/libnl-tiny-1.0.1.tar.xz

[vars]
filesize=49980
sha512=bd2114d20daf246b4d4ed5aa8c62122e73bfa076f3c4298179506ddb09d52626d3cbd4462bcafa5977ce7d80de4850acd7081cba2b30ad21e3a38bd18525b31a

[deps]

[build]
patch -p1 < "$K"/libnl-tiny-Makefile.patch
make CC="$CC" CFLAGS="$optcflags" prefix="$butch_prefix" \
  -j$MAKE_THREADS DESTDIR="$butch_install_dir" \
  AR="$CROSS_COMPILE"ar RANLIB="$CROSS_COMPILE"ranlib \
  all install

path: pkg/libnl-tiny


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libnotify/0.5/libnotify-0.5.2.tar.bz2

[vars]
filesize=310439
sha512=3d9f72a493640448bb675d40e108fc021b7a33a8eb25c6455089ae5c351f4f76d1ba24c685acfb50a6a7d6688089172806ae836a28d0ef40d8f68d42f83e9e43

[deps]
gtk+2
dbus-glib

[build]
CFLAGS=-D_GNU_SOURCE ./configure -C --prefix="$butch_prefix"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install


code:
[mirrors]
http://downloads.xiph.org/releases/ogg/libogg-1.3.2.tar.xz

[vars]
filesize=407324
sha512=dc9552b15ceccd7e12bff39a6670120ae53af74ce97254d047c28f49ba6a320f55059ed509ec1d8758a972c72514f2866634d829f3cb528c2f595cb056e9bca6

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags -D_GNU_SOURCE" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libogg


code:
[mirrors]
http://downloads.xiph.org/releases/opus/opus-1.1.1-beta.tar.gz

[vars]
filesize=913599
sha512=9d885ddd19644c45b20b1f3bafec462fa4c22001a2c8a62658b4420bb7fef8964fe9a2bbd28837abdd92be715d134b3f6c8afcab22b0fa47a304e16ef770328d

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libopus


code:
[mirrors]
http://www.tcpdump.org/release/libpcap-1.6.1.tar.gz
http://www.uk.tcpdump.org/release/libpcap-1.6.1.tar.gz
http://tcpdump.cybermirror.org/release/libpcap-1.6.1.tar.gz

[vars]
filesize=651061
sha512=721f20ccf93d0a033945a8ed618dad2aeb7334eea26ee128f2eebf65e19bd6523698191e59e727adb83b96f4ca45f2f218f9af94af9923453c06a57cab36487b

[deps]
libnl-tiny

[deps.host]
flex
bison

[build]
[ -n "$CROSS_COMPILE" ] && \
xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-pcap=linux"

# package causes gcc breakage when lto is used
if [ x$A = xmips ] ; then
  optldflags=$(printf "%s" "$optldflags"|sed 's/-flto//g')
  optcflags=$(printf "%s" "$optcflags"|sed 's/-flto//g')
fi
CFLAGS="-D_GNU_SOURCE -D_BSD_SOURCE -DIPPROTO_HOPOPTS=0 \
-I$butch_root_dir$butch_prefix/include/libnl-tiny $optcflags" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" \
  --disable-canusb \
  ac_cv_type_u_int64_t=yes $xconfflags
sed -i 's@-lnl-genl@-lnl-tiny@' Makefile
make -j$MAKE_THREADS AR="$CROSS_COMPILE"ar RANLIB="$CROSS_COMPILE"ranlib
make DESTDIR="$butch_install_dir" AR="$CROSS_COMPILE"ar \
     RANLIB="$CROSS_COMPILE"ranlib install

path: pkg/libpcap


code:
[mirrors]
http://xorg.freedesktop.org/archive/individual/lib/libpciaccess-0.13.2.tar.bz2
[vars]
filesize=359231
sha512=312d891c1337256c9aeeda2c743907ce8c51444a165a97d2007fd2f8d05cafab37cf16e85288244490e514bcfbd7ba050d985130efe3dc2f6ed316dd46e6ad1d

[deps]

[build]
patch -p1 < "$K"/libpciaccess_PATH_MAX.patch
patch -p1 < "$K"/libpciaccess-arm.patch

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libpciaccess


code:
[mirrors]
http://downloads.sourceforge.net/sourceforge/libpng/libpng-1.5.26.tar.xz

[vars]
filesize=748164
sha512=87214671af84665277f0ac3226e6feb41a3e1deb0d7d61e62c99e77d1386fcf928b21f9863c4166a7391230166190bad00e57c3fc42902b3a0a53ba68d4db1f5
desc="library to handle png files with a history of sec. vulns and API breakage"
uchkurl=ftp://ftp.simplesystems.org/pub/libpng/png/src/libpng15/

[deps]
zlib

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libpng


code:
[mirrors]
http://downloads.sourceforge.net/project/libpng/libpng12/1.2.56/libpng-1.2.56.tar.gz

[vars]
filesize=1114806
sha512=f29082281fb25184cca7897635557bc281e4f4dc91e7bf7a7458d14e8684c9c839ec24b88144bcdaeec2d0b0a0d7c11787f2cd41a5a3fc70523801125b330e28
desc="library to handle png files with a history of sec. vulns and API breakage"

[deps]
zlib

[build]
#note, major distros such as Ubuntu, Debian and Puppy have stayed with the 1.2.x series.
#after some frustration in Sabotage trying to compile netpbm with libpng 1.5.x, have rolled back.
#the 1.2.x series is still actively updated!

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install


code:
[vars]
filesize=203468
sha512=c7cf63fa82ce9e8c37c6dc3b8cc30f8883655f95683c4466c54b617b086dd26a43bfa36363e47dc5730af6d59ac70443d211eb01b07d276edd144030a3580b15

[mirrors]
http://xcb.freedesktop.org/dist/libpthread-stubs-0.3.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libpthread-stubs


code:
[vars]
filesize=1366794
sha512=b0c8753a7cd6448f3353ffd3755c159b6b0b777d7b2c0e803b04d1081e50d76083aac80218764fa9f313dc49abf4be00c8eba0b25dd89b87a38ce9085bac695f

[mirrors]
http://pkgs.fedoraproject.org/repo/pkgs/LibRaw/LibRaw-0.14.7.tar.gz/8b622d82c927d8975c22ee4316584ebd/LibRaw-0.14.7.tar.gz

[deps]
lcms2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CFLAGS="-D_GNU_SOURCE $optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libraw


code:
[mirrors]
http://download.rsyslog.com/librelp/librelp-1.2.10.tar.gz

[vars]
filesize=415653
sha512=09f88daa59711449a50b9414f30bc7a217bf3dd7722af53caee024bfe1060e1749f1083d2965c79cbe3c12819359cd3cc262e9dea8ab5ad7bf275f3b61ca907f

[deps]
gnutls

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/librelp


code:
[mirrors]
http://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.2.7.tar.gz
http://ftp.ch.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.2.7.tar.gz

[vars]
filesize=2958862
sha512=562394e84903c5b121da21cb3f45744df80b06d8717efc5567a6f663d1dcb8dd2bf505db7ab78ea83c9223a62c1bc541bf6c905720d73410bff352a63f5f8fc1
desc="tls and crypto library. replaces openssl"

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags --disable-hardening

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libressl


code:
[mirrors]
http://ftp.acc.umu.se/pub/GNOME/sources/librsvg/2.40/librsvg-2.40.15.tar.xz

[vars]
filesize=554608
sha512=1169c02247dbf3d71d3d4bfb1aa2580a4b1e243e1c2c6d1c86aaa09c54c66857b959df4358a1ca6a34ec5fbb34b9529963b993fc978ec1fe401dbc56ac460101

[deps]
gdk-pixbuf
libxml2
pango
cairo
fontconfig
freetype
gtk+2
libcroco

[build]
cp -f "$K"/config.sub .
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="-D_GNU_SOURCE $optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-silent-rules \
  --disable-introspection \
  --disable-tools \
  --disable-gtk-doc-html

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make -j$MAKE_THREADS
make V=1 DESTDIR="$butch_install_dir" install

path: pkg/librsvg


code:
[mirrors]
http://www.mega-nerd.com/SRC//libsamplerate-0.1.8.tar.gz

[vars]
filesize=4303330
sha512=85d93df24d9d62e7803a5d0ac5d268b2085214adcb160e32fac316b12ee8a0ce36ccfb433a3c0a08f6e3ec418a5962bdb84f8a11262286a9b347436983029a7d

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-sndfile
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libsamplerate


code:
[mirrors]
http://ftp.gnome.org/pub/GNOME/sources/libsigc++/2.3/libsigc++-2.3.1.tar.xz

[vars]
filesize=3458088
sha512=8c9aa63c56e978ec3e38fda9919ffbba173b97342d0e19d0ae3126e9edb97aa1d42e79897a65b054044e87604f67f1f804db8d7a8e3dc68540b1441188b8a1ef

[deps.host]
pkgconf
m4

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CPPFLAGS=-D_GNU_SOURCE \
CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
--disable-silent-rules\
--disable-documentation \

for i in tests docs examples ; do
	printf 'all:\n\ttrue\ninstall:\n\ttrue\clean:\n\ttrue\n' > "$i"/Makefile
done

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libsigc++


code:
[deps]
libice

[vars]
filesize=348908
sha512=dfb91dcc7200fce8d0a62953ae4b81fcb00d525674bbcc6dfcaa23ecb35e1213ceb07cc51f590072dce2107909903160d9f3636a0434fe2a605b1e9a9bd0a6ca

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libSM-1.2.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --without-libuuid
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libsm


code:
[mirrors]
http://www.mega-nerd.com/libsndfile/files/libsndfile-1.0.25.tar.gz
[vars]
filesize=1060692
sha512=4ca9780ed0a915aca8a10ef91bf4bf48b05ecb85285c2c3fe7eef1d46d3e0747e61416b6bddbef369bd69adf4b796ff5f61380e0bc998906b170a93341ba6f78

[deps]
libflac
libogg
libvorbis

[build]
printf "all:\n\ttrue\n\ngenfiles:\n\ttrue\n\ninstall:\n\ttrue\n\n" > tests/Makefile.in
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > regtest/Makefile.in
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > examples/Makefile.in
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make -j$MAKE_THREADS
make V=1 DESTDIR="$butch_install_dir" install

path: pkg/libsndfile


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libsoup/2.44/libsoup-2.44.1.tar.xz

[vars]
filesize=746716
sha512=07120996737d86f45acb80b05147e9af0e3e183bec9a97727881b8dc05cb154c679a785f4d5a3a53d0e3611ae0198df977bc9059623c9f1e8e01a03d4c7acb95

[deps]
libxml2
sqlite
gnutls
intltool
glib-networking

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libsoup


code:
[vars]
filesize=314429
sha512=9142896f02801c78748bc1107b9b547506d61bda737b945bd691ebf10cc6c20511ea896b9c22893a36b97a52b2d5e5c4dd35a7501fca6a65f5b33879a0c0ae37

[mirrors]
http://www.libssh.org/files/0.5/libssh-0.5.0.tar.gz

[build]
cp $K/libssh-Makefile ./Makefile
cp $K/libssh-config.mak ./config.mak
touch include/libssh/config.h
touch include/config.h
#patch -p1 < "$K"/libssh.patch
#do a echo hack until busybox fixed its patch program
echo -ne "#include <fcntl.h>\n" > /tmp/libssh.h
cat include/libssh/libssh.h >> /tmp/libssh.h
cp /tmp/libssh.h include/libssh/libssh.h
CFLAGS="-Os -s -D_GNU_SOURCE -I./include -std=gnu99 -Wall -Wextra" make src
make DESTDIR="$butch_install_dir" install

path: pkg/libssh


code:
[mirrors]
http://www.freedesktop.org/software/startup-notification/releases/startup-notification-0.12.tar.gz
http://downloads.yoctoproject.org/mirror/sources/startup-notification-0.12.tar.gz

[vars]
filesize=355285
sha512=ea1246acdb50dafd9ced9914ec3c8f0d499c0ca3cfd447b43a444c768a6e9ea7135e5c42d9ca0089354698ac235bd86d42f12c70a3a17c9c79f998c07461f7ab

[deps]
libxcb
xcb-util
libx11

[build]
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > test/Makefile.in
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  lf_cv_sane_realloc=yes
patch -p1 < "$K"/libtool-sysroot.patch
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libstartup-notification


code:
[deps]
gcc4

path: pkg/libstdc++


code:
[mirrors]
http://ftp.gnu.org/gnu/libtasn1/libtasn1-4.8.tar.gz

[vars]
filesize=1859924
sha512=22a0d1b2fc57efd18aa23ea720f915ec0c31bd2f60653181b0537d3d7c3c3262cef3a76e3be03fdb7d7cd5a6b4156a1033b156e56717bfa37a32f176692319f3

[deps]

[build]
#patch -p1 < "$K"/some.patch

[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install


code:
[mirrors]
http://heanet.dl.sourceforge.net/project/tdb/tdb/1.0.6/tdb-1.0.6.tar.gz
http://surfnet.dl.sourceforge.net/project/tdb/tdb/1.0.6/tdb-1.0.6.tar.gz
http://switch.dl.sourceforge.net/project/tdb/tdb/1.0.6/tdb-1.0.6.tar.gz

[vars]
filesize=139948
sha512=8b293bca847a49da416f0b84056846f63703ae96a34cc890673befcc015424bba0781e8d4059868182c24b191e5038314f2e4c66cb1b5f6c28eead1fa5e4ecaf

[deps]
gdbm

[build]
patch -p1 < "$K"/tdb-help.patch

# this package is 12 years old and doesnt recognise x86_64
# there is a recent fork of fedora / redhat, but it is 4 times as big
# and of course uses some glibc specific crap (strtouq)
cp -f "$K"/config.sub .

[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
CPPFLAGS=-D_GNU_SOURCE \
  ./configure --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libtdb


code:
[mirrors]
http://downloads.xiph.org/releases/theora/libtheora-1.1.1.tar.bz2

[vars]
filesize=1903175
sha512=9ab9b3af1c35d16a7d6d84f61f59ef3180132e30c27bdd7c0fa2683e0d00e2c791accbc7fd2c90718cc947d8bd10ee4a5940fb55f90f1fd7b0ed30583a47dbbd

[deps]
libogg
libvorbis

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-sdltest \
  --disable-examples
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libtheora


code:
[mirrors]
http://download.osgeo.org/libtiff/tiff-4.0.6.tar.gz

[vars]
filesize=2192991
sha512=2c8dbaaaab9f82a7722bfe8cb6fcfcf67472beb692f1b7dafaf322759e7016dad1bc58457c0f03db50aa5bd088fef2b37358fcbc1524e20e9e14a9620373fdf8

[deps]
libjpeg
libstdc++
zlib
xz

[build]
cp -f "$K"/config.sub config/
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
   ./configure -C --prefix="$butch_prefix" --with-pic \
     --enable-shared --enable-static $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libtiff


code:
[mirrors]
https://github.com/mfontanini/libtins/archive/v3.2.tar.gz

[vars]
filesize=276926
sha512=d126491c31c4f98766bdec678e2776ae264b633bc1ad811f4dd3362324bf2607f9f3d724a2a519ac9233ffca38eb2e6e855d0df7a701fd825f2822ed8309c60c
tarball=libtins-3.2.tar.gz
tardir=libtins-3.2

[deps]
libpcap
libressl
libstdc++

[deps.host]
cmake

[build]
mkdir -p build && cd build
for i in ar ld nm objcopy objdump strip ; do
printf '#!/bin/sh\n%s%s "$@"\n' "$CROSS_COMPILE" "$i" > "$CROSS_COMPILE""$i"
chmod +x "$CROSS_COMPILE""$i"
done
[ -n "$CROSS_COMPILE" ] && xconfflags="
-DCMAKE_FIND_ROOT_PATH=$butch_root_dir$butch_prefix \
-DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER \
-DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY \
-DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY \
-DCMAKE_AR="$CROSS_COMPILE"ar \
-DCMAKE_LD="$CROSS_COMPILE"ld \
-DCMAKE_NM="$CROSS_COMPILE"nm \
-DCMAKE_OBJCOPY="$CROSS_COMPILE"objcopy \
-DCMAKE_OBJDUMP="$CROSS_COMPILE"objdump \
-DCMAKE_STRIP="$CROSS_COMPILE"strip \
"

CFLAGS="-D_GNU_SOURCE $optcflags" \
LDFLAGS="$optldflags  -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
CXXFLAGS="$optcflags" \
cmake $xconfflags \
  -DCMAKE_INSTALL_PREFIX="$butch_prefix" \
  -DCMAKE_VERBOSE_MAKEFILE=ON \
  ..
make -j$MAKE_THREADS VERBOSE=1
make DESTDIR="$butch_install_dir" install

path: pkg/libtins


code:
[vars]
filesize=1770684
sha512=88ae8ba640f1d7b5237fc39e1f6b24c9502ac310001636cd4e6626061ba77fec5ea6303ce5f47056a5feb86713bdde59039293534880d223b17c382bf34465f9

[mirrors]
http://ftpmirror.gnu.org/libtool/libtool-2.4.4.tar.gz

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"
CPPFLAGS=-D_GNU_SOURCE CFLAGS="$optcflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libtool


code:
[mirrors]
http://rtorrent.net/downloads/libtorrent-0.13.6.tar.gz

[vars]
filesize=781253
sha512=b8aea4060357a8a40d15d42f1f698ef6f3ebdc885000bfbfa5bf9c81af8c88b5503a107e05c214e3e8489126928d336356c5e7e0eaf836b6b84a3cf74633b050

[deps.host]
dynamic-toolchain

[deps]
libsigc++
libstdc++
curl
zlib

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

align=yes
[ "$A" = x86_64 ] && align=no
case "$A" in i[3-6]86) align=no ;; esac

sed -i 's@-Wl,-syslibroot,@-Wl,-syslibroot=@' configure
# remove execinfo.h test which breaks xcompile
sed -i '18271,18305d' configure >/dev/null
CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
./configure -C --prefix="$butch_prefix" $xconfflags \
  --enable-aligned=$align --without-kqueue \
  --with-zlib="$butch_root_dir$butch_prefix" \
  --disable-instrumentation
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libtorrent


code:
[mirrors]
http://downloads.sourceforge.net/project/libusb/libusb-1.0/libusb-1.0.20/libusb-1.0.20.tar.bz2

[vars]
filesize=795247
sha512=4230047dbc18db402f399a6b228f70da37ce4f9da9d57203e5c31cf0edec5ddd664865b4f16038a2ae72c26097e713b709b9e882a11b65a274e84993d617c765
desc="OS independent USB device access"

[deps]
eudev

[build]
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
CPPFLAGS="-D_POSIX_SOURCE -D_BSD_SOURCE -DTIMESPEC_TO_TIMEVAL=" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-build-docs
make -j$MAKE_THREADS
make V=1 DESTDIR="$butch_install_dir" install

path: pkg/libusb


code:
[mirrors]
http://downloads.sourceforge.net/project/libusb/libusb-compat-0.1/libusb-compat-0.1.5/libusb-compat-0.1.5.tar.bz2

[vars]
filesize=276769
sha512=fe63bd1c65e67588a83ebfdd329025ecf75f33f877fb80dd83eb528df057efb591e010416027f9054294504562299166e8e2811a7681fa1967a03baae9b88857

[deps]
libusb

[build]
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
CPPFLAGS="-D_POSIX_SOURCE -D_BSD_SOURCE -DTIMESPEC_TO_TIMEVAL=" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  --disable-build-docs
make -j$MAKE_THREADS
make V=1 DESTDIR="$butch_install_dir" install

path: pkg/libusb-compat


code:
[vars]
filesize=432611
sha512=a03eafe1a102a6dd532bbe758878bd92548ed367c39909c6e8fde205c145b9581405011379fa5e031df53e208feb54d9f4886039fab6e261c8ca27ceec69b45d

[mirrors]
http://downloads.sourceforge.net/project/libusbx/releases/1.0.14/source/libusbx-1.0.14.tar.bz2
http://heanet.dl.sourceforge.net/project/libusbx/releases/1.0.14/source/libusbx-1.0.14.tar.bz2
http://surfnet.dl.sourceforge.net/project/libusbx/releases/1.0.14/source/libusbx-1.0.14.tar.bz2

[deps.host]
dynamic-toolchain

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
CPPFLAGS="-D_POSIX_SOURCE -D_BSD_SOURCE -DTIMESPEC_TO_TIMEVAL=" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make V=1 DESTDIR="$butch_install_dir" install

path: pkg/libusbx


code:
[deps]
e2fsprogs

path: pkg/libuuid


code:
[mirrors]
http://libvirt.org/sources/libvirt-1.1.3.tar.gz

[vars]
filesize=26578000
sha512=895f8ccf1fdf7a36918e4d460b44b1bf67d06842e39142c89c620f6191e299b53c50f80ab47677d7cba6bd570177d79b5ee0d7d2a11472991590389db51fab9d

[deps]
libyajl
portablexdr
libxml2

[build]
patch -p1 < "$K"/libvirt-symbol-versioning.patch
patch -p1 < "$K"/libvirt-debug-python.patch

[ -z "$butch_prefix" ] && butch_prefix=/

#sed -i 's#VERSION_SCRIPT_FLAGS = @VERSION_SCRIPT_FLAGS@#VERSION_SCRIPT_FLAGS = #' src/Makefile.in
#sed -i 's#LIBVIRT_SYMBOL_FILE = @LIBVIRT_SYMBOL_FILE@#LIBVIRT_SYMBOL_FILE = #' src/Makefile.in

CFLAGS="-D_GNU_SOURCE $optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" \
  gl_cv_func_working_mktime=yes \
  --without-macvtap \
  --without-firewalld \
  --with-sysctl=no \
  --with-init-script=none \

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libvirt


code:
[mirrors]
http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.5.tar.xz

[vars]
filesize=1193144
sha512=f18f32edc43f65fea2dd4133e2828a0ced9e5b0797c4569bd26989fc1409ad599359e7c796bffc082ad36189f9722c7b38837384cea66d217beac8b425299ef8

[deps]
libogg
gcc4

[build]
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > test/Makefile.in
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
# libvorbis wants emmintrin.h and similar stuff, which is in /include/gcc
CPPLAGS="-D_GNU_SOURCE -I$butch_root_dir$butch_prefix/include/gcc" \
CFLAGS="$optcflags" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libvorbis


code:
[mirrors]
http://www.geocities.jp/aoyoume/aotuv/source_code/libvorbis-aotuv_b6.03_2015.tar.bz2

[vars]
filesize=1398388
sha512=f87e494aad030e1e91a2a49b64c24384af7c5a3e768432859c5b72c4e2b0564fcea3d0787eed61278a99e9624dcc49cfec589d9446bfaec3b88c22040a820a05
tardir=aotuv-b6.03_20110424-20150808

[deps]
libogg

[build]
chmod +x ./configure
chmod +x ./install-sh
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libvorbis-aotuv


code:
[mirrors]
http://storage.googleapis.com/downloads.webmproject.org/releases/webm/libvpx-1.5.0.tar.bz2

[vars]
filesize=1906571
sha512=5a952aa53e539a130d316723d424fa02a8f42a450950d74a16d8abc5df569ba5559b3b09a32140b638d7a0cd54be1c7b0f8306ad286825bc1281f513bb665fc5
uchkurl=http://downloads.webmproject.org/releases/webm/index.html

[deps.host]
yasm

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--target=generic-gnu"
[ -z "$butch_prefix" ] && butch_prefix=///

sed -e 's/cp -p/cp/' -i build/make/Makefile &&
chmod -v 644 vpx/*.h

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure --prefix="$butch_prefix" --enable-shared $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS STRIP="$CROSS_COMPILE"strip AR="$CROSS_COMPILE"ar \
     LD="$CROSS_COMPILE"g++
make DESTDIR="$butch_install_dir" install

path: pkg/libvpx


code:
[vars]
filesize=990904
sha512=4975c055e94668cc3b8198443d141de91db6c9d99a79164631854b9b91eea2d9d92aefa361cb8e0fa8963a3deeb5ba6cc6ab55db1d7b038ae495b7e7cf5b2572

[mirrors]
http://downloads.webmproject.org/releases/webp/libwebp-0.4.3.tar.gz

[deps]
libjpeg
libpng
libtiff
freeglut
giflib

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libwebp


code:
[mirrors]
http://ftp.gnome.org/pub/gnome/sources/libwnck/2.18/libwnck-2.18.3.tar.bz2

[vars]
filesize=482211
sha512=9ad6cd029137ed740d118c167d72cc063482889c43491856767a1d1046ab3096f8ac12d21f1610b3afcd9c44ed139b1f167c452cef1ba2c88682982f75c44e8f

[deps]
libstartup-notification
libxt
gtk+2

[deps.host]
perl5-XML-Parser

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags -D_GNU_SOURCE" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" $xconfflags

[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

for i in po ; do
	printf 'all:\n\ttrue\ninstall:\n\ttrue\clean:\n\ttrue\n' > "$i"/Makefile
done

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libwnck


code:
[deps]
util-macros
libxcb
xproto
xextproto
xtrans
kbproto
inputproto
xf86bigfontproto

[vars]
filesize=2339981
sha512=c8609ff34d1fe71f35b35e0273a872ccded4d824c8afdcca37e1779d37bf667cb814e0ead0805668b4222f196148476f283e417ba371b722f1fe716a5bbba20b

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libX11-1.6.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" \
  --disable-loadable-xcursor $xconfflags
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install


code:
[deps.host]
pkgconf

[deps]
xproto

[vars]
filesize=295297
sha512=9f933d22f8f2411ae770094589cbe170c631a1437d572664e0fa6b9608e6ec39deef752f2dd6408ab45acdf01bf1827ef3ced640a33da787d9cfb546f12397b5

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXau-1.0.8.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && xconfflags="--host=$($CC -dumpmachine)"
./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxau


code:
[deps]
libxext
libxmu
libxpm

[vars]
filesize=677147
sha512=baf11625a20b89f08747e25dff6755ab796c8a5a91341d3cb21f85780733c4a3c25bbf134ac6259982207067d0a617f83f516c48aef6f57cbab14c8a9862944d

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXaw-1.0.12.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxaw


code:
[deps]
xcb-proto
libpthread-stubs
libxau
libxslt

[deps.host]
python

[mirrors]
http://xcb.freedesktop.org/dist/libxcb-1.10.tar.bz2

[vars]
filesize=475211
sha512=c29ab5027498635d58fd7bfcd77899a406116b25fa8c4ec6513fc1395d8a0f99f602ad20b507660a62000b6fc879860d182cafd29af590e8b14f55150a064f7a

[build]
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > tests/Makefile.in
if [ -n "$CROSS_COMPILE" ] ; then
	xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
	export PYTHONHOME="$butch_root_dir$butch_prefix"
fi
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" \
  --disable-build-docs $xconfflags

patch_status() {
	kv=$(printf 'S["%s"]="%s"\n' "$1" "$2")
	sed -i 's,^S.*'$1'.*=.*$,'"$kv"',' config.status
}

if [ -n "$CROSS_COMPILE" ] ; then
patch_status XCBPROTO_XCBINCLUDEDIR "$butch_root_dir""$butch_prefix"/share/xcb
patch_status XCBPROTO_XCBPYTHONDIR "$butch_root_dir""$butch_prefix"/lib/python2.7/site-packages
sh config.status
fi

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libxcb


code:
[deps]
compositeproto
xproto
libx11
libxfixes

[vars]
filesize=283746
sha512=b15f8fdbe4cb7488bdad161d73ef8e59ef603c5af92d7b573110ba136d7d4ce3749aac45972bce87662b0310b67e831cffad72c45c15bfff988b5b555d4c884b

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXcomposite-0.4.4.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxcomposite


code:
[deps]
xproto
libx11
libxrender
libxfixes

[vars]
filesize=311896
sha512=687963b54da66be25371f64a88f91812b38de4ffc3b806070f3aeb1da379df16ede819201a352b3fb66efc6b40a36a22770add3ae464f2008aff3e23cb60a8e6

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXcursor-1.1.14.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxcursor


code:
[mirrors]
http://xorg.freedesktop.org/archive/individual/lib/libXdamage-1.1.4.tar.gz

[vars]
filesize=339060
sha512=903cb9c40108b85c29da9343d54e76f73eaa393f5521ed5daea9ad98ee9bc64aecee818f4461fe41b347d77ea90140f2e9f1bfbf7b4b101b6b2b993ec2183923

[deps]
damageproto
libxfixes

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libxdamage


code:
[mirrors]
https://github.com/devnev/libxdg-basedir/archive/libxdg-basedir-1.2.0.tar.gz

[vars]
filesize=30159
sha512=8584405d45e0b57e570666b6eab6d99d70411d00f88965826c9ed0292372385668f190157a10ff536f3a5a59fd0031b332ecbb8a38ac64eda1b04a0603997406

[deps]

[build]
# cd fails in butch
cd libxdg-basedir-libxdg-basedir-1.2.0

# add overflow patch, as found in the arch PKGBUILD:
# https://projects.archlinux.org/svntogit/community.git/tree/trunk/PKGBUILD?h=packages/libxdg-basedir
patch -Np0 -i "$K"/libxdg-basedir.patch

./autogen.sh --prefix=/
make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libxdg-basedir


code:
[deps.host]
pkgconf

[deps]
xproto

[vars]
filesize=310878
sha512=b17ad4bf01443cb78b440a33a89f2b98babf02402d7bdf68161a08429fd1964ac8112b0bb1519dd2138db0a5ff295c7b7581f56ff602ccca1a9baac26bc62e08

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXdmcp-1.1.1.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxdmcp


code:
[deps]
xproto
libx11
xextproto

[vars]
filesize=378901
sha512=5ed612f2c5e902648eb0438bfb8d9d6440a5baa19d95eb1253b51fe9ad8dcf903a7ee68a9455044d17ce0d486e421df0f98a069ab5ad1a49364f157bdf64efe7

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXext-1.3.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxext


code:
[deps]
libx11
fixesproto

[vars]
filesize=291978
sha512=b47c841db169d1b329eec9deb555799cd087a466326840f1f5349303ba79cff5850b1bb69c1ff38b3f522f24d61db58a0c01021e1ffea2896527167262fc7150

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXfixes-5.0.1.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" \
LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxfixes


code:
[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXfont-1.5.1.tar.bz2

[vars]
filesize=502903
sha512=3ca8f7c1c642072c9bf9a755b45857f77753111ce6f1f99bd804e0f1b90cf61259fbde609a5342cce9c1ac5431b093bf75febb68baff2f2688e0a5fe5864a666

[deps]
util-macros
freetype
libfontenc
xproto
fontsproto
xtrans

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
LDFLAGS="$optldflags" \
CFLAGS="$optcflags -D_GNU_SOURCE -DNOFILES_MAX=256 -Dfd_mask=long" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxfont


code:
[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXft-2.3.2.tar.bz2

[vars]
filesize=335495
sha512=eb2e0c46b4434198690a3ca2b613df14ad599c860b47d10a1e8efe3b4e812a78460f9f414eaf89db21d605613a4e18324dcb8a22928609c6bc15178330a05398

[deps]
fontconfig
libxrender

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"

CFLAGS="$optcflags" LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libxft


code:
[deps]
libxext
inputproto
libxfixes

[vars]
filesize=440969
sha512=f419a30711220f51bc77ba4cd2759e565d4f8ba9960c3bcce3ec80ab84389fe220e4276887b125ec105810bd219698fb3a22ec4b9d91eab7235ed9a3ca6925c3

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXi-1.7.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxi


code:
[vars]
filesize=278026
sha512=c9f059697c04fdc600d9e63873e924032d6cff456674ee28a885270c54722d96df0ef7a78432c2bdc0844241f115e00ad730c29d84681efc1c45a2e1acb3288c

[mirrors]
http://xorg.freedesktop.org//releases/individual/lib/libXinerama-1.1.3.tar.bz2

[deps]
libxext
xineramaproto

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" \
LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libxinerama


code:
[deps]
libx11

[vars]
filesize=335788
sha512=1d8766db2a15fe0a1f3775d38422eabd572ec8ba8417cde9f1ec95b0065e1acb6036fcf9a8e54f2e0517b358f9f3fe6f8b419554ec7688c24ec4072939c5e099

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libxkbfile-1.0.8.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
patch -p1 < "$K"/libtool-sysroot.patch
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxkbfile


code:
[mirrors]
http://xmlsoft.org/sources/libxml2-2.9.3.tar.gz
ftp://xmlsoft.org/libxml2/libxml2-2.9.3.tar.gz
ftp://gd.tuwien.ac.at/pub/libxml/libxml2-2.9.3.tar.gz

[vars]
filesize=5477112
sha512=078afa65229de4f23e6538767253fb4f9f61d96cb72e445179c71d536b224d54922f22972a2b71434796f83f8c99f6a46c3b8813cb4582ad9fca696d141e0abb
desc="bloated and buggy XML parsing library with a history of security vulns"

[deps]
zlib
xz

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="-D_GNU_SOURCE -fPIC $optcflags" \
LDFLAGS="$optldflags" \
./configure -C \
  --prefix="$butch_prefix" --enable-shared --without-iconv \
  --without-iso8859x --without-legacy --without-python \
  --disable-silent-rules $xconfflags

patch_status() {
	kv=$(printf 'S["%s"]="%s"\n' "$1" "$2")
	sed -i 's,^S.*'$1'.*=.*$,'"$kv"',' config.status
}

if [ -n "$CROSS_COMPILE" ] ; then
patch_status PYTHON_SITE_PACKAGES "$butch_root_dir""$butch_prefix"/lib/python2.7/site-packages
patch_status PYTHON_INCLUDES "$butch_root_dir""$butch_prefix"/include/python2.7
patch_status PYTHON_VERSION 2.7
patch_status PYTHON_LIBS "-L$butch_root_dir$butch_prefix/lib/python2.7/config -lpython2.7 -Xlinker -export-dynamic"
sh config.status
fi

make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

sed -i 's@-lxml2@-lxml2 -lz -llzma@' "$butch_install_dir""$butch_prefix"/lib/pkgconfig/libxml-2.0.pc


code:
[vars]
filesize=626624
sha512=12f2cdcd66ab3f26848395c58c52f7ac887ecd749ed7a54353d217f597f6d9ee844aa95ebf2b21f8b39c5793bca66d0317035f9b91848bda11a60f3a2e542c40

[mirrors]
http://downloads.sourceforge.net/project/xmp/libxmp/4.3.9/libxmp-4.3.9.tar.gz

[deps]

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/') \
  --with-sysroot=$butch_root_dir"

CPPFLAGS="-D_GNU_SOURCE" CFLAGS="$optcflags" CXXFLAGS="$optcflags" \
LDFLAGS="$optldflags -Wl,-rpath-link=$butch_root_dir$butch_prefix/lib" \
  ./configure -C --prefix="$butch_prefix" --disable-nls $xconfflags

#[ -n "$CROSS_COMPILE" ] && "$K"/libtool.cross.gen --sysroot="$butch_root_dir"

make V=1 -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install

path: pkg/libxmp


code:
[deps]
libxext
libxt

[vars]
filesize=396230
sha512=eba4e3d10f7d75ba8464881fb69f295a89774a4b37793197d75f3312e3a342b2df8b7e13e3f5c887962704329b5347ff2f3395e229af9dadf46a93b1e8613cfc

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXmu-1.1.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxmu


code:
[deps]
libx11
libxt

[vars]
filesize=443496
sha512=c089056108d4598f6c4603d6440d9ef6216e87c5cf1e30d143b0e7abc9c5d6f40050c747a57a27d751bc80786ded0390d97cbe221be628241c881d21a3ce6024

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXpm-3.5.11.tar.bz2

[build]
sed -i 's/USE_GETTEXT="yes"/USE_GETTEXT="no"/' configure
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags -D_GNU_SOURCE -D_BSD_SOURCE" \
LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxpm


code:
[deps]
xproto
libx11
libxrender
randrproto
libxrender
libxext

[vars]
filesize=315165
sha512=59e728a4cf726e3bbf248cc76a45d78cf873ca8eee23b19a4b373accae634f4d12ebd79100d3e84416c3ef515396bbe3a0a204bc49c1748d265046ffa6bfffef

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXrandr-1.4.2.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" \
LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxrandr


code:
[deps]
renderproto
libx11

[vars]
filesize=306121
sha512=111a0ec4e19932a50da4914d9112b0a16c1d9c800e2b8398ddaf9ed70dae1a4eb75860282ca62d023e78957bbc3f015cb80d91ba76a24595df9f8a2b7e055b58

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXrender-0.9.8.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxrender


code:
[deps]
resourceproto
xproto
libx11

[vars]
filesize=282925
sha512=796a79ab694317910442cb10a936711df9dde95764eef11efb8dedc85114977e56409de2f640553f1ad492325df178b8cfbeaeec3f03bf084638c555e44292e0

[mirrors]
http://xorg.freedesktop.org/releases/individual/lib/libXres-1.0.7.tar.bz2

[build]
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine) --with-sysroot=$butch_root_dir"
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" $xconfflags \
  ac_cv_func__XEatDataWords=yes
make V=1 DESTDIR="$butch_install_dir" -j$MAKE_THREADS install

path: pkg/libxres