Skip to content
Permalink
Browse files

Roughly adapt packaging to the changes in the previous commit

  • Loading branch information
aleixpol authored and nyalldawson committed Jun 20, 2018
1 parent 618c3ce commit f1d226f5cb68b1faab63f0bc4b99c0dc3069ac40
Showing with 2 additions and 73 deletions.
  1. +1 −1 debian/qgis.install
  2. +0 −35 debian/rules
  3. +1 −37 rpm/qgis.spec.template
@@ -5,7 +5,7 @@ usr/lib/qgis/plugins/libevis.so
usr/lib/qgis/plugins/libofflineeditingplugin.so
usr/lib/qgis/plugins/libtopolplugin.so
usr/lib/qgis/plugins/libgeometrycheckerplugin.so
usr/share/pixmaps/
usr/share/applications/
usr/share/metainfo/
usr/share/mime/packages/
usr/share/icons/hicolor/
@@ -288,41 +288,6 @@ override_dh_auto_install:
# Don't ship srs.db, automatically updated in postinst with crssync
mv $(CURDIR)/debian/tmp/usr/share/qgis/resources/srs.db $(CURDIR)/debian/tmp/usr/share/qgis/resources/srs-template.db

# Install menu pixmap
install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/pixmaps
install -o root -g root -m 644 $(CURDIR)/images/icons/qgis_icon.svg $(CURDIR)/debian/tmp/usr/share/pixmaps/qgis.svg
install -o root -g root -m 644 $(CURDIR)/images/icons/qgis-icon-512x512.png $(CURDIR)/debian/tmp/usr/share/pixmaps/qgis.png
install -o root -g root -m 644 $(CURDIR)/images/icons/qgis-mime-icon.png $(CURDIR)/debian/tmp/usr/share/pixmaps/qgis-mime.png

# Install MIME type icon
for size in 8x8 16x16 22x22 24x24 32x32 36x36 42x42 48x48 64x64 72x72 80x80 96x96 128x128; do \
install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/icons/hicolor/$${size}/mimetypes ; \
install -o root -g root -m 644 $(CURDIR)/debian/icons/qgis-mime-icon$${size}.png $(CURDIR)/debian/tmp/usr/share/icons/hicolor/$${size}/mimetypes/qgis-mime.png ; \
done

# Install QGIS file formats icons
for file_type in qgs qlr qml qpt; do \
for size in 8x8 16x16 22x22 24x24 32x32 36x36 42x42 48x48 64x64 72x72 80x80 96x96 128x128 192x192 256x256 512x512; do \
install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/icons/hicolor/$${size}/mimetypes ; \
install -o root -g root -m 644 \
$(CURDIR)/debian/icons/qgis-$${file_type}$${size}.png \
$(CURDIR)/debian/tmp/usr/share/icons/hicolor/$${size}/mimetypes/qgis-$${file_type}.png ; \
done ; \
done

# Install application icon
for size in 8x8 16x16 22x22 24x24 32x32 36x36 42x42 48x48 64x64 72x72 80x80 96x96 128x128 192x192 256x256 512x512; do \
install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/icons/hicolor/$${size}/apps ; \
install -o root -g root -m 644 $(CURDIR)/debian/icons/qgis-icon$${size}.png $(CURDIR)/debian/tmp/usr/share/icons/hicolor/$${size}/apps/qgis.png ; \
done

install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/icons/hicolor/scalable/apps
install -o root -g root -m 644 $(CURDIR)/images/icons/qgis_icon.svg $(CURDIR)/debian/tmp/usr/share/icons/hicolor/scalable/apps/qgis.svg

# Install desktop files
install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/applications
install -o root -g root -m 644 $(CURDIR)/debian/qgis.desktop $(CURDIR)/debian/tmp/usr/share/applications

# Mime info
install -o root -g root -d $(CURDIR)/debian/tmp/usr/share/mime/packages
install -o root -g root -m 644 $(CURDIR)/debian/qgis.xml $(CURDIR)/debian/tmp/usr/share/mime/packages
@@ -8,7 +8,7 @@

# Force the python interpreter to python3:
# brp-python-bytecompile is unable to identify
# the proper required version of python for
# the proper required version of python for
# py files located under /usr/share/qgis/python/plugins
%global __python %{__python3}

@@ -219,46 +219,11 @@ make %{?_smp_mflags}
#export LD_LIBRARY_PATH=%{_builddir}%{name}-%{version}/output/%{_lib}
make install DESTDIR=%{buildroot}

# Install desktop file without connecting proprietary file types
desktop-file-install \
--vendor="fedora" \
--remove-mime-type="application/x-raster-ecw" \
--remove-mime-type="application/x-raster-mrsid" \
--dir=%{buildroot}%{_datadir}/applications \
debian/qgis.desktop

# Install MIME type definitions
install -d %{buildroot}%{_datadir}/mime/packages
install -pm0644 %{SOURCE5} \
%{buildroot}%{_datadir}/mime/packages/%{name}.xml

# Install application and MIME icons
for size in 8x8 16x16 22x22 24x24 32x32 36x36 42x42 48x48 64x64 72x72 80x80 96x96 128x128 192x192 256x256 512x512; do
install -pd %{buildroot}%{_datadir}/icons/hicolor/$size/apps
install -pm0644 debian/icons/%{name}-icon${size}.png %{buildroot}%{_datadir}/icons/hicolor/${size}/apps/%{name}.png
done

for ext in qgs qlr qml qpt; do
for size in 8x8 16x16 22x22 24x24 32x32 36x36 42x42 48x48 64x64 72x72 80x80 96x96 128x128 192x192 256x256 512x512; do
install -pd %{buildroot}%{_datadir}/icons/hicolor/$size/apps
install -pm0644 debian/icons/%{name}-${ext}${size}.png %{buildroot}%{_datadir}/icons/hicolor/${size}/apps/%{name}-${ext}.png
done
done

for size in 8x8 16x16 22x22 24x24 32x32 36x36 42x42 48x48 64x64 72x72 80x80 96x96 128x128 192x192 256x256 512x512; do
install -pd %{buildroot}%{_datadir}/icons/hicolor/$size/mimetypes
install -pm0644 debian/icons/qgis-mime-icon${size}.png %{buildroot}%{_datadir}/icons/hicolor/${size}/mimetypes/qgis-mime.png
done

install -pd %{buildroot}%{_datadir}/pixmaps
install -pd %{buildroot}%{_datadir}/icons/hicolor/scalable/apps

install -pm0644 images/icons/%{name}-icon-512x512.png %{buildroot}%{_datadir}/pixmaps/%{name}.png
install -pm0644 images/icons/%{name}_icon.svg %{buildroot}%{_datadir}/pixmaps/%{name}.svg
install -pm0644 images/icons/%{name}_icon.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
install -pm0644 images/icons/%{name}-mime-icon.png %{buildroot}%{_datadir}/pixmaps/%{name}-mime.png
install -pm0644 images/icons/%{name}_mime_icon.svg %{buildroot}%{_datadir}/pixmaps/%{name}-mime.png

# Install basic QGIS Mapserver configuration for Apache
install -pd %{buildroot}%{_sysconfdir}/httpd/conf.d
install -pm0644 %{SOURCE2} \
@@ -320,7 +285,6 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
%dir %{_datadir}/%{name}/
%{_datadir}/mime/packages/qgis.xml
%{_datadir}/metainfo/org.qgis.qgis.appdata.xml
%{_datadir}/pixmaps/
%{_datadir}/icons/hicolor/*/apps/*
%{_datadir}/icons/hicolor/*/mimetypes/*
%{_datadir}/applications/*%{name}.desktop

0 comments on commit f1d226f

Please sign in to comment.
You can’t perform that action at this time.