# HG changeset patch
# User Aleksej Bobylev <al.bobylev@gmail.com>
# Date 1524188643 -10800
# Node ID 75d3dd3c761f4882035caba8df540ef2859efd55
# Parent  b96375904f8e8bb64272f6e926e9caa53523a4fe
glusterfs: fix build

diff -r b96375904f8e -r 75d3dd3c761f glusterfs/receipt
--- a/glusterfs/receipt	Thu Apr 19 23:07:29 2018 +0300
+++ b/glusterfs/receipt	Fri Apr 20 04:44:03 2018 +0300
@@ -12,19 +12,33 @@
 WGET_URL="https://download.gluster.org/pub/gluster/glusterfs/${VERSION%.*}/$VERSION/$TARBALL"
 
 BUILD_DEPENDS="flex python-dev readline-dev mpc-library elfutils openssl-dev \
-acl-dev sqlite-dev liburcu-dev libxml2-dev"
+acl-dev sqlite3-dev liburcu-dev libxml2-dev rpcsvc-proto libtirpc-dev"
+SPLIT="glusterfs-dev"
 
 compile_rules() {
 	sed -i "/^cat/,/^EOM/d;s/exit/echo '$HOST_SYSTEM'\n&/" config.sub
+	export CPPFLAGS="$CPPFLAGS -I/usr/include/tirpc/"
+	export LDFLAGS="$LDFLAGS -ltirpc"
 
 	./configure \
 		--libexecdir=/usr/share \
 		$CONFIGURE_ARGS &&
+	sed -i 's| -lfl | |' $src/libglusterfs/src/Makefile &&
+	fix libtool &&
 	make &&
-	make  install
+	make install
 }
 
 genpkg_rules() {
-	copy @std
-	DEPENDS="python readline mpc-library elfutils openssl"
+	case $PACKAGE in
+		glusterfs)
+			copy @std
+			DEPENDS="acl libsqlite3 libtirpc liburcu libxml2 openssl python \
+			readline zlib"
+			;;
+		*-dev)
+			copy @dev
+			DEPENDS="glusterfs acl-dev sqlite3-dev"
+			;;
+	esac
 }