diff --git a/winsup/doc/etc.postinstall.cygwin-doc.sh b/winsup/doc/etc.postinstall.cygwin-doc.sh index 124a5ddf5..3a9457fbb 100755 --- a/winsup/doc/etc.postinstall.cygwin-doc.sh +++ b/winsup/doc/etc.postinstall.cygwin-doc.sh @@ -1,12 +1,8 @@ -#!/bin/bash +#!/bin/sh # /etc/postinstall/cygwin-doc.sh - cygwin-doc postinstall script. # installs Cygwin Start Menu shortcuts for Cygwin User Guide and API PDF and # HTML if in doc dir, and links to Cygwin web site home page and FAQ # -# Assumes you are running setup.exe 2.510.2.2 or newer, executed by /bin/bash -# and not /bin/[da]sh (if you are running an older setup.exe, this postinstall -# script can't do anything). -# # CYGWINFORALL=-A if install for All Users # installs local shortcuts for All Users or Current User in # {ProgramData,~/Appdata/Roaming}/Microsoft/Windows/Start Menu/Programs/Cygwin/ @@ -48,43 +44,23 @@ fi # mkshortcut works only in current directory - change to Cygwin Start Menu cd "$smpc_dir" || exit 2 # quit if not found -# User Guide PDF & HTML -p=$doc/cygwin-ug-net.pdf -n="User Guide (PDF)" -d="PDF Cygwin User Guide" +# create User Guide and API PDF and HTML shortcuts +while read target name desc +do + [ -r $t ] && $mks -n "$name" -d "$desc" $target +done <