Skip to content
Snippets Groups Projects
Commit b8036c72 authored by Anders Blomdell's avatar Anders Blomdell
Browse files

Put each binary in a separate package

parent 8c4d574f
Branches
No related tags found
No related merge requests found
......@@ -80,6 +80,17 @@ EOF
cat<<EOF
BuildRequires: gcc
EOF
# Iterate over all needed combinations
(grep '^##' $0 | sed -re 's/[ \t]+/ /g' | cut -d' ' -f2-4 | sort -u) \
| while read -r platform unison ocaml ; do
cat<<EOF
Requires: %{name}-${unison}-${ocaml}
EOF
done
cat<<EOF
%description
Unison is a multi-master file-synchronization tool. It allows two
......@@ -96,6 +107,19 @@ EOF
| while read -r platform unison ocaml ; do
echo " unison-text-${unison}-${ocaml} (${platform})"
done
# Iterate over all needed combinations
(grep '^##' $0 | sed -re 's/[ \t]+/ /g' | cut -d' ' -f2-4 | sort -u) \
| while read -r platform unison ocaml ; do
cat<<EOF
%package -n %{name}-${unison}-${ocaml}
Summary: unison-text-${unison}-${ocaml} (${platform})
%description -n %{name}-${unison}-${ocaml}
unison-text-${unison}-${ocaml} (${platform})
EOF
done
cat <<EOF
%prep
......@@ -121,11 +145,18 @@ INSTALLDIR=. ./$(basename $0) --install-unison
mkdir -p %{buildroot}%{_bindir}
cp -p bin/* %{buildroot}%{_bindir}
%files
EOF
# Iterate over all needed combinations
(grep '^##' $0 | sed -re 's/[ \t]+/ /g' | cut -d' ' -f2-4 | sort -u) \
| while read -r platform unison ocaml ; do
cat<<EOF
%files -n %{name}-${unison}-${ocaml}
%defattr(-,root,root)
%{_bindir}/*
%{_bindir}/unison-text-${unison}-${ocaml}
EOF
done
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment