index : devtools32 | |
Archlinux32 fork of devtools | gitolite user |
summaryrefslogtreecommitdiff |
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile | 18 | ||||
-rw-r--r-- | arch-nspawn.in | 4 | ||||
-rw-r--r-- | archbuild.in | 10 |
@@ -16,3 +16,4 @@ find-libdeps crossrepomove arch-nspawn doc/*.1 +pacman-*-i686.conf @@ -22,6 +22,13 @@ BINPROGS = \ $(IN_PROGS) \ sogrep +GENERATED_CONFIGFILES = \ + pacman-extra-i686.conf \ + pacman-testing-i686.conf \ + pacman-staging-i686.conf \ + pacman-kde-unstable-i686.conf \ + pacman-gnome-unstable-i686.conf + CONFIGFILES = \ makepkg-x86_64.conf \ pacman-extra.conf \ @@ -31,7 +38,8 @@ CONFIGFILES = \ pacman-multilib-testing.conf \ pacman-multilib-staging.conf \ pacman-kde-unstable.conf \ - pacman-gnome-unstable.conf + pacman-gnome-unstable.conf \ + $(GENERATED_CONFIGFILES) COMMITPKG_LINKS = \ extrapkg \ @@ -74,11 +82,15 @@ MANS = \ doc/find-libprovides.1 -all: $(BINPROGS) bash_completion zsh_completion man +all: $(GENERATED_CONFIGFILES) $(BINPROGS) bash_completion zsh_completion man man: $(MANS) edit = sed -e "s|@pkgdatadir[@]|$(DESTDIR)$(PREFIX)/share/devtools|g" +pacman-%-i686.conf: pacman-%.conf + @echo "GEN $@" + @sed 's,/mirrorlist$$,\032,' "$<" > "$@" + %: %.in Makefile lib/common.sh @echo "GEN $@" @$(RM) "$@" @@ -93,7 +105,7 @@ doc/%: doc/%.asciidoc a2x --no-xmllint --asciidoc-opts="-f doc/asciidoc.conf" -d manpage -f manpage -D doc $< clean: - rm -f $(IN_PROGS) bash_completion zsh_completion $(MANS) + rm -f $(GENERATED_CONFIGFILES) $(IN_PROGS) bash_completion zsh_completion $(MANS) install: install -dm0755 $(DESTDIR)$(PREFIX)/bin diff --git a/arch-nspawn.in b/arch-nspawn.in index cebeb2e..bc2215a 100644 --- a/arch-nspawn.in +++ b/arch-nspawn.in @@ -84,7 +84,9 @@ build_mount_args() { copy_hostconf () { cp -a /etc/pacman.d/gnupg "$working_dir/etc/pacman.d" - printf 'Server = %s\n' "${host_mirrors[@]}" >"$working_dir/etc/pacman.d/mirrorlist" + printf 'Server = %s\n' "${host_mirrors[@]}" | \ + tee "$working_dir/etc/pacman.d/mirrorlist" > \ + "$working_dir/etc/pacman.d/mirrorlist32" [[ -n $pac_conf ]] && cp "$pac_conf" "$working_dir/etc/pacman.conf" [[ -n $makepkg_conf ]] && cp "$makepkg_conf" "$working_dir/etc/makepkg.conf" diff --git a/archbuild.in b/archbuild.in index 163a108..31c6317 100644 --- a/archbuild.in +++ b/archbuild.in @@ -11,11 +11,17 @@ cmd="${0##*/}" if [[ "${cmd%%-*}" == 'multilib' ]]; then repo="${cmd%-build}" arch='x86_64' + arch_ext='' base_packages+=(multilib-devel) else tag="${cmd%-build}" repo=${tag%-*} arch=${tag##*-} + if [ "${arch}" = 'x86_64' ]; then + arch_ext='' + else + arch_ext="-${arch}" + fi fi chroots='/var/lib/archbuild' clean_first=false @@ -61,14 +67,14 @@ if ${clean_first} || [[ ! -d "${chroots}/${repo}-${arch}" ]]; then rm -rf --one-file-system "${chroots}/${repo}-${arch}" mkdir -p "${chroots}/${repo}-${arch}" setarch "${arch}" mkarchroot \ - -C "@pkgdatadir@/pacman-${repo}.conf" \ + -C "@pkgdatadir@/pacman-${repo}${arch_ext}.conf" \ -M "@pkgdatadir@/makepkg-${arch}.conf" \ "${chroots}/${repo}-${arch}/root" \ "${base_packages[@]}" || abort else lock 9 "${chroots}/${repo}-${arch}/root.lock" "Locking clean chroot" arch-nspawn \ - -C "@pkgdatadir@/pacman-${repo}.conf" \ + -C "@pkgdatadir@/pacman-${repo}${arch_ext}.conf" \ -M "@pkgdatadir@/makepkg-${arch}.conf" \ "${chroots}/${repo}-${arch}/root" \ pacman -Syu --noconfirm || abort |