Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ include(CheckIncludeFile)
include(gbversion.cmake)
project(gpsbabel LANGUAGES C CXX VERSION ${GB.VERSION})

if(UNIX AND NOT APPLE)
include(GNUInstallDirs)
endif()

set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED True)

Expand Down Expand Up @@ -493,3 +497,6 @@ if(UNIX AND NOT APPLE)
VERBATIM
USES_TERMINAL)
endif()
if(_GPSBABEL_INSTALL)
install(TARGETS gpsbabel DESTINATION ${CMAKE_INSTALL_BINDIR})
endif()
14 changes: 14 additions & 0 deletions gui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -329,3 +329,17 @@ else()
endif()
endif()
endif()
if(UNIX AND NOT APPLE)
if (((GPSBABEL_GOOGLE_MAPPREVIEW AND GPSBABEL_EMBED_MAP) OR NOT GPSBABEL_GOOGLE_MAPPREVIEW) AND GPSBABEL_EMBED_TRANSLATIONS)
set(_GPSBABEL_INSTALL ON PARENT_SCOPE)
install(TARGETS gpsbabelfe DESTINATION ${CMAKE_INSTALL_BINDIR})
# you probably don't need to run update-desktop-database on ${CMAKE_INSTALL_DATADIR}/applications as our desktop file doesn't have MimeTypes.
install(FILES gpsbabelfe.desktop DESTINATION ${CMAKE_INSTALL_DATADIR}/applications)
# you may need to run gtk-update-icon-cache on ${CMAKE_INSTALL_DATADIR}/icons/hicolor, possibly with -t or equivalently with --ignore-theme-index.
foreach(resolution 16 22 24 32 48 64 128 256)
install(FILES "images/appicon-${resolution}x${resolution}.png" DESTINATION "${CMAKE_INSTALL_DATADIR}/icons/hicolor/${resolution}x${resolution}/apps" RENAME "gpsbabelfe.png")
endforeach()
else()
message(WARNING "\"cmake --install\" not supported. The file gpsbabel.html is expected to be installed in the same directory as gpsbablefe. The gpsbable(fe) translations are expected to be in the translations sub-directory of the directory that gpsbabelfe is installed in. This is problematic with GNU Coding Standards. Use GPSBABLE_EMBED_MAP and GPSBABEL_EMBED_TRANSLATIONS.")
endif()
endif()
9 changes: 9 additions & 0 deletions gui/genpngs.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash -e
commondims=(16 22 24 32 48 64 128 256)
for dim in "${commondims[@]}"
do
dims=${dim}x${dim}
mkdir -p "images/hicolor/${dims}/apps"
cp images/appicon.png "images/appicon-${dims}.png"
mogrify -resize "${dims}>" -background none -gravity center -extent "${dims}" "images/appicon-${dims}.png"
done
2 changes: 1 addition & 1 deletion gui/gpsbabel.desktop → gui/gpsbabelfe.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Type=Application
Name=GPSBabel
Comment=Qt GUI interface for GPSBabel
GenericName=GPSBabel
Icon=gpsbabel
Icon=gpsbabelfe
Exec=gpsbabelfe
Terminal=false
Categories=Geography;Education;Utility;
Binary file added gui/images/appicon-128x128.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-22x22.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-24x24.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-256x256.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-48x48.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gui/images/appicon-64x64.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed snap/gui/gpsbabel.png
Binary file not shown.
2 changes: 1 addition & 1 deletion snap/gui/gpsbabel.desktop → snap/gui/gpsbabelfe.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Type=Application
Name=GPSBabel
Comment=Qt GUI interface for GPSBabel
GenericName=GPSBabel
Icon=${SNAP}/meta/gui/gpsbabel.png
Icon=${SNAP}/meta/gui/gpsbabelfe.png
Exec=gpsbabel.gpsbabelfe
Terminal=false
Categories=Geography;Education;Utility;
Binary file added snap/gui/gpsbabelfe.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading