1 |
%define srcname %{name}-libs |
%define srcname %{name}-libs |
2 |
|
|
3 |
|
%global _smp_ncpus_max 1 |
4 |
|
|
5 |
%define lib_major_xcompshad 3 |
%define lib_major_xcompshad 3 |
6 |
%define lib_name_xcompshad %mklibname xcompshad %{lib_major_xcompshad} |
%define lib_name_xcompshad %mklibname xcompshad %{lib_major_xcompshad} |
7 |
|
|
11 |
%define lib_major_xcomp 3 |
%define lib_major_xcomp 3 |
12 |
%define lib_name_xcomp %mklibname xcomp %{lib_major_xcomp} |
%define lib_name_xcomp %mklibname xcomp %{lib_major_xcomp} |
13 |
|
|
|
|
|
14 |
Name: nx |
Name: nx |
15 |
Version: 3.5.99.25 |
Version: 3.5.99.26 |
16 |
Release: %mkrel 1 |
Release: %mkrel 1.1 |
17 |
Summary: NX core libraries |
Summary: NX core libraries |
18 |
License: GPLv2 |
License: GPLv2 |
19 |
Group: Networking/Remote access |
Group: Networking/Remote access |
20 |
Url: https://github.com/ArcticaProject/nx-libs |
Url: https://github.com/ArcticaProject/nx-libs |
21 |
Source0: https://github.com/ArcticaProject/nx-libs/archive/%{version}/%{name}-%{version}.tar.gz |
Source0: https://github.com/ArcticaProject/nx-libs/archive/%{version}/%{name}-libs-%{version}.tar.gz |
22 |
# Upstream commit 5ca9a6b1e0f51b3ff65d1b5d8010ec5a71432078 |
Patch0: nxlibs-ar.patch |
23 |
Patch0: nx-libs-FreeFontNames.patch |
|
24 |
BuildRequires: autoconf |
BuildRequires: autoconf |
25 |
BuildRequires: gcc-c++ |
BuildRequires: gcc-c++ |
26 |
BuildRequires: gccmakedep |
BuildRequires: gccmakedep |
42 |
BuildRequires: pkgconfig(xpm) |
BuildRequires: pkgconfig(xpm) |
43 |
BuildRequires: pkgconfig(xrandr) |
BuildRequires: pkgconfig(xrandr) |
44 |
BuildRequires: pkgconfig(xtst) |
BuildRequires: pkgconfig(xtst) |
45 |
|
BuildRequires: pkgconfig(xkbcomp) |
46 |
|
BuildRequires: pkgconfig(fontutil) |
47 |
BuildRequires: pixman-devel |
BuildRequires: pixman-devel |
48 |
BuildRequires: python3-devel |
BuildRequires: python3-devel |
49 |
BuildRequires: quilt |
BuildRequires: quilt |
119 |
%setup -q -n %{srcname}-%{version} |
%setup -q -n %{srcname}-%{version} |
120 |
%autopatch -p1 |
%autopatch -p1 |
121 |
|
|
122 |
%build |
# Fix prefix, libdir etc |
123 |
|
sed -i -e '/ProjectRoot/s|/usr/local|%{_prefix}|g' nx-X11/config/cf/site.def |
124 |
cat >"tmp_configure" <<EOF |
sed -i -e 's|/usr/local/lib|%{_libdir}|g' \ |
125 |
export CFLAGS="-O2 -g -pipe -Wformat -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4" |
-e 's|/usr/local|%{_prefix}|g' \ |
126 |
%ifarch x86_64 ppc64 |
-e '/LibDirName/s|lib$|%{_lib}|g' \ |
127 |
export CFLAGS="$CFLAGS -fPIC -DPIC" |
nx-X11/config/cf/Imake.tmpl |
|
%endif |
|
|
export CXXFLAGS="$CFLAGS" |
|
|
export RPM_OPT_FLAGS="$CFLAGS" |
|
|
export LDFLAGS="%{?__global_ldflags} -Wl,-rpath,%{_pkglibdir}" |
|
|
|
|
|
CONFIGURE_TOP="."; |
|
|
/usr/lib/rpm/mageia/force-as-needed-for-shared-lib-in-libtool ; |
|
|
/usr/lib/rpm/mageia/drop-ld-no-undefined-for-shared-lib-modules-in-libtool ; |
|
|
/usr/lib/rpm/mageia/fix-libtool-ltmain-from-overlinking ; |
|
|
/usr/lib/rpm/mageia/fix-libtool-from-moving-options-after-libs ; |
|
|
/usr/lib/rpm/mageia/fix-dlsearch-path-in-libtool-for-multilib lib64 ; |
|
|
(cd ; [ ! -f configure.in -a ! -f configure.ac ] || libtoolize --copy --force); |
|
|
[ -f ./configure.in -o -f /configure.ac ] && |
|
|
CONFIGURE_XPATH="--x-includes=/usr/include --x-libraries=/usr/lib64" |
|
|
./configure --prefix=%{_prefix} --exec-prefix=%{_prefix} --bindir=%{_bindir} \ |
|
|
--sbindir=%{_sbindir} --sysconfdir=%{_sysconfdir} --datadir=%{_datadir} \ |
|
|
--includedir=%{_includedir} --libdir=%{_libdir} --libexecdir=%{_libdir} \ |
|
|
--localstatedir=%{_localstatedir} --mandir=%{_mandir} \ |
|
|
--infodir=%{_infodir} --disable-silent-rules "${@}" |
|
|
EOF |
|
128 |
|
|
129 |
|
$(rpm --eval '%%configure "${@}"'> tmp_configure) |
130 |
chmod a+x tmp_configure |
chmod a+x tmp_configure |
131 |
make CONFIGURE="$PWD/tmp_configure" IMAKE_DEFINES="-DUseTIRPC=YES" |
|
132 |
|
%build |
133 |
|
%make_build \ |
134 |
|
CONFIGURE="$PWD/tmp_configure" \ |
135 |
|
PREFIX=%{_prefix} \ |
136 |
|
LIBDIR=%{_libdir} \ |
137 |
|
IMAKE_DEFINES="-DUseTIRPC=YES" |
138 |
|
|
139 |
%install |
%install |
140 |
%make_install PREFIX="%{_prefix}" \ |
%make_install \ |
141 |
LIBDIR=%{_libdir} SHLIBDIR=%{_libdir} \ |
PREFIX=%{_prefix} \ |
142 |
|
LIBDIR=%{_libdir} \ |
143 |
INSTALL_DIR="install -dm0755" \ |
INSTALL_DIR="install -dm0755" \ |
144 |
INSTALL_FILE="install -pm0644" \ |
INSTALL_FILE="install -pm0644" \ |
145 |
INSTALL_PROGRAM="install -pm0755" |
INSTALL_PROGRAM="install -pm0755" |
157 |
rm -f %{buildroot}%{_libdir}/*.{a,la} |
rm -f %{buildroot}%{_libdir}/*.{a,la} |
158 |
|
|
159 |
# Fix python scripts |
# Fix python scripts |
160 |
pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{_bindir}/nxdialog |
%py3_shebang_fix %{buildroot}%{_bindir}/nxdialog |
161 |
|
|
162 |
%files -n nxagent |
%files -n nxagent |
163 |
%license COPYING LICENSE LICENSE.nxcomp |
%license COPYING LICENSE LICENSE.nxcomp |