pkgmaker 596 B

1234567891011121314151617181920212223242526272829
  1. export TOPDIR=$(realpath ..)
  2. if gmake --help >/dev/null 2>&1; then
  3. export GMAKE=gmake
  4. else
  5. export GMAKE=make
  6. fi
  7. for subdir in bash; do
  8. cd $subdir
  9. pn=$($GMAKE show=PKG_NAME)
  10. typeset -u pnu=$pn
  11. pd=$($GMAKE show=PKG_DESCR)
  12. ph=$($GMAKE show=PKG_URL)
  13. (print "config ADK_PACKAGE_$pnu"
  14. pnf=$pn
  15. while (( ${#pnf} < 34 )); do
  16. pnf=$pnf.
  17. done
  18. print "\tprompt \"$pnf ${pd:-$pn}\""
  19. print \\ttristate
  20. print \\tdefault n
  21. if [[ -n $pd$ph ]]; then
  22. print \\thelp
  23. [[ -n $pd ]] && print "\t $pd"
  24. [[ -n $pd && -n $ph ]] && print '\t '
  25. [[ -n $ph ]] && print "\t $ph"
  26. fi
  27. ) >Config.in
  28. done