OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.7 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../googleearth/googleearth.conf
  5. # Copyright (C) 2007 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This program is free software; you can redistribute it and/or modify
  10. # it under the terms of the GNU General Public License as published by
  11. # the Free Software Foundation; version 2 of the License. A copy of the
  12. # GNU General Public License can be found in the file COPYING.
  13. # --- SDE-COPYRIGHT-NOTE-END ---
  14. # Set a custom install prefix.
  15. if [ $prefix_auto = 1 ] ; then
  16. prefix="opt/googleearth"
  17. set_confopt
  18. fi
  19. # comes as script with a bzip2 at the end so we need to find out
  20. # how many bytes the archive is and then extract it using tail
  21. custextract=googleearth_extract
  22. googleearth_extract() {
  23. local filesizes=
  24. # Determine the size of the archive.
  25. eval $( strings "$1" | grep '^filesizes=' )
  26. # Extract the archive.
  27. echo "Extracting $xsrctar:$filesizes ($taropt) ... "
  28. mkdir googleearth
  29. tail --bytes $filesizes $1 | tar -v $taropt - -C googleearth > untar.txt
  30. }
  31. install_googleearth(){
  32. # Do the actual installation.
  33. mkdir -pv $root/$prefix/google-earth
  34. tar -xvf googleearth/googleearth-linux-x86.tar -C $root/$prefix/google-earth
  35. tar -xvf googleearth/googleearth-data.tar -C $root/$prefix/google-earth
  36. mkdir -pv $root/$prefix/bin
  37. install -m 755 googleearth/bin/* $root/$prefix/bin
  38. # Install documentation.
  39. cp -vf googleearth/*.html $docdir
  40. # Make sure the necessary environment vars will be set.h
  41. echo "export GOOGLEEARTH_DATA_PATH=$root/$prefix/google-earth" > \
  42. $sysconfdir/profile.d/googleearth
  43. }