Skip to content

Commit 60e60b9

Browse files
committed
fix: correct CMake config install paths and Audacious path detection
CMakeLists.txt: add install block for extension-less config files (e.g. k3brc) missed by FILES_MATCHING glob; fix servicemenu install destination to KF6 path (share/kio/servicemenus/). bin/musiclib_init_config.sh: expand Audacious path guard from one-liner to if-block with info message; fix SERVICEMENU_SRC to KF6 path (/usr/share/kio/servicemenus/). Bump version to 1.61.
1 parent 1090b28 commit 60e60b9

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

CMakeLists.txt

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
cmake_minimum_required(VERSION 3.21)
2-
project(MusicLib VERSION 1.60 LANGUAGES CXX)
2+
project(MusicLib VERSION 1.61 LANGUAGES CXX)
33

44
set(CMAKE_CXX_STANDARD 20)
55
set(CMAKE_CXX_STANDARD_REQUIRED ON)
@@ -102,6 +102,14 @@ install(DIRECTORY ${CMAKE_SOURCE_DIR}/config/
102102
WORLD_READ
103103
)
104104

105+
# Install extension-less config files not matched by FILES_MATCHING above
106+
install(FILES ${CMAKE_SOURCE_DIR}/config/k3brc
107+
DESTINATION lib/musiclib/config
108+
PERMISSIONS OWNER_READ OWNER_WRITE
109+
GROUP_READ
110+
WORLD_READ
111+
)
112+
105113
# KDE service menu installation (KF6: /usr/share/kio/servicemenus/)
106114
install(FILES ${CMAKE_SOURCE_DIR}/config/servicemenus/musiclib-rate.desktop
107115
DESTINATION share/kio/servicemenus

bin/musiclib_init_config.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,10 @@ if command -v audacious &>/dev/null; then
4141
_aud_config="$HOME/.config/audacious/config"
4242
if [ -f "$_aud_config" ]; then
4343
_aud_path=$(awk '/^\[search-tool\]/{found=1; next} found && /^path=/{sub(/^path=/, ""); print; exit} found && /^\[/{exit}' "$_aud_config")
44-
[ -n "$_aud_path" ] && EXISTING_MUSIC_REPO="$_aud_path"
44+
if [ -n "$_aud_path" ]; then
45+
EXISTING_MUSIC_REPO="$_aud_path"
46+
print_info "Library location found in Audacious settings: $_aud_path"
47+
fi
4548
fi
4649
fi
4750

@@ -1171,7 +1174,7 @@ fi
11711174

11721175
print_header "Dolphin Service Menu"
11731176

1174-
SERVICEMENU_SRC="/usr/lib/musiclib/config/servicemenus/musiclib-rate.desktop"
1177+
SERVICEMENU_SRC="/usr/share/kio/servicemenus/musiclib-rate.desktop"
11751178
SERVICEMENU_DEST_DIR="${XDG_DATA_HOME}/kio/servicemenus"
11761179
SERVICEMENU_DEST="${SERVICEMENU_DEST_DIR}/musiclib-rate.desktop"
11771180

0 commit comments

Comments
 (0)