1 %{!?_with_debug:%{!?_without_debug:%define _without_debug 0}}
3 %define kernel kernel-x86-ivi
4 %define kernel_relstr "%(/bin/rpm -q --queryformat '%{VERSION}-%{RELEASE}' %{kernel})"
5 %define kernel_release %(echo %{kernel_relstr})
6 %define kernel_modstr "%(/bin/rpm -ql %{kernel} | sort | grep /lib/modules/%{kernel_release} | head -1 | sed 's#/*$##g')"
7 %define kernel_modpath %(echo %{kernel_modstr})
8 %define kernel_moddir %(echo %{kernel_modstr} | sed 's#.*/##g')
15 Group: System Environment/Daemons
16 URL: https://github.com/intel-ethernet/Open-AVB
17 Source0: %{name}-%{version}.tar.gz
18 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
19 Requires: openavb-kmod-igb
21 BuildRequires: libstdc++-devel
22 BuildRequires: kernel-x86-ivi-devel
23 BuildRequires: pkgconfig(libpci)
24 BuildRequires: pkgconfig(zlib)
27 Summary: OpenAVB kernel module for Intel ethernet cards.
28 Group: System Environment/Kernel
29 Requires: %{kernel}-%{kernel_release}
32 Summary: igb runtime library from the OpenAVB distribution.
33 Group: System Environment/Libraries
36 Summary: Example clients from the OpenAVB distribution.
37 Group: Applications/Communications
38 Requires: openavb-libigb = %{version}
41 Summary: Headers and libraries from the OpenAVB distribution.
42 Group: Development/Libraries
45 Summary: Documentation from theOpenAVB distribution.
49 This package contains the basic OpenAVB userspace daemons.
52 This package contains the kernel module required by OpenAVB for Intel
56 This package contains the libigb runtime library from the OpenAVB
60 This package contains various test and example utilities for OpenAVB.
63 This package contains header files and libraries for OpenAVB.
66 This package contains some documentation from the OpenAVB distribution.
72 %if %{?_with_debug:1}%{!?_with_debug:0}
73 export CFLAGS="-O0 -g3"
74 export CXXFLAGS="-O0 -g3"
77 NUM_CPUS="`cat /proc/cpuinfo | tr -s '\t' ' ' | \
78 grep '^processor *:' | wc -l`"
79 [ -z "$NUM_CPUS" ] && NUM_CPUS=1
82 %configure $CONFIG_OPTIONS && \
83 make BUILD_KERNEL=%{kernel_moddir} clean && \
84 make BUILD_KERNEL=%{kernel_moddir} -j$(($NUM_CPUS + 1))
87 rm -rf $RPM_BUILD_ROOT
89 make DESTDIR=$RPM_BUILD_ROOT \
90 INSTALL_MOD_PATH=$RPM_BUILD_ROOT \
91 BUILD_KERNEL=%{kernel_moddir} install
93 rm -f $RPM_BUILD_ROOT%{_libdir}/libigb.la
96 rm -rf $RPM_BUILD_ROOT
102 depmod -a %{kernel_moddir}
105 %defattr(-,root,root,-)
106 %{_sbindir}/daemon_cl
111 %defattr(-,root,root,-)
112 %{kernel_modpath}/kernel/drivers/net/igb_avb
115 %defattr(-,root,root,-)
116 %{_libdir}/libigb.so.*
119 %defattr(-,root,root,-)
122 %{_bindir}/simple_talker
125 %defattr(-,root,root,-)
128 %{_libdir}/pkgconfig/igb.pc
131 %defattr(-,root,root,-)
132 %doc README.rst documents examples
135 * Tue Nov 27 2012 Krisztian Litkey <krisztian.litkey@intel.com> -
136 - Initial build for 2.0alpha.