summaryrefslogtreecommitdiffstats
path: root/packaging
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2014-12-31 10:05:28 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-12-31 10:05:28 -0800
commit1169d7dd352428ce2acb139121f98d785e7bd2a0 (patch)
treec0c0a814741af4323241d5011337b01a0f5d977d /packaging
parent38278c9c71b99a368ccda31880d13e47d6acd021 (diff)
downloadsubsurface-1169d7dd352428ce2acb139121f98d785e7bd2a0.tar.gz
Add the current OBS spec file for daily builds
This is simply here for people to look at. It will age immediately and it makes no sense to try to keep it current here as it is maintained in OBS. But I think it might be a useful starting point for others who want to package daily builds of Subsurface. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'packaging')
-rw-r--r--packaging/OBS/subsurfacedaily.spec121
1 files changed, 121 insertions, 0 deletions
diff --git a/packaging/OBS/subsurfacedaily.spec b/packaging/OBS/subsurfacedaily.spec
new file mode 100644
index 000000000..ad6783ed7
--- /dev/null
+++ b/packaging/OBS/subsurfacedaily.spec
@@ -0,0 +1,121 @@
+#
+# spec file for package subsurface
+#
+# Copyright (c) 2014 Dirk Hohndel
+#
+
+%define latestVersion 4.3
+
+
+%define gitVersion 155
+
+
+
+Name: subsurfacedaily
+Version: %latestVersion.%gitVersion
+Release: 0
+License: GPL v2
+Summary: Open source dive log
+Url: http://subsurface-divelog.org
+Group: Productivity/Other
+Source: subsurfacedaily-%latestVersion.%gitVersion.orig.tar.xz
+Conflicts: subsurface
+BuildRequires: desktop-file-utils
+BuildRequires: fdupes
+BuildRequires: gcc-c++
+BuildRequires: make
+BuildRequires: asciidoc
+BuildRequires: autoconf
+BuildRequires: automake
+BuildRequires: libtool
+BuildRequires: cmake
+%if 0%{?suse_version}
+# kde4-filesystem needed for some folders not owned (%{_datadir}/icons/hicolor and others)
+BuildRequires: kde4-filesystem
+%endif
+BuildRequires: libzip-devel
+BuildRequires: libxml2-devel
+BuildRequires: libxslt-devel
+BuildRequires: libgit2-devel
+# for libgit2
+%if 0%{?fedora_version} || 0%{?rhel_version} || 0%{?centos_version}
+BuildRequires: openssl-devel
+BuildRequires: libsqlite3x-devel
+BuildRequires: libusbx-devel
+BuildRequires: qt5-qtbase-devel
+BuildRequires: qt5-qttools-devel
+BuildRequires: qt5-qtwebkit-devel
+BuildRequires: qt5-qtsvg-devel
+BuildRequires: qt5-qtscript-devel
+BuildRequires: qt5-qtdeclarative-devel
+BuildRequires: qt5-qtbase-mysql
+BuildRequires: qt5-qtbase-postgresql
+BuildRequires: qt5-qtbase-ibase
+BuildRequires: qt5-qtbase-odbc
+BuildRequires: qt5-qtbase-tds
+%else
+BuildRequires: update-desktop-files
+BuildRequires: libopenssl-devel
+BuildRequires: sqlite3-devel
+BuildRequires: libusb-1_0-devel
+BuildRequires: libqt5-qtbase-devel
+BuildRequires: libqt5-qtsvg-devel
+BuildRequires: libqt5-linguist-devel
+BuildRequires: libqt5-qttools-devel
+BuildRequires: libQt5WebKit5-devel
+BuildRequires: libQt5WebKitWidgets-devel
+BuildRequires: libqt5-qtscript-devel
+BuildRequires: libqt5-qtdeclarative-devel
+%endif
+BuildRoot: %{_tmppath}/subsurface%{version}-build
+
+%description
+This is the official Subsurface build, including our own custom libdivecomputer and libssrfmarblewidget
+
+%prep
+%setup -q
+
+%build
+(cd libdivecomputer ; autoreconf --install ; ./configure --disable-shared ; make %{?_smp_mflags} )
+(mkdir marble-build ; cd marble-build ; \
+ cmake -DQTONLY=ON -DQT5BUILD=ON \
+ -DBUILD_MARBLE_APPS=OFF -DBUILD_MARBLE_EXAMPLES=OFF \
+ -DBUILD_MARBLE_TESTS=OFF -DBUILD_MARBLE_TOOLS=OFF \
+ -DBUILD_TESTING=OFF -DWITH_DESIGNER_PLUGIN=OFF \
+ -DBUILD_WITH_DBUS=OFF ../marble-source ; \
+ make %{?_smp_mflags} ; \
+ mkdir include ; cd include ; for i in `find ../../marble-source -name \*.h` ; do ln -s -f $i . ; done ; \
+ ln -s -f . marble )
+qmake-qt5 LIBDCDEVEL=./libdivecomputer LIBMARBLEDEVEL=./marble-build SPECIAL_MARBLE_PREFIX=1 subsurface.pro
+make %{?_smp_mflags}
+
+%install
+mkdir -p %{buildroot}/%{_libdir}
+make prefix=%{buildroot}/usr install
+%if 0%{?fedora_version} || 0%{?rhel_version} || 0%{?centos_version}
+desktop-file-install --dir=%{buildroot}/%{_datadir}/applications subsurface.desktop
+%else
+%suse_update_desktop_file -r subsurface Utility DesktopUtility
+%endif
+%fdupes %{buildroot}
+
+%post
+%desktop_database_post
+/sbin/ldconfig
+
+%postun
+%desktop_database_post
+/sbin/ldconfig
+
+%files
+%defattr(-,root,root)
+%doc gpl-2.0.txt README ReleaseNotes/ReleaseNotes.txt
+%{_bindir}/subsurface
+%{_datadir}/applications/subsurface.desktop
+%{_datadir}/icons/hicolor/*/apps/subsurface-icon.*
+%{_datadir}/subsurface/
+%{_mandir}/man1/subsurface.1%{?ext_man}
+/usr/lib*/libssrfmarblewidget.so*
+
+%changelog
+