diff --git a/compat/msvc/config.h b/compat/msvc/config.h index fafffeb72a849437b1f11c75553f321199e9a669..5e31cb7dee18d59ebd73f34f59185968ef3367ce 100644 --- a/compat/msvc/config.h +++ b/compat/msvc/config.h @@ -201,7 +201,7 @@ STACK_DIRECTION = 0 => direction of growth unknown */ #define VERSION "10.0.2" // UWP compatibility -#define PROGSHAREDIR "" +#define JAMI_DATADIR "" /* Define to limit the scope of <windows.h>. */ /* #undef WIN32_LEAN_AND_MEAN */ diff --git a/globals.mk b/globals.mk index 579c0232fef9cbbcf36b5f26d1659ec55bdde963..c159792d8c143ed434f625d25e08c81ffd83c547 100644 --- a/globals.mk +++ b/globals.mk @@ -17,7 +17,7 @@ AM_CPPFLAGS += \ -I$(src)/src/jami \ $(SIP_CFLAGS) \ -DPREFIX=\"$(prefix)\" \ - -DPROGSHAREDIR=\"$(datadir)/jami\" \ + -DJAMI_DATADIR=\"$(datadir)/jami\" \ -DENABLE_TRACE \ -DRING_REVISION=\"$(RING_REVISION)\" \ -DRING_DIRTY_REPO=\"$(RING_DIRTY_REPO)\" \ diff --git a/meson.build b/meson.build index 8b74963f7b109a5d9bbfbae9b2198b52cb2e6ee4..a2ac3f60217f151f0ea3af51c427a68df4961e83 100644 --- a/meson.build +++ b/meson.build @@ -72,7 +72,7 @@ conf.set_quoted('PACKAGE', 'jami') conf.set_quoted('PACKAGE_NAME', 'Jami Daemon') conf.set_quoted('PACKAGE_VERSION', meson.project_version()) conf.set_quoted('PACKAGE_STRING', 'Jami Daemon ' + meson.project_version()) -conf.set_quoted('PROGSHAREDIR', get_option('datadir') / 'jami') +conf.set_quoted('JAMI_DATADIR', get_option('datadir') / 'jami') depopensl = meson.get_compiler('cpp').find_library('OpenSLES', has_headers: 'SLES/OpenSLES.h', required: get_option('opensl')) conf.set10('HAVE_OPENSL', depopensl.found()) diff --git a/src/account.cpp b/src/account.cpp index f24d1f1bc008f91731d7cc9cb5fb6b3c28298869..f28adbab11443230addba9f180211c108466f06e 100644 --- a/src/account.cpp +++ b/src/account.cpp @@ -101,7 +101,7 @@ const char* const Account::PROXY_PUSH_TOKEN_KEY = "proxyPushToken"; constexpr const char* const DEFAULT_RINGTONE_PATH = "/data/data/cx.ring/files/ringtones/default.opus"; #else -constexpr const char* const DEFAULT_RINGTONE_PATH = PROGSHAREDIR "/ringtones/default.opus"; +constexpr const char* const DEFAULT_RINGTONE_PATH = JAMI_DATADIR "/ringtones/default.opus"; #endif Account::Account(const std::string& accountID) diff --git a/src/manager.cpp b/src/manager.cpp index 7af53b049db91f206cda051fab0550068074c220..37cd51399c29fcc5b97258ef4659ff7a7bbc54a4 100644 --- a/src/manager.cpp +++ b/src/manager.cpp @@ -2091,7 +2091,7 @@ Manager::playRingtone(const std::string& accountID) if (ringchoice.find(DIR_SEPARATOR_CH) == std::string::npos) { // check inside global share directory static const char* const RINGDIR = "ringtones"; - ringchoice = std::string(PROGSHAREDIR) + DIR_SEPARATOR_STR + RINGDIR + DIR_SEPARATOR_STR + ringchoice = std::string(JAMI_DATADIR) + DIR_SEPARATOR_STR + RINGDIR + DIR_SEPARATOR_STR + ringchoice; } #endif