Blob Blame Raw
%global commit0 0c10102578e7c762674eaf9460b0903d76f151db
%global shortcommit0 %(c=%{commit0}; echo ${c:0:7})
%global gver .%{gitdate}git%{shortcommit0}
%global gitdate 20170703

Name:           i-nex
Version:        7.6.0
Release:        9%{gver}%{?dist}
Summary:        System information tool like hardinfo, sysinfo
License:        GPLv3 and LGPLv3
Source1:        %{name}.appdata.xml
Patch0:         %{name}-Makefile.patch

ExcludeArch:    aarch64 %arm ppc64le ppc64 s390x
BuildRequires:  gambas3-devel
BuildRequires:  ImageMagick
BuildRequires:  ImageMagick-devel
BuildRequires:  git
BuildRequires:  gcc-c++
BuildRequires:  autoconf
BuildRequires:  make
BuildRequires:  redhat-lsb
BuildRequires:  automake
BuildRequires:  libappstream-glib
BuildRequires:  gambas3-gb-image
BuildRequires:  gambas3-gb-qt5
BuildRequires:  gambas3-gb-form
BuildRequires:  gambas3-gb-desktop
BuildRequires:  gambas3-gb-form-dialog >= 3.5.0
BuildRequires:  gambas3-gb-form-stock
BuildRequires:  gambas3-gb-gui >= 3.5.0
BuildRequires:  gambas3-gb-qt5-ext >= 3.5.0
BuildRequires:  gambas3-gb-settings
BuildRequires:  pkgconfig
BuildRequires:  libcpuid-devel >= 0.2.1
BuildRequires:  pkgconfig(libprocps)
BuildRequires:  pkgconfig(x11)
BuildRequires:  pkgconfig(gl)
BuildRequires:  pkgconfig(xext)
BuildRequires:  pciutils
BuildRequires:  procps
BuildRequires:  desktop-file-utils
Requires:       gambas3-gb-gtk
Requires:       gambas3-gb-desktop
Requires:       gambas3-gb-settings
Requires:       gambas3-gb-form-dialog
Requires:       gambas3-gb-qt5 >= 3.5.0
Requires:       gambas3-gb-qt5-ext >= 3.5.0
Requires:       gambas3-gb-form-mdi
Requires:       gambas3-gb-form-stock
Requires:       redhat-lsb
Requires:       mesa-demos 
Requires:       xorg-x11-server-utils
Requires:       gambas3-gb-dbus
Requires:       gambas3-runtime
Requires:       gambas3-gb-image
Requires:       gambas3-gb-gtk
Requires:       gambas3-gb-form
Requires:       util-linux
Requires:       procps-ng
Requires:       coreutils
Requires:       pciutils
Requires:       libcpuid
Requires:       gambas3-runtime
Requires:       gambas3-gb-gui >= 3.5.0
Requires:       net-tools
Requires:       procps-ng
Requires:       pastebinit
Requires:       procps-ng

i-nex - System information tool like hardinfo, sysinfo.
I-Nex is an application that gathers information for hardware 
components available on your system and displays it using an 
user interface similar to the popular Windows tool CPU-Z.

I-Nex can display information for the following components: CPU, 
GPU, Motherboard, Sound, Hard disks, RAM, Network and USB as well 
as some system info like the hostname, Linux distribution and 
version, Xorg, GCC, GLX versions and Linux Kernel info.

%autosetup -p1 -n I-Nex-%{commit0}
# make it dynamic
sed -i -e 's|^STATIC.*|STATIC = false|'
sed -i -e 's|^UDEV_RULES_DIR.*|UDEV_RULES_DIR = /usr/lib/udev/rules.d|'
# A hack to be able to run the program via the name execution. Thanks openSuse!
#+ some info tools are under *sbin
cat > %{name}.sh <<HERE

export LIBOVERLAY_SCROLLBAR=0 PATH=/sbin:/usr/sbin:\$PATH
exec %{_bindir}/%{name}.gambas

#using system's pastebinit
sed -i \
       '\|/usr/share/i-nex/pastebinit/|s|/usr/share/i-nex/pastebinit/||' \
cp I-Nex/i-nex/logo/i-nex.0.4.x.png %{name}.png
sed -e 's|env LIBOVERLAY_SCROLLBAR=0 /usr/bin/i-nex.gambas|i-nex|' \
         -e '/^Icon=/s|=.*|=%{name}|' debian/%{name}.desktop > %{name}.desktop

# remove empty line
sed -i -e '1,1d' debian/i-nex-library.desktop

cd I-Nex
autoreconf -fiv
cd ..


# A hack to be able to run the program via the name execution.
install -D -m 755 %{name}.sh %{buildroot}%{_bindir}/%{name}

# Let's use %%doc macro.
rm -rf %{buildroot}%{_datadir}/doc/%{name}

# Let's use system's `pastebinit`.
rm -rf %{buildroot}%{_datadir}/%{name}/pastebinit

chmod 0644 %{buildroot}/%{_udevrulesdir}/i2c_smbus.rules 
mv %{buildroot}/%{_udevrulesdir}/i2c_smbus.rules %{buildroot}/%{_udevrulesdir}/50-i2c_smbus.rules

install -Dm644 %{S:1} %{buildroot}/%{_datadir}/appdata/%{name}.appdata.xml

desktop-file-validate %{buildroot}%{_datadir}/applications/*.desktop
appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/appdata/%{name}.appdata.xml

%license debian/copyright

* Tue Oct 08 2019 Petr Viktorin <> - 7.6.0-9.20170703git0c10102
- Remove unused dependency python2-configobj

* Thu Jul 25 2019 Fedora Release Engineering <> - 7.6.0-8.20170703git0c10102
- Rebuilt for

* Fri Feb 01 2019 Fedora Release Engineering <> - 7.6.0-7.20170703git0c10102
- Rebuilt for

* Fri Jul 13 2018 Fedora Release Engineering <> - 7.6.0-6.20170703git0c10102
- Rebuilt for

* Thu Mar 15 2018 Martin Gansser <> - 7.6.0-5.20170703git0c10102
- Update Python 2 dependency declarations to new packaging standard

* Wed Feb 07 2018 Fedora Release Engineering <> - 7.6.0-4.20170703git0c10102
- Rebuilt for

* Mon Oct 23 2017 Martin Gansser <> - 7.6.0-3.20170703git0c10102
- Delete BR hicolor-icon-theme not needed
- Use udev macro %%{_udevrulesdir}
- Add BR libappstream-glib
- Add %%{name}-Makefile.patch to fix install pixmap
- Add ExcludeArch: aarch64 %%arm ppc64le ppc64 s390x

* Mon Oct 23 2017 Martin Gansser <> - 7.6.0-2.20170703git0c10102
- Use udev macro %%{_udevrulesdir}
- RR hicolor-icon-theme not needed
- Add an AppData file. See
- Add gitdate for snapshot release

* Wed Sep 27 2017 Martin Gansser <> - 7.6.0-1.20170703git0c10102 
-Initial build