File libwacom.spec of Package libwacom

#
# spec file for package libwacom
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           libwacom
Version:        0.15
Release:        1.6
Summary:        Library to identify wacom tablets
License:        MIT
Group:          System/Libraries
Url:            http://linuxwacom.sourceforge.net/
Source:         http://downloads.sourceforge.net/project/linuxwacom/libwacom/%{name}-%{version}.tar.bz2
Source99:       baselibs.conf
%if 0%{?suse_version} >= 1140
BuildRequires:  pkgconfig(glib-2.0)
BuildRequires:  pkgconfig(gudev-1.0)
%else
BuildRequires:  glib2-devel
BuildRequires:  libgudev-1_0-devel
%endif
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
libwacom is a library to identify wacom tablets and their model-specific
features. It provides easy access to information such as "is this a
built-in on-screen tablet", "what is the size of this model", etc.

%package -n libwacom2
Summary:        Library to identify wacom tablets
Group:          System/Libraries
Requires:       %{name}-data >= %{version}

%description -n libwacom2
libwacom is a library to identify wacom tablets and their model-specific
features. It provides easy access to information such as "is this a
built-in on-screen tablet", "what is the size of this model", etc.

%package data
Summary:        Library to identify wacom tablets -- Data Files
Group:          System/Libraries

%description data
libwacom is a library to identify wacom tablets and their model-specific
features. It provides easy access to information such as "is this a
built-in on-screen tablet", "what is the size of this model", etc.

%package tools
Summary:        Library to identify wacom tablets -- Tools
Group:          Hardware/Other

%description tools
libwacom is a library to identify wacom tablets and their model-specific
features. It provides easy access to information such as "is this a
built-in on-screen tablet", "what is the size of this model", etc.

%package devel
Summary:        Library to identify wacom tablets -- Development Files
Group:          Development/Libraries/C and C++
Requires:       libwacom2 = %{version}

%description devel
libwacom is a library to identify wacom tablets and their model-specific
features. It provides easy access to information such as "is this a
built-in on-screen tablet", "what is the size of this model", etc.

%prep
%setup -q

%build
%configure \
        --disable-static
make %{?_smp_mflags}

%install
%make_install
find %{buildroot} -type f -name "*.la" -delete -print

%post -n libwacom2 -p /sbin/ldconfig

%postun -n libwacom2 -p /sbin/ldconfig

%files -n libwacom2
%defattr(-,root,root)
%doc COPYING NEWS README
%{_libdir}/libwacom.so.2*

%files data
%defattr(-,root,root)
%dir %{_datadir}/libwacom
%{_datadir}/libwacom/*.tablet
%{_datadir}/libwacom/*.stylus
%{_datadir}/libwacom/layouts/

%files tools
%defattr(-,root,root)
%{_bindir}/libwacom-list-local-devices

%files devel
%defattr(-,root,root)
%{_includedir}/libwacom-1.0/
%{_libdir}/*.so
%{_libdir}/pkgconfig/libwacom.pc

%changelog
* Sun Aug 16 2015 p.drouand@gmail.com
- Update to version 0.15
  * Support added for ISDv4 0x4800 (Dell Venue 10 5050 Android tablet)
  * Bustype i2c is now supported
- Changes from version 0.14
  * Support added for Cintiq 13HD touch
  * Fixes to the udev rule set to tag uinput devices correctly too
  * Integrated tabled are not marked as ID_INPUT_TOUCHPAD anymore now
* Sat Apr 25 2015 zaitor@opensuse.org
- Update to version 0.13:
  + New devices:
  - DTU-1141.
  - Huion H610 Pro.
  + Several memory leak fixes.
  + Added libwacom_match_get_name() to allow data-file matching on
    the name as well as the pid/vid.
* Fri Mar 27 2015 dimstar@opensuse.org
- Update to version 0.12:
  + Added libwacom_stylus_has_wheel() for relative wheel detection.
  + Added libwacom_stylus_get_axes() for a list of supported axes.
  + New devices:
  - Cintiq 27QHD, Cintiq 27QHD Touch.
  - DTU-1031X.
  - Intuos Pen Medium.
  + Reworked udev rules:
  - be more restrictive when to set ID_INPUT_TOUCHPAD.
  - unset ID_INPUT_JOYSTICK on tablet devices.
  - tag the Pad device as ID_INPUT_TABLET_PAD.
* Wed Jan 28 2015 zaitor@opensuse.org
- Update to version 0.11:
  + Better detection of wireless tablets on kernels 3.18.
  + New devices: Cintiq Companion.
* Sat Aug 23 2014 dimstar@opensuse.org
- Update to version 0.10:
  + Fixed bus detection of Bluetooth tablets on kernels 3.14 and
    later.
  + New devices: ISDV4 0x12C, 116, 4004, 5000, 5002.
* Sat Mar  8 2014 dimstar@opensuse.org
- Update to version 0.9:
  + Add support for TouchSwitch keyword.
  + New devices:
  - Intuos series.
  - Pen&Touch (2nd gen).
  - DTU-1031.
  - Cintiq Companion Hybri.
* Thu Oct 10 2013 dimstar@opensuse.org
- Update to version 0.8 (bnc#845267):
  + New devices:
  - Cintiq 13HD, 22HD touch.
  - DTH-2242, DTU-1931.
  - ISDv4 EC, ED, 10F.
  - Intuos Pro.
* Tue Apr 16 2013 dimstar@opensuse.org
- Update to version 0.7.1:
  + New devices: ISDv4 10d.
  + Better checks to prevent bad databases.
* Tue Jan  8 2013 dimstar@opensuse.org
- Update to version 0.7:
  + New devices:
  - Cintiq 22HD, 24HD touch,
  - ISDv4 E5, 100, 101
  + Support for SVG layouts of the tablets
  + New APIs for:
  - list status LEDs
  - list integration flags (differ between builtin and
    screen-tablets)
* Fri Nov  9 2012 dimstar@opensuse.org
- Update to version 0.6.1:
  + More/corrected metadata for:
  - Cintiq 22HD, 24HD, 24HD touch.
  - DTI 520.
  - ISDv4 E5, 100, 101.
* Sat Jul 14 2012 zaitor@opensuse.org
- Update to version 0.6:
  + More metadata for:
  - NTrig tablet PC
  - ISDv4 0x93, 0x90, 0xED, 0xEF
  - Bamboo Pen, Fun, Craft, Touch
  + Support for debugging with uinput devices.
* Mon May 14 2012 vuntz@opensuse.org
- Update to version 0.5:
  + Add support for multiple match statements
  + Add support for bluetotooth devices
  + Add libwacom-list-local-devices helper tool
  + Add list-devices helper tool
  + Rename udev generation tool to generate-udev-rules
  + More metadata description updates
- Create a tools subpackage for the new libwacom-list-local-devices
  helper tool.
* Tue Mar 27 2012 vuntz@opensuse.org
- Update to version 0.4:
  + More metadata for:
  - Intuos4 WL
  - Bamboo One
  - Intuos5 series
  + Don't fail to create a WacomDevice for Touch devices
  + Add API to access all items in the database
  + Add helper tool to generate udev rules from the database
* Tue Feb  7 2012 vuntz@opensuse.org
- Update to version 0.3:
  + Loads of new and updated tablet definition files
  + Add and correct information about styli
  + Update wacom.example with loads of documentation about adding
    new tablet definitions
  + Handle Puck device type
  + Support enumerating touchstrips, touchrings and buttons
  + Get device name from the kernel for generic tablets
  + Add support for the WACf004 serial tablet
  + Build fixes (exported symbols, soname)
- Remove xz BuildRequires now that it comes for free in the build
  system.
- Rename libwacom0 subpackage to libwacom2, following upstream
  soversion change.
* Tue Jan 17 2012 vuntz@opensuse.org
- Update to version 0.2:
  + Don't add devices that lack DeviceMatch
  + Get whether a device is builtin from udev
  + Fix definitions for Reversible property
  + Add definition for Cintiq 21UX2
  + Add test for serial devices
  + Fix Intuos4 styli's number of buttons
- Add xz BuildRequires because we can't build a package for a
  xz-compressed tarball without explicitly specifying that... See
  bnc#697467 for more details.
* Thu Jan  5 2012 vuntz@opensuse.org
- Initial package (version 0.1).