www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 094c41ebf2932b9a7ed8215340faeab19b3f6702
parent a4fea75eeee594707ba1f2dd0205f573fcfde9f6
Author: Matthew Flatt <mflatt@racket-lang.org>
Date:   Sat, 10 Aug 2013 08:46:43 -0600

Add ".desktop" file support

A launcher can have a ".desktop" file (found like other files: as the
same name as the main launcher file, but with a ".desktop" suffix),
where the "Exec" and "Icon" fields are added automatically. A ".png"
or ".ico" file can be supplied for the icon (where the ".ico" file
is already used for Windows launchers).

Closes PR 13953

Fix various problems with Unix-style install from an installer.

Also, add an ugly icon for the Racket Package Manager, with the hope
that it will provoke someone to create a nicer one.

original commit: 58c0074a7181a1590dfa0a931ba63c29a4334726

Diffstat:
Mpkgs/distro-build/unix-installer/installer-header | 32++++++++++++++++++--------------
1 file changed, 18 insertions(+), 14 deletions(-)

diff --git a/pkgs/distro-build/unix-installer/installer-header b/pkgs/distro-build/unix-installer/installer-header @@ -159,13 +159,14 @@ esac set_dirs() { # unixstyle: uses all of these - # wholedir: uses only bindir & mandir, no need for the others + # wholedir: uses only bindir, mandir, and appsdir, no need for the others bindir="$1/bin" libdir="$1/lib" incrktdir="$1/include/$TARGET" librktdir="$1/lib/$TARGET" sharerktdir="$1/share/$TARGET" configdir="$1/etc/$TARGET" + appsdir="$1/share/applications" has_share="N" if test -d "$1/share"; then has_share="Y"; fi if test "$has_share" = "N" && test -d "$1/doc"; then docdir="$1/doc/$TARGET" @@ -242,10 +243,10 @@ wholedir_install() { rm_on_abort="" echo "" - echo "If you want to install new system links within the \"bin\" and" - echo " \"man\" subdirectories of a common directory prefix (for example," - echo " \"/usr/local\") then enter the prefix of an existing directory" - echo " that you want to use. This might overwrite existing symlinks," + echo "If you want to install new system links within the \"bin\", \"man\"" + echo " and \"share/applications\" subdirectories of a common directory prefix" + echo " (for example, \"/usr/local\") then enter the prefix of an existing" + echo " directory that you want to use. This might overwrite existing symlinks," echo " but not files." echon "(default: skip links) > " read SYSDIR @@ -280,6 +281,7 @@ wholedir_install() { } install_links "$bindir" "bin" install_links "$mandir/man1" "man/man1" + install_links "$appsdir" "share/applications" fi } @@ -327,14 +329,15 @@ unixstyle_install() { if test "$retry" = "N"; then echo "" echo "Target Directories:" - show_dir_var "[e] Executables " "$bindir" - show_dir_var "[o] Libraries " "$librktdir" - show_dir_var "[s] Shared files " "$sharerktdir" - show_dir_var "[c] Configuration" "$configdir" - show_dir_var "[d] Documentation" "$docdir" - show_dir_var "[l] C Libraries " "$libdir" - show_dir_var "[h] C headers " "$incrktdir" - show_dir_var "[m] Man Pages " "$mandir" + show_dir_var "[e] Executables " "$bindir" + show_dir_var "[o] Libraries " "$librktdir" + show_dir_var "[s] Shared files " "$sharerktdir" + show_dir_var "[c] Configuration " "$configdir" + show_dir_var "[d] Documentation " "$docdir" + show_dir_var "[a] .desktop files" "$appsdir" + show_dir_var "[m] Man Pages " "$mandir" + show_dir_var "[l] C Libraries " "$libdir" + show_dir_var "[h] C headers " "$incrktdir" echo "Enter a letter to change an entry, or enter to continue." fi retry="N" @@ -355,6 +358,7 @@ unixstyle_install() { [oO]* ) read_dir librktdir ;; [sS]* ) read_dir sharerktdir ;; [cC]* ) read_dir configdir ;; + [aA]* ) read_dir appsdir ;; [mM]* ) read_dir mandir ;; "" ) if test "$err" = "N"; then done="Y" else echo "*** Please fix erroneous paths to proceed"; fi ;; @@ -387,7 +391,7 @@ unixstyle_install() { cd "$where" "$tmp/bin/racket" "$tmp/collects/setup/unixstyle-install.rkt" \ "move" "$tmp" "$bindir" "$sharerktdir/collects" "$docdir" "$libdir" \ - "$incrktdir" "$librktdir" "$sharerktdir" "$configdir" "$mandir" \ + "$incrktdir" "$librktdir" "$sharerktdir" "$configdir" "$appsdir" "$mandir" \ || failwith "installation failed" }