From 848ba26243e5e1773bc06132635a911d42756a97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Sat, 7 Dec 2013 18:50:49 +0100 Subject: Fix plugins install directory This resolves Bug 1151 --- configure.in.in | 18 ++++++++++++++++++ kmymoney2/widgets/Makefile.am | 8 ++++---- 2 files changed, 22 insertions(+), 4 deletions(-) diff --git a/configure.in.in b/configure.in.in index a90f40f..b116f30 100644 --- a/configure.in.in +++ b/configure.in.in @@ -77,6 +77,24 @@ if test "x$X" = "x"; then fi UIC=`echo $UIC -L \$\(top_builddir\)/kmymoney2/widgets/.libs` +# +# get qt plugins directory +# + +if test "$PKG_CONFIG" != "no" ; then + if $PKG_CONFIG --exists qt-mt ; then + qt_plugins_dir="`pkg-config --variable=pluginsdir qt-mt`" + else + if $PKG_CONFIG --exists tqt-mt ; then + qt_plugins_dir="`pkg-config --variable=pluginsdir tqt-mt`" + fi + fi +fi +if test "x$qt_plugins_dir" = "x"; then + qt_plugins_dir=$(qt_libraries)/../plugins +fi +AC_SUBST(qt_plugins_dir) + # # create header directory, make symlinks # diff --git a/kmymoney2/widgets/Makefile.am b/kmymoney2/widgets/Makefile.am index 6879430..76cd1c7 100644 --- a/kmymoney2/widgets/Makefile.am +++ b/kmymoney2/widgets/Makefile.am @@ -68,19 +68,19 @@ kmmwidgets.cpp: $(srcdir)/kmymoney.widgets # Hence the quick hack to include the required objects from the # libkmm_mymoney.so directly into libkmymoney.so libkmymoney_la_CXXFLAGS = -U_CHECK_MEMORY -DKMM_DESIGNER -libkmymoney_la_LDFLAGS = `ls ../mymoney/*.lo` $(KDE_LDFLAGS) $(QT_LDFLAGS) $(X_LDFLAGS) -rpath $(DESTDIR)$(qt_libraries)/../plugins/designer $(LIB_TDEUI) $(LIB_TDECORE) $(LIB_QT) +libkmymoney_la_LDFLAGS = `ls ../mymoney/*.lo` $(KDE_LDFLAGS) $(QT_LDFLAGS) $(X_LDFLAGS) -rpath $(DESTDIR)$(qt_plugins_dir)/designer $(LIB_TDEUI) $(LIB_TDECORE) $(LIB_QT) if INSTALL_QTDESIGNER_SUPPORT install-exec-local: libkmymoney.la - $(mkinstalldirs) $(DESTDIR)$(qt_libraries)/../plugins/designer - $(INSTALL_PROGRAM) .libs/libkmymoney.so $(DESTDIR)$(qt_libraries)/../plugins/designer + $(mkinstalldirs) $(DESTDIR)$(qt_plugins_dir)/designer + $(INSTALL_PROGRAM) .libs/libkmymoney.so $(DESTDIR)$(qt_plugins_dir)/designer $(mkinstalldirs) $(DESTDIR)$(kde_datadir)/$(PICS_DIR) for file in $(WIDGET_PNGS); do \ $(INSTALL_DATA) $(abs_srcdir)/$$file $(DESTDIR)$(kde_datadir)/$(PICS_DIR); \ done uninstall-local: - -rm $(DESTDIR)$(qt_libraries)/../plugins/designer/libkmymoney.so + -rm $(DESTDIR)$(qt_plugins_dir)/designer/libkmymoney.so for file in $(WIDGET_PNGS); do \ rm -rf $(DESTDIR)$(kde_datadir)/$(PICS_DIR)/$$file; \ done -- cgit v1.2.1