- qwt-6.0.1
- add pkgconfig support
epel9
Rex Dieter 12 years ago
parent f564df3bae
commit e78b4a724d

1
.gitignore vendored

@ -1,2 +1,3 @@
/qwt-5.2.1.tar.bz2
/qwt-5.2.2.tar.bz2
/qwt-6.0.1.tar.bz2

@ -1,65 +0,0 @@
diff -up qwt-5.2.2/qwtconfig.pri.install_qt qwt-5.2.2/qwtconfig.pri
--- qwt-5.2.2/qwtconfig.pri.install_qt 2011-08-01 04:28:22.000000000 -0500
+++ qwt-5.2.2/qwtconfig.pri 2012-08-03 09:02:20.518891316 -0500
@@ -7,10 +7,14 @@ VER_MIN = 2
VER_PAT = 2
VERSION = $${VER_MAJ}.$${VER_MIN}.$${VER_PAT}
+CONFIG(install-qt) {
+target.path = $$[QT_INSTALL_LIBS]
+headers.path = $$[QT_INSTALL_HEADERS]/qwt
+doc.path = $$[QT_INSTALL_DOCS]
+} else {
unix {
INSTALLBASE = /usr/local/qwt-$$VERSION
}
-
win32 {
INSTALLBASE = C:/Qwt-$$VERSION
}
@@ -18,6 +22,7 @@ win32 {
target.path = $$INSTALLBASE/lib
headers.path = $$INSTALLBASE/include
doc.path = $$INSTALLBASE/doc
+}
######################################################################
# qmake internal options
diff -up qwt-5.2.2/src/src.pro.install_qt qwt-5.2.2/src/src.pro
--- qwt-5.2.2/src/src.pro.install_qt 2011-08-01 04:28:22.000000000 -0500
+++ qwt-5.2.2/src/src.pro 2012-08-03 09:02:41.250632133 -0500
@@ -219,10 +219,29 @@ contains(CONFIG, QwtWidgets) {
# Install directives
+# pkgconfig support
+#target.path = $$[QT_INSTALL_LIBS]
+CONFIG += create_pc create_prl no_install_prl
+QMAKE_PKGCONFIG_NAME = qwt5-qt4
+QMAKE_PKGCONFIG_DESCRIPTION = Qt Widgets for Technical Applications
+QMAKE_PKGCONFIG_LIBDIR = $$[QT_INSTALL_LIBS]
+QMAKE_PKGCONFIG_INCDIR = $$[QT_INSTALL_HEADERS]/qwt
+QMAKE_PKGCONFIG_CFLAGS = -I$$[QT_INSTALL_HEADERS]
+QMAKE_PKGCONFIG_REQUIRES = QtGui QtSvg
+QMAKE_PKGCONFIG_DESTDIR = pkgconfig
+
headers.files = $$HEADERS
-doc.files = $${QWT_ROOT}/doc/html $${QWT_ROOT}/doc/qwt-5.2.0.qch
-unix {
- doc.files += $${QWT_ROOT}/doc/man
-}
+INSTALLS += target headers
+
+html.files = $${QWT_ROOT}/doc/html
+html.path = $$[QT_INSTALL_DOCS]/html/
+INSTALLS += html
+
+qch.files = $${QWT_ROOT}/doc/qwt-5.2.0.qch
+qch.path = $$[QT_INSTALL_DOCS]/qch
+INSTALLS += qch
+
+unix:man.files += $${QWT_ROOT}/doc/man
+unix:man.path = /usr/share
+unix:INSTALLS += man
-INSTALLS = target headers doc

@ -0,0 +1,56 @@
diff -up qwt-6.0.1/qwtbuild.pri.install-qt qwt-6.0.1/qwtbuild.pri
--- qwt-6.0.1/qwtbuild.pri.install-qt 2011-08-01 09:33:53.000000000 -0500
+++ qwt-6.0.1/qwtbuild.pri 2012-08-14 11:04:38.898276331 -0500
@@ -56,7 +56,7 @@ RCC_DIR = resources
unix {
- exists( $${QMAKE_LIBDIR_QT}/libqwt.* ) {
+ exists( $${QMAKE_LIBDIR_QT}/libqwt.so ) {
# On some Linux distributions the Qwt libraries are installed
# in the same directory as the Qt libraries. Unfortunately
diff -up qwt-6.0.1/qwtconfig.pri.install-qt qwt-6.0.1/qwtconfig.pri
--- qwt-6.0.1/qwtconfig.pri.install-qt 2011-08-01 09:33:53.000000000 -0500
+++ qwt-6.0.1/qwtconfig.pri 2012-08-14 11:04:38.898276331 -0500
@@ -18,6 +18,13 @@ QWT_VERSION = $${QWT_VER_MAJ}.$${QW
QWT_INSTALL_PREFIX = $$[QT_INSTALL_PREFIX]
+CONFIG(install-qt) {
+QWT_INSTALL_DOCS = $$[QT_INSTALL_DOCS]/html
+QWT_INSTALL_HEADERS = $$[QT_INSTALL_HEADERS]/qwt
+QWT_INSTALL_LIBS = $$[QT_INSTALL_LIBS]
+QWT_INSTALL_PLUGINS = $$[QT_INSTALL_PLUGINS]/designer
+QWT_INSTALL_FEATURES = $$[QMAKE_MKSPECS]/features
+} else {
unix {
QWT_INSTALL_PREFIX = /usr/local/qwt-$$QWT_VERSION
}
@@ -51,6 +58,7 @@ QWT_INSTALL_PLUGINS = $${QWT_INSTALL_P
QWT_INSTALL_FEATURES = $${QWT_INSTALL_PREFIX}/features
# QWT_INSTALL_FEATURES = $${QT_INSTALL_PREFIX}/features
+}
######################################################################
# Build the static/shared libraries.
diff -up qwt-6.0.1/src/src.pro.install-qt qwt-6.0.1/src/src.pro
--- qwt-6.0.1/src/src.pro.install-qt 2011-08-01 09:33:53.000000000 -0500
+++ qwt-6.0.1/src/src.pro 2012-08-14 11:07:38.498031025 -0500
@@ -16,6 +16,15 @@ include( $${QWT_ROOT}/qwtbuild.pri )
TEMPLATE = lib
TARGET = $$qtLibraryTarget(qwt)
+# pkgconfig support
+CONFIG += create_pc create_prl no_install_prl
+QMAKE_PKGCONFIG_NAME = qwt
+QMAKE_PKGCONFIG_DESCRIPTION = Qt Widgets for Technical Applications
+QMAKE_PKGCONFIG_LIBDIR = $${QWT_INSTALL_LIBS}
+QMAKE_PKGCONFIG_INCDIR = $${QWT_INSTALL_HEADERS}
+QMAKE_PKGCONFIG_REQUIRES = QtGui QtSvg
+QMAKE_PKGCONFIG_DESTDIR = pkgconfig
+
DESTDIR = $${QWT_ROOT}/lib
contains(QWT_CONFIG, QwtDll) {

@ -1,27 +1,23 @@
Name: qwt
Summary: Qt Widgets for Technical Applications
Version: 5.2.2
Release: 6%{?dist}
Version: 6.0.1
Release: 1%{?dist}
License: LGPLv2 with exceptions
URL: http://qwt.sourceforge.net
Group: System Environment/Libraries
Source: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.bz2
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
## upstreamable patches
# add install-qt config to use system paths
# needs work to fix the doc install for non install-qt case
Patch50: qwt-5.2.2-install_qt.patch
Patch50: qwt-6.0.1-install_qt.patch
BuildRequires: pkgconfig(QtGui) pkgconfig(QtSvg)
Provides: qwt5-qt4 = %{version}-%{release}
Provides: qwt5-qt4%{_isa} = %{version}-%{release}
%{?_qt4_version:Requires: qt4%{?_isa} >= %{_qt4_version}}
Provides: qwt6 = %{version}-%{release}
Provides: qwt6%{_isa} = %{version}-%{release}
%description
The Qwt library contains GUI Components and utility classes which are primarily
useful for programs with a technical background.
@ -31,17 +27,15 @@ or ranges of type double.
%package devel
Summary: Development files for %{name}
Group: Development/Libraries
Provides: qwt5-qt4-devel = %{version}-%{release}
Provides: qwt5-qt4-devel%{_isa} = %{version}-%{release}
Provides: qwt6-devel = %{version}-%{release}
Provides: qwt6-devel%{_isa} = %{version}-%{release}
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: pkgconfig(QtGui) pkgconfig(QtSvg)
%description devel
%{summary}.
%package doc
Summary: Extra Developer documentation for %{name}
Group: Documentation
Requires: %{name}-devel = %{version}-%{release}
Summary: Developer documentation for %{name}
BuildArch: noarch
%description doc
%{summary}.
@ -51,12 +45,11 @@ BuildArch: noarch
%prep
%setup -q
%patch50 -p1 -b .install_qt
%patch50 -p1 -b .install-qt
%build
%{?_qt4_qmake} \
CONFIG+=QwtSVGItem \
CONFIG+=install-qt
make %{?_smp_mflags}
@ -70,33 +63,29 @@ make install INSTALL_ROOT=$RPM_BUILD_ROOT
mv $RPM_BUILD_ROOT%{_qt4_docdir}/html/html \
$RPM_BUILD_ROOT%{_qt4_docdir}/html/qwt
# hack
mv $RPM_BUILD_ROOT%{_qt4_libdir}/pkgconfig/qwt.pc \
$RPM_BUILD_ROOT%{_qt4_libdir}/pkgconfig/qwt5-qt4.pc
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%clean
rm -rf $RPM_BUILD_ROOT
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root,-)
%doc CHANGES
%doc COPYING
%doc README
%{_qt4_libdir}/libqwt.so.5*
%doc CHANGES README
%{_qt4_libdir}/libqwt.so.6*
%{_qt4_libdir}/libqwtmathml.so.6*
%{?_qt4_plugindir}/designer/libqwt_designer_plugin.so
%files devel
%defattr(-,root,root,-)
%{_mandir}/man3/*
%{_qt4_headerdir}/qwt/
%{_qt4_libdir}/libqwt.so
%{_qt4_libdir}/pkgconfig/qwt5-qt4.pc
%{?_qt4_plugindir}/designer/libqwt_designer_plugin.so
%{_qt4_libdir}/libqwtmathml.so
%{_qt4_libdir}/qt4/mkspecs/features/qwt*
%{_qt4_libdir}/pkgconfig/qwt.pc
%files doc
%defattr(-,root,root,-)
@ -107,6 +96,10 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Tue Aug 14 2012 Rex Dieter <rdieter@fedoraproject.org> - 6.0.1-1
- qwt-6.0.1
- add pkgconfig support
* Fri Aug 03 2012 Rex Dieter <rdieter@fedoraproject.org> 5.2.2-6
- qwt*.pc : +Requires: QtGui QtSvg
@ -117,7 +110,7 @@ rm -rf $RPM_BUILD_ROOT
- Provides: qwt5-qt4(-devel)
- pkgconfig-style deps
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.2.2-3
- * Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.2.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.2.2-2

@ -1 +1 @@
70d77e4008a6cc86763737f0f24726ca qwt-5.2.2.tar.bz2
ace68558eab873e2da7e641179c4ef0c qwt-6.0.1.tar.bz2

Loading…
Cancel
Save