summaryrefslogtreecommitdiff
path: root/src/fullpkg
diff options
context:
space:
mode:
Diffstat (limited to 'src/fullpkg')
-rwxr-xr-xsrc/fullpkg/fullpkg21
-rwxr-xr-xsrc/fullpkg/fullpkg-build19
-rwxr-xr-xsrc/fullpkg/fullpkg-find68
3 files changed, 74 insertions, 34 deletions
diff --git a/src/fullpkg/fullpkg b/src/fullpkg/fullpkg
index 978cf7b..e053c6e 100755
--- a/src/fullpkg/fullpkg
+++ b/src/fullpkg/fullpkg
@@ -1,8 +1,27 @@
#!/usr/bin/env bash
-# set -x # uncomment for debug
# Builds packages from ABS recursively. It tries to find dependencies that
# aren't built or need update and then makepkg them in order.
+# Copyright (C) 2011 Nicolás Reynolds <fauno@parabola.nu>
+# Copyright (C) 2011-2012 Joshua Ismael Haase Hernández (xihh) <hahj87@gmail.com>
+#
+# License: GNU GPLv3+
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+. libremessages
+
usage() {
print "Usage: %s [OPTIONS] [BUILD_DIR]" "${0##*/}"
print "A (libre)makepkg wrapper that will also build dependencies"
diff --git a/src/fullpkg/fullpkg-build b/src/fullpkg/fullpkg-build
index e824c2e..06d0d50 100755
--- a/src/fullpkg/fullpkg-build
+++ b/src/fullpkg/fullpkg-build
@@ -3,6 +3,25 @@
# Builds packages from ABS recursively. It tries to find dependencies that
# aren't built or need update and then makepkg them in order.
+# Copyright (C) 2011 Joshua Ismael Haase Hernández (xihh) <hahj87@gmail.com>
+# Copyright (C) 2011 Nicolás Reynolds <fauno@parabola.nu>
+# Copyright (C) 2013 Luke Shumaker <lukeshu@sbcglobal.net>
+#
+# License: GNU GPLv3+
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
# TODO move __build to chroot
. libremessages
diff --git a/src/fullpkg/fullpkg-find b/src/fullpkg/fullpkg-find
index a96bc8a..c12888a 100755
--- a/src/fullpkg/fullpkg-find
+++ b/src/fullpkg/fullpkg-find
@@ -1,38 +1,39 @@
#!/usr/bin/env bash
# set -x # uncomment for debug
-# Copyright (c) 2011-2012 Joshua I. Haase H. (xihh) <hahj87@gmail.com>
-# Copyright (c) 2011-2012 Nicolás Reynolds <fauno@kiwwwi.com.ar>
-# Copyright (c) 2012 Michał Masłowski <mtjm@mtjm.eu>
-# Copyright (c) 2012-2013 Luke Shumaker <LukeShu@sbcglobal.net>
+# Copyright (C) 2011-2012 Joshua Ismael Haase Hernández (xihh) <hahj87@gmail.com>
+# Copyright (C) 2011-2012 Nicolás Reynolds <fauno@parabola.nu>
+# Copyright (C) 2012 Michał Masłowski <mtjm@mtjm.eu>
+# Copyright (C) 2013-2014 Luke Shumaker <lukeshu@sbcglobal.net>
#
# The copy_files() function is taken from makechrootpkg:
-# Copyright (c) 2007 Armin Luntzer <armin@archlinuxppc.org>
-# Copyright (c) 2007 Jason Chu <jchu@xentac.net>
-# Copyright (c) 2007, 2011 Dan McGee <dan@archlinux.org>
-# Copyright (c) 2007-2008 Travis Willard <travis@archlinux.org>
-# Copyright (c) 2007-2009 Aaron Griffin <aaronmgriffin@gmail.com>
-# Copyright (c) 2008 Simo Leone <simo@archlinux.org>
-# Copyright (c) 2009 Biru Ionut <biru.ionut@gmail.com>
-# Copyright (c) 2009 Biru Ionut <ionut@archlinux.ro>
-# Copyright (c) 2009 Evangelos Foutras <foutrelis@gmail.com>
-# Copyright (c) 2009 Francois Charette <francois@samarqand.localdomain>
-# Copyright (c) 2009 Nezmer <Nezmer@allurelinux.org>
-# Copyright (c) 2009 Ronald van Haren <pressh@gmail.com>
-# Copyright (c) 2009-2011 Andrea Scarpino <andrea@archlinux.org>
-# Copyright (c) 2009-2012 Allan McRae <allan@archlinux.org>
-# Copyright (c) 2009-2012 Eric Bélanger <snowmaniscool@gmail.com>
-# Copyright (c) 2009-2012 Pierre Schmitz <pierre@archlinux.de>
-# Copyright (c) 2010 Byron Clark <byron@theclarkfamily.name>
-# Copyright (c) 2011 Ionut Biru <ibiru@archlinux.org>
-# Copyright (c) 2011 Lukas Fleischer <archlinux@cryptocrack.de>
-# Copyright (c) 2011-2012 Florian Pritz <bluewind@xinu.at>
-# Copyright (c) 2011-2013 Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
-# Copyright (c) 2013 Sébastien Luttringer <seblu@seblu.net>
+# Copyright (C) 2007 Armin Luntzer <armin@archlinuxppc.org>
+# Copyright (C) 2007 Jason Chu <jchu@xentac.net>
+# Copyright (C) 2007, 2011 Dan McGee <dan@archlinux.org>
+# Copyright (C) 2007-2008 Travis Willard <travis@archlinux.org>
+# Copyright (C) 2007-2009 Aaron Griffin <aaronmgriffin@gmail.com>
+# Copyright (C) 2008 Simo Leone <simo@archlinux.org>
+# Copyright (C) 2009 Biru Ionut <ibiru@archlinux.org>
+# Copyright (C) 2009 Evangelos Foutras <foutrelis@gmail.com>
+# Copyright (C) 2009 Francois Charette <francois@samarqand.localdomain>
+# Copyright (C) 2009 Nezmer <Nezmer@allurelinux.org>
+# Copyright (C) 2009 Ronald van Haren <pressh@gmail.com>
+# Copyright (C) 2009-2011 Andrea Scarpino <andrea@archlinux.org>
+# Copyright (C) 2009-2012 Allan McRae <allan@archlinux.org>
+# Copyright (C) 2009-2012 Eric Bélanger <snowmaniscool@gmail.com>
+# Copyright (C) 2009-2012 Pierre Schmitz <pierre@archlinux.de>
+# Copyright (C) 2010 Byron Clark <byron@theclarkfamily.name>
+# Copyright (C) 2011 Ionut Biru <ibiru@archlinux.org>
+# Copyright (C) 2011 Lukas Fleischer <archlinux@cryptocrack.de>
+# Copyright (C) 2011-2012 Florian Pritz <bluewind@xinu.at>
+# Copyright (C) 2011-2013 Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
+# Copyright (C) 2013 Sébastien Luttringer <seblu@seblu.net>
#
# Because of the code from makechrootpkg, this file is GPLv2, instead of GPLv3
# like most of libretools.
#
+# License: GNU GPLv2
+#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License.
@@ -51,7 +52,7 @@
# Get repo name. Asumes ${ABSROOT}/repo/package/PKGBUILD
guess_repo() {
- basename $(dirname $(pwd))
+ basename "$(dirname "$(pwd)")"
}
# This function is stolen from makechrootpkg.
@@ -120,11 +121,12 @@ find_deps() {
## Check next levels
declare -i next_level=$LEVEL+1
- # All deps in separate line, only once, without version.
- deps=($(echo "${depends[@]} ${makedepends[@]}" | \
- sed "s/[=<>]\+[^ ]\+//g" | \
- tr ' ' "\n" | \
- sort -u))
+ # All deps
+ local deps=("${depends[@]}" "${makedepends[@]}" "${checkdepends[@]}")
+ # Strip version specifiers
+ deps=("${deps[@]%%[=<>]*}")
+ # Filter out duplicates
+ read -d $'\n' -a deps <<<"$(printf '%s\n' "${deps[@]}"|sort -u)"
local _dep
for _dep in "${deps[@]}"; do
@@ -139,7 +141,7 @@ find_deps() {
pushd "${pkgdir}" > /dev/null
# runs itself on dep's PKGBUILD dir
- $0 -l ${next_level} ${build_dir} || return $?
+ "$0" -l "${next_level}" "${build_dir}" || return $?
popd > /dev/null
fi