mirror of
https://github.com/lakinduakash/linux-wifi-hotspot.git
synced 2024-11-21 19:40:11 +00:00
Merge pull request #41 from fabricio-godoi/master
feat(.desktop): include script to create system shortcut
This commit is contained in:
commit
c399af64f9
@ -30,18 +30,24 @@ set (appdir "/usr/share")
|
||||
set (appbin "/usr/bin")
|
||||
|
||||
add_custom_target(install_build
|
||||
# echo "HERE: $(HOME)"
|
||||
COMMAND mkdir -p $ENV{DESTDIR}${appdir}/${PROJECT_NAME}
|
||||
COMMAND mkdir -p $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/glade
|
||||
COMMAND install -Dm755 ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME} $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/${PROJECT_NAME}
|
||||
COMMAND install -Dm755 ${CMAKE_CURRENT_BINARY_DIR}/glade/* $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/glade/
|
||||
COMMAND ln -rs $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/${PROJECT_NAME} $ENV{DESTDIR}${appbin}/${PROJECT_NAME}
|
||||
#COMMAND ${CMAKE_COMMAND} -E create_symlink $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/${PROJECT_NAME} $ENV{DESTDIR}${appbin}/${PROJECT_NAME}
|
||||
COMMAND echo $ENV{DESTDIR}
|
||||
COMMAND install -Dm644 ${CMAKE_SOURCE_DIR}/desktop/hotspot.png $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/hotspot.png
|
||||
COMMAND install -Dm644 ${CMAKE_SOURCE_DIR}/desktop/wifihotspot.desktop $ENV{DESTDIR}${appdir}/${PROJECT_NAME}/${PROJECT_NAME}.desktop
|
||||
COMMAND install -Dm644 ${CMAKE_SOURCE_DIR}/desktop/wifihotspot.desktop $ENV{DESTDIR}${appdir}/applications/${PROJECT_NAME}.desktop
|
||||
DEPENDS ${PROJECT_NAME}
|
||||
COMMENT Installing files...
|
||||
)
|
||||
|
||||
add_custom_target(uninstall_build
|
||||
COMMAND rm -r $ENV{DESTDIR}${appdir}/${PROJECT_NAME}
|
||||
COMMAND rm -rf $ENV{DESTDIR}${appdir}/${PROJECT_NAME}
|
||||
COMMAND rm -f $ENV{DESTDIR}${appbin}/${PROJECT_NAME}
|
||||
COMMAND rm -f $ENV{DESTDIR}${appdir}/applications/${PROJECT_NAME}.desktop
|
||||
COMMENT Unstalling files...
|
||||
)
|
BIN
src/desktop/hotspot.png
Normal file
BIN
src/desktop/hotspot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.8 KiB |
8
src/desktop/wifihotspot.desktop
Normal file
8
src/desktop/wifihotspot.desktop
Normal file
@ -0,0 +1,8 @@
|
||||
[Desktop Entry]
|
||||
Type=Application
|
||||
Name=WifiHotspot
|
||||
Icon=/usr/share/wihotspot/hotspot.png
|
||||
Exec=sh -c 'pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY sudo /usr/bin/wihotspot'
|
||||
Terminal=false
|
||||
Categories=System
|
||||
Keywords=Hotspot;WiFi
|
@ -13,6 +13,7 @@ install:
|
||||
install -Dm644 bash_completion $(DESTDIR)$(PREFIX)/share/bash-completion/completions/create_ap
|
||||
install -Dm644 README.md $(DESTDIR)$(PREFIX)/share/doc/create_ap/README.md
|
||||
|
||||
|
||||
uninstall:
|
||||
rm -f $(DESTDIR)$(BINDIR)/create_ap
|
||||
rm -f $(DESTDIR)/etc/create_ap.conf
|
||||
|
@ -87,3 +87,6 @@ Using the persistent [systemd](https://wiki.archlinux.org/index.php/systemd#Basi
|
||||
FreeBSD
|
||||
- Copyright (c) 2013, oblique
|
||||
- Copyright (c) 2019, lakinduakash
|
||||
|
||||
## Disclaimer
|
||||
<div>Icons made by <a href="https://www.flaticon.com/authors/photo3idea-studio" title="photo3idea_studio">photo3idea_studio</a> from <a href="https://www.flaticon.com/" title="Flaticon">www.flaticon.com</a></div>
|
||||
|
Loading…
Reference in New Issue
Block a user