openpkg.boot 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510
  1. #!/bin/sh
  2. ##
  3. ## openpkg.boot -- OpenPKG bootstrap procedure (look Ma, without hands ;)
  4. ## Copyright (c) 2000-2003 Cable & Wireless Deutschland GmbH
  5. ## Copyright (c) 2000-2003 The OpenPKG Project <http://www.openpkg.org/>
  6. ## Copyright (c) 2000-2003 Ralf S. Engelschall <rse@engelschall.com>
  7. ##
  8. # This is a very tricky procedure for building the OpenPKG bootstrap
  9. # package via the RPM specification openpkg.spec, but without
  10. # requiring that OpenPKG's RPM already exists. For this the
  11. # openpkg.spec file is manually executed here in order to build
  12. # OpenPKG RPM the first time (that is, we emulate a sufficient
  13. # subset of the RPM functionality), followed by a second round over
  14. # openpkg.spec with the real (and then existing) OpenPKG RPM tool.
  15. # Also keep in mind that lots of tricks are played here in order to
  16. # perform all the steps without having to touch the real installation
  17. # location. That is the whole procedure can (and should) be performed
  18. # by a non-privileged user and no access to the real installation
  19. # location filesystem location.
  20. me="openpkg.boot"
  21. ##
  22. ## command line handling
  23. ##
  24. # command line parameters (defaults)
  25. help=0
  26. verbose=''
  27. prefix=''
  28. usr=''; grp=''
  29. susr=''; sgrp=''
  30. musr=''; mgrp=''
  31. rusr=''; rgrp=''
  32. nusr=''; ngrp=''
  33. bs=0
  34. # parse command line options
  35. for opt
  36. do
  37. case $opt in
  38. -*=*) arg=`echo "$opt" | sed 's/^[-_a-zA-Z0-9]*=//'` ;;
  39. *) arg='' ;;
  40. esac
  41. case $opt in
  42. -h | --help ) help=1 ;;
  43. -v | --verbose ) verbose=v ;;
  44. --prefix=* ) prefix=$arg ;;
  45. --usr=* | --user=* ) usr=$arg ;;
  46. --grp=* | --group=* ) grp=$arg ;;
  47. --susr=* ) susr=$arg ;;
  48. --sgrp=* ) sgrp=$arg ;;
  49. --musr=* ) musr=$arg ;;
  50. --mgrp=* ) mgrp=$arg ;;
  51. --rusr=* ) rusr=$arg ;;
  52. --rgrp=* ) rgrp=$arg ;;
  53. --nusr=* ) nusr=$arg ;;
  54. --ngrp=* ) ngrp=$arg ;;
  55. -bs | -s ) bs=1 ;;
  56. * ) help=1 ;;
  57. esac
  58. done
  59. if [ ".$bs" = .0 -a ".$prefix" = . ]; then
  60. help=1
  61. fi
  62. if [ ".$help" = .1 ]; then
  63. echo "Usage: sh $me [-h|--help] [-v|--verbose]" 2>&1
  64. echo " --prefix=<prefix> [--user=<usr>] [--group=<grp>]" 2>&1
  65. echo " [--{s,m,r,n}usr=<usr>] [--{s,m,r,n}grp=<grp>]" 2>&1
  66. exit 1
  67. fi
  68. # determine missing parameters
  69. eval `sh aux.usrgrp.sh \
  70. --usr="$usr" --grp="$grp" \
  71. --susr="$susr" --sgrp="$sgrp" \
  72. --musr="$musr" --mgrp="$mgrp" \
  73. --rusr="$rusr" --rgrp="$rgrp" \
  74. --nusr="$nusr" --ngrp="$ngrp"`
  75. ##
  76. ## determine package information
  77. ##
  78. name="openpkg"
  79. spec="$name.spec"
  80. version=`grep V_openpkg $spec | head -1 | awk '{ printf("%s", $3); }'`
  81. release=`grep R_openpkg $spec | head -1 | awk '{ printf("%s", $3); }'`
  82. ##
  83. ## display headline
  84. ##
  85. sh ./shtool echo -e "%BOpenPKG Bootstrap Procedure%b"
  86. echo "++ bootstrap version: $version-$release"
  87. echo "++ user/group pairs: $susr/$sgrp $musr/$mgrp $rusr/$rgrp $nusr/$ngrp"
  88. ##
  89. ## optionally roll just a bootstrap source package
  90. ##
  91. if [ ".$bs" = .1 ]; then
  92. srcdir=.
  93. if [ -d ../../DST ]; then
  94. dstdir=../../DST/openpkg
  95. elif [ -d ../../dst ]; then
  96. dstdir=../../dst/openpkg
  97. else
  98. dstdir=.
  99. fi
  100. tmpdir="/tmp/$me.$$.d"
  101. if [ -d ../PKG/SRC ]; then
  102. pkgdir=../PKG/SRC
  103. elif [ -d ../PKG ]; then
  104. pkgdir=../PKG
  105. elif [ -d ../../PKG/SRC ]; then
  106. pkgdir=../../PKG/SRC
  107. elif [ -d ../../PKG ]; then
  108. pkgdir=../../PKG
  109. elif [ -d ../../pkg/src ]; then
  110. pkgdir=../../pkg/src
  111. elif [ -d ../../pkg ]; then
  112. pkgdir=../../pkg
  113. else
  114. pkgdir=..
  115. fi
  116. echo "** rolling source bootstrap package:"
  117. echo " $pkgdir/$name-$version-$release.src.sh"
  118. rm -rf $tmpdir
  119. mkdir $tmpdir
  120. ( echo "dstdir=$dstdir"
  121. echo "srcdir=$srcdir"
  122. echo "tmpdir=$tmpdir"
  123. grep '^%define' $spec | sed -e 's:^%define *\([^ ]*\) *\(.*\):\1="\2":'
  124. grep '^Source' $spec | sed -e 's;^Source[0-9]*: *;;' -e 's;^.*/;$dstdir/;' \
  125. -e 's;^\([^/]*\)$;$srcdir/\1;' -e 's;%;$;g' \
  126. -e 's;^\(.*\)$;cp \1 $tmpdir/;'
  127. echo "cp -p $spec $tmpdir/"
  128. ) >$tmpdir/.sh
  129. sh $tmpdir/.sh
  130. rm -f $tmpdir/.sh
  131. sed <$srcdir/aux.wrapsrc.sh >$pkgdir/$name-$version-$release.src.sh \
  132. -e "s;@DIR@;$name-$version-$release.src;" -e "s;@TGZ@;$name-$version-$release.src.tar.Z;"
  133. (cd $tmpdir && tar cf - *) |\
  134. uuencode $name-$version-$release.src.tar.Z |\
  135. dd bs=64000 2>/dev/null >>$pkgdir/$name-$version-$release.src.sh
  136. exit 0
  137. fi
  138. ##
  139. ## calculate location id
  140. ##
  141. prefix=`echo "$prefix" | sed -e 's;//*;/;g' -e 's;/$;;'`
  142. if [ ".`expr $prefix : '/[^/][^/]*$'`" != .0 ]; then
  143. loc=`echo $prefix | cut -c2-4`
  144. else
  145. loc=`echo $prefix | sed -e 's;/\(.\)[^/]*;\1;g' | cut -c1-3`
  146. fi
  147. echo "++ location id: $loc"
  148. ##
  149. ## determine distribution directory
  150. ##
  151. V_rpm=`grep V_rpm $spec | head -1 | awk '{ printf("%s", $3); }'`
  152. if [ -f "../../DST/openpkg/rpm-${V_rpm}.tar.gz" ]; then
  153. distdir="`cd ../../DST/openpkg; pwd`" # developer only
  154. else
  155. distdir="`pwd`"
  156. fi
  157. echo "++ distribution directory: $distdir"
  158. ##
  159. ## perform prerequisite checks
  160. ##
  161. sh ./aux.prereq.sh source
  162. ##
  163. ## find reasonable run-time paths and tools
  164. ##
  165. # find reasonable temporary directory
  166. tmpdir="/tmp"
  167. test ".$TMPDIR" != . && tmpdir="$TMPDIR"
  168. test ".$TEMPDIR" != . && tmpdir="$TEMPDIR"
  169. # find reasonable safe program path
  170. test ".$PATH" = . && PATH="/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin"
  171. for dir in /usr/ccs/bin /usr/xpg4/bin; do
  172. test -d $dir && PATH="$PATH:$dir"
  173. done
  174. export PATH
  175. # find reasonable UUENCODE
  176. l_uuencode=''
  177. for t in guuencode uuencode; do
  178. for p in `IFS=":"; echo . $PATH`; do
  179. if [ -f "$p/$t" ]; then
  180. l_uuencode="$p/$t"
  181. break
  182. fi
  183. done
  184. [ ".$l_uuencode" != . ] && break
  185. done
  186. if [ ".$l_uuencode" = . ]; then
  187. echo "$0:FAILED: required UUENCODE not found"
  188. exit 1
  189. fi
  190. # find reasonable TAR
  191. l_tar=''
  192. for t in gtar tar; do
  193. for p in `IFS=":"; echo . $PATH`; do
  194. if [ -f "$p/$t" ]; then
  195. l_tar="$p/$t"
  196. break
  197. fi
  198. done
  199. [ ".$l_tar" != . ] && break
  200. done
  201. if [ ".$l_tar" = . ]; then
  202. echo "$0:FAILED: required TAR not found"
  203. exit 1
  204. fi
  205. # find required Make tool
  206. l_make=''
  207. for t in gmake make; do
  208. for p in `IFS=":"; echo . $PATH`; do
  209. if [ -f "$p/$t" ]; then
  210. l_make="$p/$t"
  211. break
  212. fi
  213. done
  214. [ ".$l_make" != . ] && break
  215. done
  216. if [ ".$l_make" = . ]; then
  217. echo "$0:FAILED: required Make tool not found"
  218. exit 1
  219. fi
  220. # find required [GNU] C Compiler
  221. l_cc=''
  222. for t in egcc ggcc gcc cc; do
  223. for p in `IFS=":"; echo . $PATH`; do
  224. if [ -f "$p/$t" ]; then
  225. # if [ ".`$p/$t --version 2>/dev/null | grep '[23]\.[789]'`" != . ]; then
  226. l_cc="$p/$t"
  227. break
  228. # fi
  229. fi
  230. done
  231. [ ".$l_cc" != . ] && break
  232. done
  233. if [ ".$l_cc" = . ]; then
  234. echo "$0:FAILED: required [GNU] C/C++ compiler not found"
  235. exit 1
  236. fi
  237. ##
  238. ## execute the spec file manually by emulating
  239. ## the behaviour of the OpenPKG RPM tool.
  240. ##
  241. # create script prolog
  242. prolog="$tmpdir/openpkg.boot.prolog.sh"
  243. cp /dev/null $prolog
  244. (
  245. echo "_specdir=`pwd`"
  246. echo "_sourcedir=$distdir"
  247. echo "_tmppath=$tmpdir"
  248. echo "_builddir=$tmpdir"
  249. echo "l_prefix=$prefix"
  250. echo "l_location=$loc"
  251. echo "l_buildroot=$tmpdir/$name-$version-root"
  252. echo "l_susr=$susr"
  253. echo "l_sgrp=$sgrp"
  254. echo "l_musr=$musr"
  255. echo "l_mgrp=$mgrp"
  256. echo "l_rusr=$rusr"
  257. echo "l_rgrp=$rgrp"
  258. echo "l_nusr=$nusr"
  259. echo "l_ngrp=$ngrp"
  260. echo "l_tar=$l_tar"
  261. echo "l_make=$l_make"
  262. echo "l_cc=$l_cc"
  263. grep '%define' $spec | \
  264. sed \
  265. -e 's:^%define *\([^ ]*\) *\(.*\):\1="\2":'
  266. grep "^[A-Za-z0-9]*: *" $spec | \
  267. sed \
  268. -e 's;^\([A-Za-z0-9]*\): *\(.*\)$;\1="\2";' \
  269. -e 's;^A;a;' -e 's;^B;b;' -e 's;^C;c;' -e 's;^D;d;' -e 's;^E;e;' \
  270. -e 's;^F;f;' -e 's;^G;g;' -e 's;^H;h;' -e 's;^I;i;' -e 's;^J;j;' \
  271. -e 's;^K;k;' -e 's;^L;l;' -e 's;^M;m;' -e 's;^N;n;' -e 's;^O;o;' \
  272. -e 's;^P;p;' -e 's;^Q;q;' -e 's;^R;r;' -e 's;^S;s;' -e 's;^T;t;' \
  273. -e 's;^U;u;' -e 's;^V;v;' -e 's;^W;w;' -e 's;^X;x;' -e 's;^Y;y;' \
  274. -e 's;^Z;z;' -e 's;^buildRoot;buildroot;'
  275. echo "RPM_BUILD_ROOT=\"%{buildroot}\""
  276. echo "RPM_BUILD_DIR=\"%{_builddir}\""
  277. echo "RPM_SOURCE_DIR=\"$distdir\""
  278. echo "export RPM_BUILD_ROOT"
  279. echo "export RPM_BUILD_DIR"
  280. echo "export RPM_SOURCE_DIR"
  281. echo "set -x"
  282. echo "umask 022"
  283. echo "cd \$RPM_BUILD_DIR"
  284. ) | sed -e 's;%{\([^}]*\)};${\1};g' >$prolog
  285. # install package via RPM spec file by faking a
  286. # sufficiently enough RPM run-time environment
  287. runscript () {
  288. step=$1
  289. script="$tmpdir/openpkg.boot.$step.sh"
  290. echo ". $prolog" >$script
  291. sed -e "/^%$step/,/^%/ p" -e 'd' <$spec | \
  292. sed -e '/^%/d' | \
  293. sed -e 's;%{SOURCE \([^ ]*\.tar[^ ]*\)};${RPM_DIST_DIR}/\1;g' \
  294. -e 's;%{SOURCE \([^ ]*\)};${RPM_SOURCE_DIR}/\1;g' | \
  295. sed -e 's;%{[?]\([^:]*\):\([^}]*\)};${\1+\2};g' \
  296. -e 's;%{![?]\([^:]*\):\([^}]*\)};${\1-\2};g' \
  297. -e 's;%{\([^}]*\)};${\1};g' >>$script
  298. echo "++ executing(%$step): sh $script"
  299. sh $script
  300. if [ $? -ne 0 ]; then
  301. rm -f $script
  302. echo "$0:ERROR: script returned non-null value"
  303. exit 1
  304. fi
  305. rm -f $script
  306. }
  307. runscript prep
  308. runscript build
  309. runscript install
  310. ##
  311. ## adjust build environment so that the installed
  312. ## "rpm" is actually useable, although it still resides in
  313. ## the temporary location instead of the real location.
  314. ##
  315. # suck in prolog in order to get variables from the spec file
  316. cwd=`pwd`
  317. . $prolog
  318. cd $cwd
  319. # suck in buildenv script in order to get musr/mgrp
  320. . $tmpdir/openpkg-*/.buildenv
  321. # create a custom "rpm" command
  322. echo "++ creating custom RPM command"
  323. rm -f $tmpdir/rpm >/dev/null 2>&1
  324. rmdir $tmpdir/rpm >/dev/null 2>&1
  325. if [ -d "$tmpdir/rpm" ]; then
  326. echo "$0:ERROR: directory $tmpdir/rpm exists, cannot create file with same name"
  327. exit 1
  328. fi
  329. if [ -f "$tmpdir/rpm" ]; then
  330. echo "$0:ERROR: file $tmpdir/rpm exists, cannot override"
  331. exit 1
  332. fi
  333. echo "#!/bin/sh" >$tmpdir/rpm
  334. echo "exec $RPM_BUILD_ROOT$prefix/lib/openpkg/rpm --rcfile $tmpdir/rpm.1 \"\$@\"" >>$tmpdir/rpm
  335. chmod a+x $tmpdir/rpm
  336. # direct our own "rpm" tool to adjusted macro sets
  337. sed <`SOURCE rpmrc` >$tmpdir/rpm.1 \
  338. -e "s;^\\(macrofiles:\\) .*;\\1 $tmpdir/rpm.2:$tmpdir/rpm.3;"
  339. # use an adjusted vendor macro set
  340. sed <$RPM_BUILD_ROOT$prefix/lib/openpkg/macros >$tmpdir/rpm.2 \
  341. -e "s;$prefix;$RPM_BUILD_ROOT$prefix;g"
  342. # override the vendor macro set
  343. sed <`SOURCE rpmmacros` >$tmpdir/rpm.3 \
  344. -e "s;@SUSR@;$susr;" \
  345. -e "s;@SGRP@;$sgrp;" \
  346. -e "s;@MUSR@;$musr;" \
  347. -e "s;@MGRP@;$mgrp;" \
  348. -e "s;@RUSR@;$rusr;" \
  349. -e "s;@RGRP@;$rgrp;" \
  350. -e "s;@NUSR@;$nusr;" \
  351. -e "s;@NGRP@;$ngrp;" \
  352. -e "s;@LOC@;$loc;" \
  353. -e "s;^\\(%l_root_install *\\)@l_prefix@;\\1 $prefix;" \
  354. -e "s;^\\(%l_root_rpm *\\)@l_prefix@;\\1 $RPM_BUILD_ROOT$prefix;" \
  355. -e "s;^\\(%_specdir *\\).*;\\1 `pwd`;" \
  356. -e "s;^\\(%_sourcedir *\\).*;\\1 $distdir;" \
  357. -e "s;^\\(%_builddir *\\).*;\\1 $tmpdir;" \
  358. -e "s;^\\(%_tmppath *\\).*;\\1 $tmpdir;" \
  359. -e "s;^\\(%_buildshell *\\).*;\\1 /bin/sh;" \
  360. -e "s;@l_build_path@;/bin:/sbin:/usr/bin:/usr/sbin;g" \
  361. -e "s;@l_build_ldlp@;/usr/lib;g" \
  362. -e "s;@l_build_ulim@;:;g"
  363. # use an own $HOME/.popt in order to make sure the "rpm"
  364. # tool is able to execute its sub-tools "rpm<x>".
  365. V_rpm=`grep V_rpm $spec | head -1 | awk '{ printf("%s", $3); }'`
  366. sed <$RPM_BUILD_ROOT$prefix/lib/openpkg/rpmpopt-${V_rpm} >$tmpdir/.popt \
  367. -e "s;^\\(rpm.*exec.*\\)\\(rpm[bdeukv]*\\);\\1$RPM_BUILD_ROOT$prefix/lib/openpkg/\\2;"
  368. # activate the .popt file
  369. HOME=$tmpdir
  370. export HOME
  371. ##
  372. ## now initialize the RPM database under the temporary install location
  373. ##
  374. echo "++ initializing RPM database"
  375. $tmpdir/rpm --initdb
  376. ##
  377. ## now turn over and re-iterate over the RPM spec, but this time
  378. ## with the real RPM tool.
  379. ##
  380. echo "++ re-iterating over RPM specification procedures"
  381. OPENPKG_BOOT=1
  382. export OPENPKG_BOOT
  383. $tmpdir/rpm -bb $spec
  384. ##
  385. ## and finally overwrite the installation again, but this time by
  386. ## installing officially through the "rpm" tool. This way we achieve
  387. ## that RPM is remembered as an RPM package in its own database. We
  388. ## just have to make sure the package is relocated while installing.
  389. ## For this we could use --prefix=$RPM_BUILD_ROOT$prefix, but this
  390. ## would create an incorrect filelist for "rpm" in the database.
  391. ## Instead we use the --justdb option which means "rpm" behaves as it
  392. ## would install into the real location, but does not actually install
  393. ## anything. But as a side-effect, the database is now correct.
  394. ##
  395. echo "++ overwriting RPM installation by installing via RPM itself"
  396. $tmpdir/rpm -Uvh --force --noscripts --notriggers --justdb --ignoresize \
  397. $RPM_BUILD_ROOT$prefix/RPM/PKG/openpkg-*.rpm
  398. ## Puhhhh!!! what a tricky bootstrapping procedure. But now we are
  399. ## mostly finished. All we finally have to do is to roll a bootstrap
  400. ## tarball in addition to the binary RPM and save the stuff in a
  401. ## permanent location.
  402. v="$version-$release"
  403. t="`$tmpdir/rpm --eval '%{_target}'`-$loc"
  404. # find a reasonable destination directory for packages
  405. if [ -d ../PKG/BIN ]; then
  406. dstdir=../PKG/BIN
  407. elif [ -d ../PKG ]; then
  408. dstdir=../PKG
  409. elif [ -d ../../PKG/BIN ]; then
  410. dstdir=../../PKG/BIN
  411. elif [ -d ../../PKG ]; then
  412. dstdir=../../PKG
  413. else
  414. dstdir=..
  415. fi
  416. # create Source-RPM file
  417. echo "++ creating bootstrap source RPM file"
  418. $tmpdir/rpm -bs --nodeps $spec
  419. cp $RPM_BUILD_ROOT$prefix/RPM/PKG/openpkg-$v.src.rpm $dstdir/
  420. rm -f $RPM_BUILD_ROOT$prefix/RPM/PKG/openpkg-$v.src.rpm
  421. # create Binary-RPM file
  422. echo "++ creating bootstrap binary RPM file"
  423. cp $RPM_BUILD_ROOT$prefix/RPM/PKG/openpkg-$v.$t.rpm $dstdir/
  424. rm -f $RPM_BUILD_ROOT$prefix/RPM/PKG/openpkg-$v.$t.rpm
  425. # create Binary-Bootstrap file
  426. echo "++ creating bootstrap binary shell script"
  427. cat $spec | sed -e "/^%pre$/,/^%/ p" -e 'd' | sed -e '/^%/d' -e 's/^ //' >$tmpdir/rpm.pre
  428. sed <`SOURCE aux.wrapbin.sh` \
  429. -e "s;@SUSR@;$susr;" -e "s;@SGRP@;$sgrp;" \
  430. -e "s;@MUSR@;$musr;" -e "s;@MGRP@;$mgrp;" \
  431. -e "s;@RUSR@;$rusr;" -e "s;@RGRP@;$rgrp;" \
  432. -e "s;@NUSR@;$nusr;" -e "s;@NGRP@;$ngrp;" \
  433. -e "s;@l_prefix@;$prefix;" -e "s;@TGZ@;openpkg-$v.$t.tar.Z;" \
  434. -e "/^@PRE@/r $tmpdir/rpm.pre" |\
  435. sed -e '/^@PRE@/d' >$dstdir/openpkg-$v.$t.sh
  436. files=`cat $spec |\
  437. sed -e '1,/%files/d' -e '/%clean/,$d' |\
  438. grep -v '^ *$' | grep -v '%defattr' |\
  439. sed -e 's;%config(noreplace) *;;' -e 's;%config *;;' \
  440. -e 's;%dir *;;' -e 's;%{l_prefix}/;;' -e 's;^ *;;' -e "s;%{V_rpm};${V_rpm};"`
  441. for dbfile in Basenames Conflictname Group Name Packages Providename \
  442. Requirename Triggername; do
  443. files="$files RPM/DB/$dbfile"
  444. done
  445. ( cd $RPM_BUILD_ROOT$prefix;
  446. $RPM_BUILD_ROOT$prefix/lib/openpkg/tar --no-recursion -cf - $files) |\
  447. $l_uuencode openpkg-$v.$t.tar.Z >>$dstdir/openpkg-$v.$t.sh
  448. # cleanup
  449. echo "++ cleaning up"
  450. rm -rf $RPM_BUILD_ROOT
  451. rm -rf $tmpdir/$name-$version
  452. rm -f $tmpdir/rpm $tmpdir/rpm.[123] $tmpdir/.popt $tmpdir/rpm.pre
  453. rm -f $prolog
  454. # final hint about results
  455. set +x
  456. echo "++ resulting files (placed into $dstdir):"
  457. (cd $dstdir; ls -l openpkg-$v.$t.sh openpkg-$v.$t.rpm openpkg-$v.src.rpm)