Commit dfc34cc09fd72d7d5ff71e4e4ace85ffdd1bf8e9
1 parent
5f73e572
Exists in
master
and in
1 other branch
Updating RPM package info.
Showing
1 changed file
with
32 additions
and
21 deletions
Show diff stats
rpm/libv3270.spec
| @@ -22,6 +22,12 @@ | @@ -22,6 +22,12 @@ | ||
| 22 | %define MINOR_VERSION 2 | 22 | %define MINOR_VERSION 2 |
| 23 | 23 | ||
| 24 | %define _libvrs %{MAJOR_VERSION}_%{MINOR_VERSION} | 24 | %define _libvrs %{MAJOR_VERSION}_%{MINOR_VERSION} |
| 25 | +%define _product %(pkg-config --variable=product_name lib3270) | ||
| 26 | + | ||
| 27 | +#Compat macro for new _fillupdir macro introduced in Nov 2017 | ||
| 28 | +%if ! %{defined _fillupdir} | ||
| 29 | + %define _fillupdir /var/adm/fillup-templates | ||
| 30 | +%endif | ||
| 25 | 31 | ||
| 26 | #---[ Macros ]-------------------------------------------------------------------------------------------------------- | 32 | #---[ Macros ]-------------------------------------------------------------------------------------------------------- |
| 27 | 33 | ||
| @@ -31,19 +37,22 @@ | @@ -31,19 +37,22 @@ | ||
| 31 | 37 | ||
| 32 | #---[ Main package ]-------------------------------------------------------------------------------------------------- | 38 | #---[ Main package ]-------------------------------------------------------------------------------------------------- |
| 33 | 39 | ||
| 34 | -Summary: 3270 Virtual Terminal for GTK | ||
| 35 | -Name: libv3270-%{_libvrs} | ||
| 36 | -Version: 5.2 | ||
| 37 | -Release: 0 | ||
| 38 | -License: LGPL-3.0 | ||
| 39 | -Source: libv3270-%{version}.tar.xz | 40 | +Summary: 3270 Virtual Terminal for GTK |
| 41 | +Name: libv3270-%{_libvrs} | ||
| 42 | +Version: 5.2 | ||
| 43 | +Release: 0 | ||
| 44 | +License: LGPL-3.0 | ||
| 45 | +Source: libv3270-%{version}.tar.xz | ||
| 40 | 46 | ||
| 41 | -Url: https://github.com/PerryWerneck/libv3270.git | 47 | +Url: https://github.com/PerryWerneck/libv3270.git |
| 42 | 48 | ||
| 43 | -Group: Development/Libraries/C and C++ | ||
| 44 | -BuildRoot: /var/tmp/%{name}-%{version} | 49 | +Group: Development/Libraries/C and C++ |
| 50 | +BuildRoot: /var/tmp/%{name}-%{version} | ||
| 45 | 51 | ||
| 46 | -BuildRequires: lib3270-devel | 52 | +Provides: libv3270_%{MAJOR_VERSION}_%{MINOR_VERSION} |
| 53 | +Conflicts: otherproviders(libv3270_%{MAJOR_VERSION}_%{MINOR_VERSION}) | ||
| 54 | + | ||
| 55 | +BuildRequires: lib3270-%{MAJOR_VERSION}_%{MINOR_VERSION}-devel | ||
| 47 | BuildRequires: autoconf >= 2.61 | 56 | BuildRequires: autoconf >= 2.61 |
| 48 | BuildRequires: automake | 57 | BuildRequires: automake |
| 49 | BuildRequires: binutils | 58 | BuildRequires: binutils |
| @@ -69,11 +78,6 @@ BuildRequires: gtk3-devel | @@ -69,11 +78,6 @@ BuildRequires: gtk3-devel | ||
| 69 | BuildRequires: libgladeui-2-6 | 78 | BuildRequires: libgladeui-2-6 |
| 70 | %endif | 79 | %endif |
| 71 | 80 | ||
| 72 | -%if 0%{?centos_version} | ||
| 73 | -# centos requires python for genmarshal | ||
| 74 | -BuildRequires: python | ||
| 75 | -%endif | ||
| 76 | - | ||
| 77 | %description | 81 | %description |
| 78 | 82 | ||
| 79 | Originally designed as part of the pw3270 application this library provides a TN3270 virtual terminal widget for GTK 3. | 83 | Originally designed as part of the pw3270 application this library provides a TN3270 virtual terminal widget for GTK 3. |
| @@ -82,15 +86,18 @@ See more details at https://softwarepublico.gov.br/social/pw3270/ | @@ -82,15 +86,18 @@ See more details at https://softwarepublico.gov.br/social/pw3270/ | ||
| 82 | 86 | ||
| 83 | #---[ Development ]--------------------------------------------------------------------------------------------------- | 87 | #---[ Development ]--------------------------------------------------------------------------------------------------- |
| 84 | 88 | ||
| 85 | -%package -n libv3270-devel | 89 | +%package devel |
| 86 | 90 | ||
| 87 | Summary: 3270 Virtual Terminal for GTK development files | 91 | Summary: 3270 Virtual Terminal for GTK development files |
| 88 | -Group: System/Libraries | 92 | +Group: Development/Libraries/C and C++ |
| 89 | 93 | ||
| 90 | Requires: %{name} = %{version} | 94 | Requires: %{name} = %{version} |
| 91 | -Requires: lib3270-devel | 95 | +Requires: lib3270-%{MAJOR_VERSION}_%{MINOR_VERSION}-devel |
| 96 | + | ||
| 97 | +Provides: libv3270-devel = %{version} | ||
| 98 | +Conflicts: otherproviders(libv3270-devel) | ||
| 92 | 99 | ||
| 93 | -%description -n libv3270-devel | 100 | +%description devel |
| 94 | 101 | ||
| 95 | 3270 Virtual Terminal for GTK development files. | 102 | 3270 Virtual Terminal for GTK development files. |
| 96 | 103 | ||
| @@ -139,6 +146,8 @@ rm -rf $RPM_BUILD_ROOT | @@ -139,6 +146,8 @@ rm -rf $RPM_BUILD_ROOT | ||
| 139 | 146 | ||
| 140 | %files | 147 | %files |
| 141 | %defattr(-,root,root) | 148 | %defattr(-,root,root) |
| 149 | + | ||
| 150 | +# https://en.opensuse.org/openSUSE:Packaging_for_Leap#RPM_Distro_Version_Macros | ||
| 142 | %if 0%{?sle_version} > 120200 | 151 | %if 0%{?sle_version} > 120200 |
| 143 | %doc AUTHORS README.md | 152 | %doc AUTHORS README.md |
| 144 | %license LICENSE | 153 | %license LICENSE |
| @@ -149,7 +158,9 @@ rm -rf $RPM_BUILD_ROOT | @@ -149,7 +158,9 @@ rm -rf $RPM_BUILD_ROOT | ||
| 149 | %{_libdir}/libv3270.so.%{MAJOR_VERSION} | 158 | %{_libdir}/libv3270.so.%{MAJOR_VERSION} |
| 150 | %{_libdir}/libv3270.so.%{MAJOR_VERSION}.%{MINOR_VERSION} | 159 | %{_libdir}/libv3270.so.%{MAJOR_VERSION}.%{MINOR_VERSION} |
| 151 | 160 | ||
| 152 | -%files -n libv3270-devel | 161 | +%config %{_datadir}/%{_product}/colors.conf |
| 162 | + | ||
| 163 | +%files devel | ||
| 153 | %defattr(-,root,root) | 164 | %defattr(-,root,root) |
| 154 | 165 | ||
| 155 | %{_libdir}/libv3270.so | 166 | %{_libdir}/libv3270.so |
| @@ -159,7 +170,7 @@ rm -rf $RPM_BUILD_ROOT | @@ -159,7 +170,7 @@ rm -rf $RPM_BUILD_ROOT | ||
| 159 | %{_includedir}/v3270 | 170 | %{_includedir}/v3270 |
| 160 | 171 | ||
| 161 | %{_libdir}/*.a | 172 | %{_libdir}/*.a |
| 162 | -%{_datadir}/pw3270/pot/*.pot | 173 | +%{_datadir}/%{_product}/pot/*.pot |
| 163 | 174 | ||
| 164 | %files -n glade-catalog-v3270 | 175 | %files -n glade-catalog-v3270 |
| 165 | %defattr(-,root,root) | 176 | %defattr(-,root,root) |