File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -11,6 +11,9 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
1111
1212if (APPLE )
1313 enable_language (OBJCXX )
14+ if (NOT CMAKE_OSX_DEPLOYMENT_TARGET)
15+ set (CMAKE_OSX_DEPLOYMENT_TARGET "10.15" CACHE STRING "Minimum macOS deployment target" )
16+ endif ()
1417endif ()
1518
1619set (CMAKE_AUTOMOC ON )
@@ -24,7 +27,6 @@ find_package(Qt6Network 6.7 REQUIRED)
2427find_package (Qt6OpenGL 6.7 REQUIRED )
2528find_package (Qt6QuickWidgets 6.7 REQUIRED )
2629find_package (Qt6Svg 6.7 REQUIRED )
27- find_package (Qt6Multimedia 6.7 REQUIRED )
2830find_package (Qt6TextToSpeech 6.7 REQUIRED )
2931find_package (Qt6OpenGLWidgets 6.7 REQUIRED )
3032
Original file line number Diff line number Diff line change 1717
1818required_formulae=(cmake mupdf qtspeech)
1919cmake_prefixes=()
20- for formula in qtbase qtdeclarative qtsvg qtmultimedia qtspeech mupdf; do
20+ for formula in qtbase qtdeclarative qtsvg qtspeech mupdf; do
2121 prefix=$( brew --prefix " $formula " 2> /dev/null || true)
2222 if [[ -z $prefix || ! -d $prefix ]]; then
2323 echo " Missing Homebrew formula '$formula '. Install dependencies with:" >&2
Original file line number Diff line number Diff line change @@ -230,11 +230,6 @@ void configure_paths() {
230230#ifdef Q_OS_MACOS
231231 app_data_path = parent_path.slash (L" .." ).slash (L" Resources" );
232232 shader_path = app_data_path.slash (L" shaders" );
233-
234- Path mac_home_path (QDir::homePath ().toStdWString ());
235- Path mac_standard_config_path = mac_home_path.slash (L" .config" ).slash (L" sioyek" );
236- user_keys_paths.push_back (mac_standard_config_path.slash (L" keys_user.config" ));
237- user_config_paths.push_back (mac_standard_config_path.slash (L" prefs_user.config" ));
238233#else
239234 shader_path = parent_path.slash (L" shaders" );
240235#endif
@@ -322,6 +317,14 @@ void configure_paths() {
322317 local_database_file_path = standard_data_path.slash (L" local.db" );
323318 global_database_file_path = standard_data_path.slash (L" shared.db" );
324319 last_opened_file_address_path = standard_data_path.slash (L" last_document_path.txt" );
320+ #ifdef Q_OS_MACOS
321+ // XDG-style ~/.config path is pushed last so it is the preferred write location (back())
322+ // while AppDataLocation paths above serve as read-only fallbacks
323+ Path mac_home_path (QDir::homePath ().toStdWString ());
324+ Path mac_standard_config_path = mac_home_path.slash (L" .config" ).slash (L" sioyek" );
325+ user_keys_paths.push_back (mac_standard_config_path.slash (L" keys_user.config" ));
326+ user_config_paths.push_back (mac_standard_config_path.slash (L" prefs_user.config" ));
327+ #endif
325328#else
326329 user_config_paths.push_back (parent_path.slash (L" prefs_user.config" ));
327330 user_keys_paths.push_back (parent_path.slash (L" keys_user.config" ));
You can’t perform that action at this time.
0 commit comments