diff options
author | Michael Stahl <Michael.Stahl@cib.de> | 2019-07-30 13:40:52 +0200 |
---|---|---|
committer | Michael Stahl <Michael.Stahl@cib.de> | 2019-07-31 16:51:30 +0200 |
commit | b3f72cd239e5a9d7f863bded46d6fc902a4c570c (patch) | |
tree | a8357457bbe9e4e5e83f97e82a8a32a742fada38 | |
parent | e9d6950387a6e41f8f7b7d91921a2686defe136b (diff) |
sysui: fix rpm errors in freedesktop-menus (4.14.1)
RPM build errors:
Explicit %attr() mode not applicable to symlink: /workdir/CustomTarget/sysui/rpm/libreofficedev/freedesktop/usr/bin/libreofficedev6.1
Installed (but unpackaged) file(s) found:
/usr/local/lib/girepository-1.0/LOKDocView-0.1.typelib
/usr/share/gir-1.0/LOKDocView-0.1.gir
The LOKDocView problem turned out to be the result of the first
incremental build after adding --with-package-format, and previously it
was avoided with a if in configure; moving the commands out of
create_tree.sh should be more obvious and reliable though.
Change-Id: I69c1566e26eeaa1d8bf88a3650a78da6ddfb5a3b
Reviewed-on: https://gerrit.libreoffice.org/76596
Tested-by: Jenkins
Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
(cherry picked from commit 634844354ee6ed884128086a80c3ee32c889d8c9)
-rw-r--r-- | configure.ac | 5 | ||||
-rw-r--r-- | sysui/CustomTarget_share.mk | 27 | ||||
-rwxr-xr-x | sysui/desktop/freedesktop/freedesktop-menus.spec | 2 | ||||
-rwxr-xr-x | sysui/desktop/share/create_tree.sh | 15 |
4 files changed, 29 insertions, 20 deletions
diff --git a/configure.ac b/configure.ac index b2a074b5bc8e..7ebdc176ed9c 100644 --- a/configure.ac +++ b/configure.ac @@ -9984,10 +9984,7 @@ if test "x$enable_gtk3" = "xyes"; then PKG_CHECK_MODULES(GTK3, gtk+-3.0 >= 3.18 gtk+-unix-print-3.0 gmodule-no-export-2.0 glib-2.0 >= 2.38 cairo, ENABLE_GTK3="TRUE", ENABLE_GTK3="") if test "x$ENABLE_GTK3" = "xTRUE"; then R="gtk3" - dnl Avoid installed by unpackaged files for now. - if test -z "$PKGFORMAT"; then - GOBJECT_INTROSPECTION_CHECK(INTROSPECTION_REQUIRED_VERSION) - fi + GOBJECT_INTROSPECTION_CHECK(INTROSPECTION_REQUIRED_VERSION) else AC_MSG_ERROR([gtk3 or dependent libraries of the correct versions, not found]) fi diff --git a/sysui/CustomTarget_share.mk b/sysui/CustomTarget_share.mk index d4f24b5f8e60..9f5e37139fd7 100644 --- a/sysui/CustomTarget_share.mk +++ b/sysui/CustomTarget_share.mk @@ -129,6 +129,9 @@ $(eval $(call gb_CustomTarget_register_targets,sysui/share,\ $(product)/openoffice.keys \ $(product)/openoffice.sh \ $(product)/create_tree.sh \ + $(if $(INTROSPECTION_SCANNER),\ + $(product)/LOKDocView-0.1.gir \ + $(product)/LOKDocView-0.1.typelib) \ $(product)/launcherlist) \ )) @@ -173,6 +176,30 @@ $(share_WORKDIR)/%/create_tree.sh: $(share_SRCDIR)/share/create_tree.sh \ cat $< >> $@ chmod 774 $@ +# Generate gobject-introspection files +# These are *not* packaged in rpms because there's no good place to put them +# where the system will actually find them and where it won't conflict with a +# distro packaged LO; on Fedora 30 at least there's no /opt path in +# $XDG_DATA_DIRS +ifneq ($(INTROSPECTION_SCANNER),) + +$(share_WORKDIR)/%/LOKDocView-0.1.gir: \ + $(call gb_Library_get_target,libreofficekitgtk) + mkdir -p $(dir $@) + g-ir-scanner "${SRCDIR}/include/LibreOfficeKit/LibreOfficeKitGtk.h" \ + "${SRCDIR}/libreofficekit/source/gtk/lokdocview.cxx" \ + `${PKG_CONFIG} --cflags gobject-introspection-1.0 gtk+-3.0` \ + -I"${SRCDIR}/include/" \ + --include=GLib-2.0 --include=GObject-2.0 --include=Gio-2.0 \ + --library=libreofficekitgtk --library-path="${INSTDIR}/program" \ + --include=Gdk-3.0 --include=GdkPixbuf-2.0 --include=Gtk-3.0 \ + --namespace=LOKDocView --nsversion=0.1 --identifier-prefix=LOKDoc --symbol-prefix=lok_doc \ + --output="$@" --warn-all --no-libtool + +$(share_WORKDIR)/%/LOKDocView-0.1.typelib: $(share_WORKDIR)/%/LOKDocView-0.1.gir + g-ir-compiler "$<" --output="$@" + +endif $(share_WORKDIR)/%/launcherlist: $(LAUNCHERS) mkdir -p $(dir $@) diff --git a/sysui/desktop/freedesktop/freedesktop-menus.spec b/sysui/desktop/freedesktop/freedesktop-menus.spec index 6d05b2e0d2a8..fdeea00a5d54 100755 --- a/sysui/desktop/freedesktop/freedesktop-menus.spec +++ b/sysui/desktop/freedesktop/freedesktop-menus.spec @@ -391,7 +391,7 @@ done # compat symlinks %attr(0755,root,root) /opt/%unixfilename %endif -%attr(0755, root, root) /usr/bin/* +/usr/bin/* /usr/share/applications/%unixfilename-base.desktop /usr/share/applications/%unixfilename-calc.desktop /usr/share/applications/%unixfilename-draw.desktop diff --git a/sysui/desktop/share/create_tree.sh b/sysui/desktop/share/create_tree.sh index f146242d3796..0ade96cdb4c0 100755 --- a/sysui/desktop/share/create_tree.sh +++ b/sysui/desktop/share/create_tree.sh @@ -83,18 +83,3 @@ for i in base calc draw impress writer; do done cp "${APPDATA_SOURCE_DIR}/org.libreoffice.kde.metainfo.xml" "${DESTDIR}/${PREFIXDIR}/share/appdata/org.${PREFIX}.kde.metainfo.xml" -# Generate gobject-introspection files -if [ -n "$INTROSPECTION_SCANNER" ]; then - mkdir -p "${DESTDIR}/${PREFIXDIR}/share/gir-1.0" - g-ir-scanner "${SRCDIR}/include/LibreOfficeKit/LibreOfficeKitGtk.h" "${SRCDIR}/libreofficekit/source/gtk/lokdocview.cxx" \ - `${PKG_CONFIG} --cflags gobject-introspection-1.0 gtk+-3.0` -I"${SRCDIR}/include/" \ - --include=GLib-2.0 --include=GObject-2.0 --include=Gio-2.0 \ - --library=libreofficekitgtk --library-path="${INSTDIR}/program" \ - --include=Gdk-3.0 --include=GdkPixbuf-2.0 --include=Gtk-3.0 \ - --namespace=LOKDocView --nsversion=0.1 --identifier-prefix=LOKDoc --symbol-prefix=lok_doc \ - --output="${DESTDIR}/${PREFIXDIR}/share/gir-1.0/LOKDocView-0.1.gir" --warn-all --no-libtool - - mkdir -p "${DESTDIR}/${LIBDIR}/girepository-1.0" - g-ir-compiler "${DESTDIR}/${PREFIXDIR}/share/gir-1.0/LOKDocView-0.1.gir" \ - --output="${DESTDIR}/${LIBDIR}/girepository-1.0/LOKDocView-0.1.typelib" -fi |