summaryrefslogtreecommitdiff
path: root/control.sh
diff options
context:
space:
mode:
authorJay Freeman <saurik@saurik.com>2009-08-09 02:50:34 +0000
committerJay Freeman <saurik@saurik.com>2009-08-09 02:50:34 +0000
commit1fc212398c58ef27963f84fa69df552acacf7767 (patch)
tree34b4e1e2507af390799e3c606d094760a383fa4a /control.sh
parent35d894811b58293feab572d52024530411fd9728 (diff)
jlanger failed to build my zsh.
git-svn-id: http://svn.telesphoreo.org/trunk@647 514c082c-b64e-11dc-b46d-3d985efe055d
Diffstat (limited to 'control.sh')
-rwxr-xr-xcontrol.sh86
1 files changed, 63 insertions, 23 deletions
diff --git a/control.sh b/control.sh
index 8a1f2c7ff..e82c45308 100755
--- a/control.sh
+++ b/control.sh
@@ -15,7 +15,7 @@ cat <<EOF
Package: ${PKG_NAME}
EOF
-if [[ ${PKG_PRIO} == required || ${PKG_PRIO} == +* ]]; then
+if [[ ${PKG_PRIO} == +* ]]; then
cat <<EOF
Essential: yes
EOF
@@ -61,36 +61,76 @@ Size: $(find "${PKG_DEST}" -type f -exec cat {} \; | gzip -c | wc -c | cut -d $'
EOF
fi
-unset comma
-for dep in "${PKG_DEPS[@]}"; do
- if [[ ${comma+@} == @ ]]; then
- echo -n ","
- else
- echo -n "Depends:"
- comma=
+if [[ -e ${PKG_DATA}/_metadata/predepends_ ]]; then
+ echo "Pre-Depends: $(cat "${PKG_DATA}/_metadata/predepends_")"
+else
+ unset comma
+
+ if [[ ${PKG_ZLIB} == lzma ]]; then
+ if [[ ${comma+@} == @ ]]; then
+ echo -n ","
+ else
+ echo -n "Pre-Depends:"
+ comma=
+ fi
+
+ echo -n " dpkg (>= 1.14.25-8)"
fi
- echo -n " $(basename "${dep}" .dep)"
-
- ver=${PKG_DATA}/_metadata/${dep%.dep}.ver.${PKG_ARCH}
- if [[ -e "${ver}" ]]; then
- echo -n " (>= $(cat "${ver}"))"
+ if [[ -e ${PKG_DATA}/_metadata/predepends ]]; then
+ if [[ ${comma+@} == @ ]]; then
+ echo -n ","
+ else
+ echo -n "Pre-Depends:"
+ comma=
+ fi
+
+ echo -n " $(cat "${PKG_DATA}/_metadata/predepends")"
fi
-done
-if [[ -e ${PKG_DATA}/_metadata/depends ]]; then
if [[ ${comma+@} == @ ]]; then
- echo -n ","
- else
- echo -n "Depends:"
- comma=
+ echo
fi
-
- echo -n " $(cat "${PKG_DATA}/_metadata/depends")"
fi
-if [[ ${comma+@} == @ ]]; then
- echo
+if [[ ! -e ${PKG_DATA}/_metadata/depends_ ]]; then
+ unset comma
+ for dep in "${PKG_DEPS[@]}"; do
+ if [[ ${dep} == _* ]]; then
+ continue
+ fi
+
+ if [[ ${comma+@} == @ ]]; then
+ echo -n ","
+ else
+ echo -n "Depends:"
+ comma=
+ fi
+
+ echo -n " $(basename "${dep}" .dep)"
+
+ ver=${PKG_DATA}/_metadata/${dep%.dep}.ver.${PKG_ARCH}
+ if [[ -e "${ver}" ]]; then
+ echo -n " (>= $(cat "${ver}"))"
+ fi
+ done
+
+ if [[ -e ${PKG_DATA}/_metadata/depends ]]; then
+ if [[ ${comma+@} == @ ]]; then
+ echo -n ","
+ else
+ echo -n "Depends:"
+ comma=
+ fi
+
+ echo -n " $(cat "${PKG_DATA}/_metadata/depends")"
+ fi
+
+ if [[ ${comma+@} == @ ]]; then
+ echo
+ fi
+elif [[ -s ${PKG_DATA}/_metadata/depends_ ]]; then
+ echo "Depends: $(cat "${PKG_DATA}/_metadata/depends_")"
fi
if [[ -e ${PKG_DATA}/_metadata/replaces ]]; then