forked from pool/wxWidgets-3_2
Accepting request 827955 from home:StefanBruens:branches:X11:wxWidgets
- Use _multibuild to avoid changes and spec files of the variants getting out of sync. OBS-URL: https://build.opensuse.org/request/show/827955 OBS-URL: https://build.opensuse.org/package/show/X11:wxWidgets/wxWidgets-3_2?expand=0&rev=68
This commit is contained in:
@@ -16,10 +16,53 @@
|
||||
#
|
||||
|
||||
|
||||
Name: wxWidgets-3_2
|
||||
%global flavor @BUILD_FLAVOR@%{nil}
|
||||
%if "%{flavor}" == ""
|
||||
ExclusiveArch: do_not_build
|
||||
%endif
|
||||
|
||||
%if "%{flavor}" == "GTK2"
|
||||
%define pkgname wxWidgets-3_2
|
||||
%define variant suse
|
||||
%define gtk_version 2
|
||||
%define toolkit gtk%gtk_version
|
||||
%define base_packages 0
|
||||
%bcond_with webview
|
||||
%endif
|
||||
|
||||
%if "%{flavor}" == "GTK3"
|
||||
%define pkgname wxGTK3-3_2
|
||||
%define variant suse
|
||||
%define gtk_version 3
|
||||
%define toolkit gtk%gtk_version
|
||||
# build non-UI toolkit related packages
|
||||
%define base_packages 1
|
||||
%bcond_without webview
|
||||
%endif
|
||||
|
||||
%if "%{flavor}" == "GTK3-nostl"
|
||||
%define pkgname wxWidgets-3_2-nostl
|
||||
%define variant suse-nostl
|
||||
%define gtk_version 3
|
||||
%define toolkit gtk%gtk_version
|
||||
%define base_packages 1
|
||||
%bcond_with webview
|
||||
%define extra_description This variant of wxWidgets is built without STL types (such as \
|
||||
std::string), and is provided for old programs which fail to use e.g. \
|
||||
wxString and instead rely on the wxChar pointer API.
|
||||
%endif
|
||||
|
||||
%if "%{flavor}" == "Qt"
|
||||
%define pkgname wxWidgets-3_2
|
||||
%define variant suse
|
||||
%define toolkit qt
|
||||
%define base_packages 0
|
||||
%bcond_with webview
|
||||
%endif
|
||||
|
||||
Name: %{pkgname}
|
||||
%define base_name wxWidgets-3_2
|
||||
%define tarball_name wxWidgets
|
||||
%define variant suse
|
||||
# Use default debug level, enabling exceptions
|
||||
# Other valid values: yes/no/max
|
||||
%define wx_debug %{nil}
|
||||
@@ -29,8 +72,6 @@ Version: 3.1.4
|
||||
Release: 0
|
||||
%define wx_minor 3.1
|
||||
%define wx_micro 3.1.4
|
||||
# build non-UI toolkit related packages
|
||||
%define base_packages 0
|
||||
Summary: C++ Library for Cross-Platform Development
|
||||
License: LGPL-2.1-or-later WITH WxWindows-exception-3.1
|
||||
Group: Development/Libraries/C and C++
|
||||
@@ -45,12 +86,8 @@ Patch1: soversion.diff
|
||||
BuildRequires: autoconf
|
||||
BuildRequires: cppunit-devel
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: gnome-vfs2-devel
|
||||
BuildRequires: gstreamer-devel
|
||||
BuildRequires: gstreamer-plugins-base-devel
|
||||
BuildRequires: gtk2-devel
|
||||
%define gtk_version 2
|
||||
%define toolkit gtk%gtk_version
|
||||
BuildRequires: libSM-devel
|
||||
BuildRequires: libexpat-devel
|
||||
BuildRequires: libjpeg-devel
|
||||
@@ -59,6 +96,24 @@ BuildRequires: libnotify-devel
|
||||
BuildRequires: libpng-devel
|
||||
BuildRequires: libtiff-devel
|
||||
BuildRequires: zlib-devel
|
||||
%if %{toolkit} == "gtk2"
|
||||
BuildRequires: gnome-vfs2-devel
|
||||
BuildRequires: gtk2-devel
|
||||
%endif
|
||||
%if %{toolkit} == "gtk3"
|
||||
BuildRequires: pkgconfig(gtk+-3.0)
|
||||
%if %{with webview}
|
||||
BuildRequires: pkgconfig(webkit2gtk-4.0)
|
||||
%endif
|
||||
%endif
|
||||
%if %{toolkit} == "qt"
|
||||
BuildRequires: pkgconfig(Qt5Core) >= 5.2.1
|
||||
BuildRequires: pkgconfig(Qt5Gui) >= 5.2.1
|
||||
BuildRequires: pkgconfig(Qt5OpenGL) >= 5.2.1
|
||||
BuildRequires: pkgconfig(Qt5Test) >= 5.2.1
|
||||
BuildRequires: pkgconfig(Qt5Widgets) >= 5.2.1
|
||||
BuildRequires: pkgconfig(cairo)
|
||||
%endif
|
||||
BuildRequires: pkgconfig(glu)
|
||||
BuildRequires: pkgconfig(liblzma)
|
||||
%if 0%{?sle_version} < 150000 && !0%{?is_opensuse}
|
||||
@@ -89,6 +144,7 @@ Every wxWidgets application must link against this library. It
|
||||
contains mandatory classes that any wxWidgets code depends on (e.g.
|
||||
wxString) and portability classes that abstract differences between
|
||||
platforms. wxBase can be used to develop console-only applications.
|
||||
%{?extra_description}
|
||||
|
||||
%package -n libwx_baseu_net-%variant%psonum
|
||||
Summary: wxWidgets networking library
|
||||
@@ -144,6 +200,7 @@ The wxHTML library provides classes for parsing and displaying HTML.
|
||||
It is not intended to be a high-end HTML browser. wxHTML can be used
|
||||
as a generic rich text viewer – for example, to display an About Box
|
||||
or the result of a database search.
|
||||
%{?extra_description}
|
||||
|
||||
%package -n libwx_%{toolkit}u_media-%variant%psonum
|
||||
Summary: wxWidgets media class library
|
||||
@@ -221,9 +278,18 @@ Group: System/Libraries
|
||||
SDL based sound plugin for the wxWidgets cross-platform GUI.
|
||||
|
||||
%package devel
|
||||
Summary: Development files for GTK2-backed wxWidgets 3.2
|
||||
Summary: Development files for %{name}
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: gtk%gtk_version-devel
|
||||
%if %{toolkit} == "gtk2"
|
||||
Requires: gtk2-devel
|
||||
%endif
|
||||
%if %{toolkit} == "gtk3"
|
||||
Requires: pkgconfig(gtk+-3.0)
|
||||
%endif
|
||||
%if %{toolkit} == "qt"
|
||||
Requires: pkgconfig(Qt5OpenGL) >= 5.2.1
|
||||
Requires: pkgconfig(Qt5Widgets) >= 5.2.1
|
||||
%endif
|
||||
Requires: libwx_%{toolkit}u_adv-%variant%psonum = %version
|
||||
Requires: libwx_%{toolkit}u_aui-%variant%psonum = %version
|
||||
Requires: libwx_%{toolkit}u_core-%variant%psonum = %version
|
||||
@@ -235,12 +301,16 @@ Requires: libwx_%{toolkit}u_qa-%variant%psonum = %version
|
||||
Requires: libwx_%{toolkit}u_ribbon-%variant%psonum = %version
|
||||
Requires: libwx_%{toolkit}u_richtext-%variant%psonum = %version
|
||||
Requires: libwx_%{toolkit}u_stc-%variant%psonum = %version
|
||||
%if %{with webview}
|
||||
Requires: libwx_%{toolkit}u_webview-%variant%psonum = %version
|
||||
%endif
|
||||
Requires: libwx_%{toolkit}u_xrc-%variant%psonum = %version
|
||||
Requires: libwx_baseu-%variant%psonum = %version
|
||||
Requires: libwx_baseu_net-%variant%psonum = %version
|
||||
Requires: libwx_baseu_xml-%variant%psonum = %version
|
||||
Requires: pkgconfig(gl)
|
||||
Requires: pkgconfig(glu)
|
||||
|
||||
Provides: wxGTK2-devel = %version-%release
|
||||
Provides: wxWidgets-any-devel
|
||||
Provides: wxWidgets-devel = %version-%release
|
||||
@@ -255,7 +325,8 @@ backends. Applications can be created for different GUIs (GTK+,
|
||||
Motif, MS Windows, MacOS X, Windows CE, GPE) from the same source
|
||||
code.
|
||||
|
||||
This package contains all files needed for developing with wxGTK%gtk_version.
|
||||
This package contains all files needed for developing with %{name}.
|
||||
%{?extra_description}
|
||||
|
||||
Note: wxWidgets variant devel packages are mutually exclusive. Please
|
||||
read %_docdir/%name/README.SUSE to pick a correct variant.
|
||||
@@ -266,6 +337,8 @@ cp %{S:2} .
|
||||
|
||||
%build
|
||||
autoconf -f -i
|
||||
# NOTE: gnome-vfs is deprecated. Disabled for GTK3 build
|
||||
#
|
||||
# With 2.9.1:
|
||||
# --enable-objc_uniquifying is relevant only for Cocoa
|
||||
# --enable-accessibility is currently supported only in msw
|
||||
@@ -273,19 +346,31 @@ autoconf -f -i
|
||||
|
||||
%configure \
|
||||
--enable-vendor=%variant \
|
||||
%if %{toolkit} == "qt"
|
||||
--with-qt \
|
||||
%else
|
||||
--with-gtk=%gtk_version \
|
||||
%if %{gtk_version} == 2
|
||||
--with-gnomevfs \
|
||||
%endif
|
||||
%endif
|
||||
--enable-unicode \
|
||||
--with-opengl \
|
||||
--with-libmspack \
|
||||
--with-sdl \
|
||||
--with-gnomevfs \
|
||||
--enable-ipv6 \
|
||||
--enable-mediactrl \
|
||||
--enable-optimise \
|
||||
%{wx_debug:--enable-debug=%{wx_debug}} \
|
||||
--enable-repro-build \
|
||||
%if "%{flavor}" == "GTK3-nostl"
|
||||
--disable-stl \
|
||||
--disable-plugins
|
||||
%else
|
||||
--enable-stl \
|
||||
--enable-plugins
|
||||
%endif
|
||||
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
@@ -378,15 +463,25 @@ ln -sf $(echo %buildroot/%_libdir/wx/config/* | sed "s%%%buildroot%%%%") %buildr
|
||||
%files -n libwx_%{toolkit}u_stc-%variant%psonum
|
||||
%_libdir/libwx_%{toolkit}u_stc-%variant.so.%{sonum}*
|
||||
|
||||
%if %{with webview}
|
||||
%files -n libwx_%{toolkit}u_webview-%variant%psonum
|
||||
%_libdir/libwx_%{toolkit}u_webview-%variant.so.%{sonum}*
|
||||
%dir %_libdir/wx
|
||||
%dir %_libdir/wx/%wx_micro
|
||||
%_libdir/wx/%wx_micro/web-extensions/
|
||||
%endif
|
||||
|
||||
%files -n libwx_%{toolkit}u_xrc-%variant%psonum
|
||||
%_libdir/libwx_%{toolkit}u_xrc-%variant.so.%{sonum}*
|
||||
|
||||
%if %base_packages
|
||||
%if "%{flavor}" != "GTK3-nostl"
|
||||
%files -n %{base_name}-plugin-sound_sdlu-3_2
|
||||
%dir %_libdir/wx
|
||||
%dir %_libdir/wx/%wx_micro
|
||||
%_libdir/wx/%wx_micro/sound_sdlu-%wx_micro.so
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%files devel
|
||||
# Complete documentation is available in the docs packages.
|
||||
|
Reference in New Issue
Block a user