Update for perl-5.26.0
[git/cygwin-packages/biber.git] / prereqs02 / build.sh
CommitLineData
30aaa56e
KB
1#! /bin/bash
2
3# Run in elevated shell as kbrown-admin.
4# Copy setup-*.exe to *.exe to avoid prompt.
5
6SYSARCH=$(uname -m)
7if [ ${SYSARCH} = i686 ]
8then
9 GENINI="GEN-ini"
10 DEST_ARCH="x86"
11else
12 GENINI="GEN-ini64"
13 DEST_ARCH="x86_64"
14fi
15
16setup="/c/downloads/cygwin/${DEST_ARCH}.exe"
17
18GENINI() {
19 mksetupini --arch=${DEST_ARCH} --release=kbrown --inifile=${DEST_ARCH}/setup.ini \
20 --okmissing=required-package --okmissing=curr --releasearea .
21cd ${DEST_ARCH}
22xz -c setup.ini > setup.xz
23chown kbrown setup.ini setup.xz
24cd ..
25}
26
27install() {
28 local command
29 pushd /c/downloads/cygwin/myrepo
30 GENINI
31 popd
32 command="${setup} -q -X -L"
33 for m in ${mods}
34 do
35 command+=" -P ${m}"
36 done
37 echo "Running ${command}"
38 ${command}
39}
40
41mods="
42 perl-ExtUtils-Helpers
43 perl-ExtUtils-InstallPaths
44 perl-Importer
45 perl-Module-Runtime
46 perl-Test-Fatal
47 perl-Test-Requires
48 perl-Test-Simple
67677658 49 perl-Module-Install
30aaa56e
KB
50"
51
52rm -f build_failures.txt test_failures.txt
53touch build_failures.txt test_failures.txt
54chown kbrown build_failures.txt test_failures.txt
55
56export cygport_no_error=1
57
58for m in ${mods}
59do
60 eval $(grep '^NAME=' ${m}/${m}.cygport)
61 eval $(grep '^VERSION=' ${m}/${m}.cygport)
62 eval $(grep '^RELEASE=' ${m}/${m}.cygport)
63 PVR=${NAME}-${VERSION}-${RELEASE}
64 ARCH=${SYSARCH}
65 eval $(grep '^ARCH=' ${m}/${m}.cygport)
66 if [ ${ARCH} = i686 -o ${SYSARCH} = x86_64 ]
67 then
68 echo "Entering ${m}..."
69 cd ${m} || exit 1
70 echo "Running cygport..."
71 rm -rf ${PVR}.${ARCH}
72 if cygport ${m}.cygport fetch all
73 then
74 cygport ${m}.cygport test || echo $m >> ../test_failures.txt
75 if [ ${ARCH} = noarch ]
76 then
77 dest=/c/downloads/cygwin/myrepo/noarch/release/
78 else
79 dest=/c/downloads/cygwin/myrepo/${DEST_ARCH}/release/
80 fi
81 chown -R kbrown .
82 rm -rf ${dest}/${m}
83 cp -alf ${PVR}.${ARCH}/dist/${m} ${dest}
84 else
85 echo ${m} >> ../build_failures.txt
86 chown -R kbrown .
87 fi
88 echo "Leaving ${m}."
89 cd ..
90 fi
91done
92install
93if [ -n "$(cat *.txt)" ]
94then
95 echo There were failures.
96 exit 1
97else
98 exit 0
99fi
100
This page took 0.02693 seconds and 5 git commands to generate.