Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/bin/mksrcinfo
blob: 4a38b00546794c400caa9935836d5f16e9e2f132 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/bash

# generate .SRCINFO from PKGBUILD
#  bleh - this should really be handled by makepkg!

(
  . ./PKGBUILD

  if [ -z "${pkgbase}" ]; then
    printf 'pkgbase = %s\n' "${pkgname}"
  else
    printf 'pkgbase = %s\n' "${pkgbase}"
  fi
  printf '\tarch = %s\n' "${arch[@]}"
  printf '\tgroups = %s\n' "${groups[@]}"
  for print in 'makedepends' 'checkdepends' 'depends' 'provides'; do
    eval printf "'\t${print} = %s\n'" '"${'"${print}"'[@]}"'
    for a in 'i686'; do
      eval printf "'\t${print} = %s\n'" '"${'"${print}_${a}"'[@]}"'
    done
  done
  printf 'pkgname = %s\n' "${pkgname[@]}"
) > .SRCINFO