mirror of
https://git.jami.net/savoirfairelinux/jami-daemon.git
synced 2025-08-07 22:02:12 +08:00
daemon: Use the PROGSHAREDIR macro to refer to the custom datadir.
The sources previously hard-coded the location of the default Jami ringtone as "/usr/share/ring/ringtones/default.opus". It should instead be computed from the already existing PROGSHAREDIR macro, which is built from Autoconf's configurable datadir. * globals.mk (-DPROGSHAREDIR): Rename the 'ring' subdirectory to 'jami'. * meson.build (conf): Likewise. * ringtones/Makefile.am (dist_jamiringtones_DATA): s/ring/jami/g * ringtones/meson.build: Likewise. * src/account.cpp (DEFAULT_RINGTONE_PATH): Define in terms of PROGSHAREDIR. * bin/dbus/Makefile.am (libclient_dbus_la_CXXFLAGS): Remove extraneous flags, already propagated via AM_CPPFLAGS. Honor AM_CXXFLAGS. * src/client/Makefile.am (libclient_la_CXXFLAGS): Remove. * src/plugin/Makefile.am (libplugin_la_CXXFLAGS): Likewise. Change-Id: Icaa0a92e896f86b0bb07f82e4079570db08fafbd
This commit is contained in:

committed by
Adrien Béraud

parent
11a85bde08
commit
f0fb8148ba
@ -58,12 +58,7 @@ if ENABLE_VIDEO
|
||||
libclient_dbus_la_SOURCES += dbusvideomanager.cpp dbusvideomanager.h
|
||||
endif
|
||||
|
||||
libclient_dbus_la_CXXFLAGS = -I../ \
|
||||
-I$(top_srcdir)/src \
|
||||
-I$(top_srcdir)/src/dring \
|
||||
-DPREFIX=\"$(prefix)\" \
|
||||
-DPROGSHAREDIR=\"${datadir}/ring\" \
|
||||
$(DBUSCPP_CFLAGS)
|
||||
libclient_dbus_la_CXXFLAGS = $(AM_CXXFLAGS) $(DBUSCPP_CFLAGS)
|
||||
|
||||
do_subst = $(SED) \
|
||||
-e 's,[@]bindir[@],$(bindir),g'
|
||||
|
@ -17,7 +17,7 @@ AM_CPPFLAGS += \
|
||||
-I$(src)/src/dring \
|
||||
$(SIP_CFLAGS) \
|
||||
-DPREFIX=\"$(prefix)\" \
|
||||
-DPROGSHAREDIR=\"${datadir}/ring\" \
|
||||
-DPROGSHAREDIR=\"$(datadir)/jami\" \
|
||||
-DENABLE_TRACE \
|
||||
-DRING_REVISION=\"$(RING_REVISION)\" \
|
||||
-DRING_DIRTY_REPO=\"$(RING_DIRTY_REPO)\" \
|
||||
|
@ -66,7 +66,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') / 'ring')
|
||||
conf.set_quoted('PROGSHAREDIR', 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())
|
||||
|
@ -1,5 +1,5 @@
|
||||
ringringtonesdir = $(datadir)/ring/ringtones
|
||||
dist_ringringtones_DATA = \
|
||||
jamiringtonesdir = $(datadir)/jami/ringtones
|
||||
dist_jamiringtones_DATA = \
|
||||
01_AfroNigeria.opus \
|
||||
02_AfroNigeria.opus \
|
||||
03_AcousticGuitar.opus \
|
||||
@ -10,4 +10,4 @@ dist_ringringtones_DATA = \
|
||||
08_RingFirefly.opus \
|
||||
09_ElectroCloud.opus \
|
||||
10_UrbanTrap.opus \
|
||||
default.opus
|
||||
default.opus
|
||||
|
@ -10,5 +10,5 @@ install_data(
|
||||
'09_ElectroCloud.opus',
|
||||
'10_UrbanTrap.opus',
|
||||
'default.opus',
|
||||
install_dir: get_option('datadir') / 'ring' / 'ringtones'
|
||||
install_dir: get_option('datadir') / 'jami' / 'ringtones'
|
||||
)
|
||||
|
@ -96,10 +96,10 @@ const char* const Account::LOCAL_MODERATORS_ENABLED_KEY = "localModeratorsEnable
|
||||
const char* const Account::ALL_MODERATORS_ENABLED_KEY = "allModeratorsEnabled";
|
||||
|
||||
#ifdef __ANDROID__
|
||||
constexpr const char* const DEFAULT_RINGTONE_PATH
|
||||
= "/data/data/cx.ring/files/ringtones/default.opus";
|
||||
const char* const DEFAULT_RINGTONE_PATH = "/data/data/cx.ring/files/ringtones/default.opus";
|
||||
#else
|
||||
constexpr const char* const DEFAULT_RINGTONE_PATH = "/usr/share/ring/ringtones/default.opus";
|
||||
const char* const DEFAULT_RINGTONE_PATH = (std::string() + PROGSHAREDIR + "/ringtones/default.opus")
|
||||
.c_str();
|
||||
#endif
|
||||
|
||||
Account::Account(const std::string& accountID)
|
||||
|
@ -25,10 +25,3 @@ libclient_la_SOURCES = \
|
||||
$(PLUGIN_SRC) \
|
||||
$(PRESENCE_SRC) \
|
||||
$(VIDEO_SRC)
|
||||
|
||||
libclient_la_CXXFLAGS = \
|
||||
-I./ \
|
||||
-I../ \
|
||||
-DPREFIX=\"$(prefix)\" \
|
||||
-DPROGSHAREDIR=\"${datadir}/ring\" \
|
||||
$(AM_CXXFLAGS)
|
||||
|
@ -23,10 +23,3 @@ libplugin_la_SOURCES = \
|
||||
pluginsutils.cpp \
|
||||
chatservicesmanager.cpp \
|
||||
callservicesmanager.cpp
|
||||
|
||||
libplugin_la_CXXFLAGS = \
|
||||
-I./ \
|
||||
-I../ \
|
||||
-DPREFIX=\"$(prefix)\" \
|
||||
-DPROGSHAREDIR=\"${datadir}/ring\" \
|
||||
$(AM_CXXFLAGS)
|
||||
|
Reference in New Issue
Block a user