libsmbios-vl.spec 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399
  1. # pkg/libsmbios.spec. Generated from libsmbios.spec.in by configure.
  2. # required by suse build system
  3. # norootforbuild
  4. # these are all substituted by autoconf
  5. %define major 2
  6. %define minor 2
  7. %define micro 28
  8. %define extra %{nil}
  9. %define pot_file libsmbios
  10. %define lang_dom libsmbios-2.2-x86_64
  11. %define release_version 2.2.28
  12. %define release_name libsmbios
  13. Name: %{release_name}
  14. Version: %{release_version}
  15. Release: 2%{?_dist_release}
  16. Summary: Libsmbios C/C++ shared libraries
  17. Summary(ja): Libsmbios C/C++ 共有ライブラリ
  18. License: GPLv2+ or OSL 2.1
  19. Group: System Environment/Libraries
  20. URL: http://linux.dell.com/libsmbios/main
  21. Source: http://linux.dell.com/libsmbios/download/libsmbios/libsmbios-%{version}/libsmbios-%{version}.tar.bz2
  22. Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root
  23. BuildRequires: strace libxml2-devel gcc-c++ gettext doxygen cppunit-devel pkgconfig python-devel
  24. # libsmbios only ever makes sense on intel compatible arches
  25. # no DMI tables on ppc, s390, etc.
  26. ExclusiveArch: x86_64 ia64 %{ix86}
  27. Vendor: Project Vine
  28. Distribution: Vine Linux
  29. Packager: shaolin, daisuke
  30. %description
  31. Libsmbios is a library and utilities that can be used by client programs to get
  32. information from standard BIOS tables, such as the SMBIOS table.
  33. This package provides the C-based libsmbios library, with a C interface.
  34. This package also has a C++-based library, with a C++ interface. It is not
  35. actively maintained, but provided for backwards compatibility. New programs
  36. should use the libsmbios C interface.
  37. %package -n python-smbios
  38. Summary: Python interface to Libsmbios C library
  39. Summary(ja): libsmbios C ライブラリへの Python インターフェース
  40. Group: System Environment/Libraries
  41. Requires: %{release_name} = %{version}-%{release}
  42. Requires: python
  43. %description -n python-smbios
  44. This package provides a Python interface to libsmbios
  45. %package -n smbios-utils
  46. Summary: Meta-package that pulls in all smbios binaries and python scripts
  47. Summary(ja): すべての smbios プログラムと python スクリプトをインストールするための仮想パッケージ
  48. Group: Applications/System
  49. Requires: smbios-utils-bin
  50. Requires: smbios-utils-python
  51. %description -n smbios-utils
  52. This is a meta-package that pulls in the binary libsmbios executables as well
  53. as the python executables.
  54. %package -n smbios-utils-bin
  55. Summary: Binary utilities that use libsmbios
  56. Summary(ja): libsmbios を用いたユーティリティ集
  57. Group: Applications/System
  58. Requires: %{release_name} = %{version}-%{release}
  59. %description -n smbios-utils-bin
  60. Get BIOS information, such as System product name, product id, service tag and
  61. asset tag.
  62. %package -n smbios-utils-python
  63. Summary: Python executables that use libsmbios
  64. Summary(ja): libsmbios を用いた Python スクリプト集
  65. Group: Applications/System
  66. Requires: python-smbios = %{version}-%{release}
  67. %description -n smbios-utils-python
  68. Get BIOS information, such as System product name, product id, service tag and
  69. asset tag. Set service and asset tags on Dell machines. Manipulate wireless
  70. cards/bluetooth on Dell laptops. Set BIOS password on select Dell systems.
  71. Update BIOS on select Dell systems. Set LCD brightness on select Dell laptops.
  72. # name the devel package libsmbios-devel regardless of package name, per suse/fedora convention
  73. %package -n libsmbios-devel
  74. Summary: Development headers and archives
  75. Summary(ja): libsmbios の開発用ヘッダファイルとライブラリ
  76. Group: Development/Libraries
  77. Requires: %{release_name} = %{version}-%{release}
  78. %description -n libsmbios-devel
  79. Libsmbios is a library and utilities that can be used by client programs to get
  80. information from standard BIOS tables, such as the SMBIOS table.
  81. This package contains the headers and .a files necessary to compile new client
  82. programs against libsmbios.
  83. %prep
  84. %setup -q -n libsmbios-%{version}
  85. find . -type d -exec chmod -f 755 {} \;
  86. find doc src -type f -exec chmod -f 644 {} \;
  87. chmod 755 src/cppunit/*.sh
  88. %build
  89. # this line lets us build an RPM directly from a git tarball
  90. # and retains any customized version information we might have
  91. [ -e ./configure ] || ./autogen.sh --no-configure
  92. mkdir _build
  93. cd _build
  94. echo '../configure "$@"' > configure
  95. chmod +x ./configure
  96. %configure
  97. mkdir -p out/libsmbios_c
  98. mkdir -p out/libsmbios_c++
  99. make %{?_smp_mflags} 2>&1 | tee build-%{_arch}.log
  100. echo \%doc _build/build-%{_arch}.log > buildlogs.txt
  101. %install
  102. rm -rf %{buildroot}
  103. mkdir %{buildroot}
  104. cd _build
  105. TOPDIR=..
  106. make install DESTDIR=%{buildroot} INSTALL="%{__install} -p"
  107. mkdir -p %{buildroot}/%{_includedir}
  108. cp -a $TOPDIR/src/include/* %{buildroot}/%{_includedir}/
  109. cp -a out/public-include/* %{buildroot}/%{_includedir}/
  110. rm -f %{buildroot}/%{_libdir}/lib*.{la,a}
  111. find %{buildroot}/%{_includedir} out/libsmbios_c++ out/libsmbios_c -exec touch -r $TOPDIR/configure.ac {} \;
  112. mv out/libsmbios_c++ out/libsmbios_c++-%{_arch}
  113. mv out/libsmbios_c out/libsmbios_c-%{_arch}
  114. rename %{pot_file}.mo %{lang_dom}.mo $(find %{buildroot}/%{_datadir} -name %{pot_file}.mo)
  115. %find_lang %{lang_dom}
  116. touch files-yum-dellsysid
  117. touch files-smbios-utils-python
  118. touch files-python-smbios
  119. # backwards compatible:
  120. ln -s %{_sbindir}/dellWirelessCtl %{buildroot}/%{_bindir}/dellWirelessCtl
  121. ln -s smbios-sys-info %{buildroot}/%{_sbindir}/getSystemId
  122. ln -s smbios-wireless-ctl %{buildroot}/%{_sbindir}/dellWirelessCtl
  123. ln -s smbios-lcd-brightness %{buildroot}/%{_sbindir}/dellLcdBrightness
  124. ln -s smbios-rbu-bios-update %{buildroot}/%{_sbindir}/dellBiosUpdate
  125. cat > files-python-smbios <<-EOF
  126. %doc COPYING-GPL COPYING-OSL README
  127. %{python_sitelib}/*
  128. EOF
  129. cat > files-smbios-utils-python <<-EOF
  130. %doc COPYING-GPL COPYING-OSL README
  131. %doc src/bin/getopts_LICENSE.txt src/include/smbios/config/boost_LICENSE_1_0_txt
  132. %doc doc/pkgheader.sh
  133. %dir %{_sysconfdir}/libsmbios
  134. %config(noreplace) %{_sysconfdir}/libsmbios/*
  135. # python utilities
  136. %{_sbindir}/smbios-sys-info
  137. %{_sbindir}/smbios-token-ctl
  138. %{_sbindir}/smbios-passwd
  139. %{_sbindir}/smbios-wakeup-ctl
  140. %{_sbindir}/smbios-wireless-ctl
  141. %{_sbindir}/smbios-rbu-bios-update
  142. %{_sbindir}/smbios-lcd-brightness
  143. # symlinks: backwards compat
  144. %{_sbindir}/dellLcdBrightness
  145. %{_sbindir}/getSystemId
  146. %{_sbindir}/dellWirelessCtl
  147. %{_sbindir}/dellBiosUpdate
  148. # used by HAL in old location, so keep it around until HAL is updated.
  149. %{_bindir}/dellWirelessCtl
  150. # data files
  151. %{_datadir}/smbios-utils
  152. EOF
  153. %clean
  154. rm -rf %{buildroot}
  155. %post -n %{release_name} -p /sbin/ldconfig
  156. %postun -n %{release_name} -p /sbin/ldconfig
  157. %files -f _build/%{lang_dom}.lang
  158. %defattr(-,root,root,-)
  159. %{_libdir}/libsmbios_c.so.*
  160. %{_libdir}/libsmbios.so.*
  161. %files -n libsmbios-devel -f _build/buildlogs.txt
  162. %defattr(-,root,root,-)
  163. %doc COPYING-GPL COPYING-OSL README src/bin/getopts_LICENSE.txt src/include/smbios/config/boost_LICENSE_1_0_txt
  164. %{_includedir}/smbios
  165. %{_includedir}/smbios_c
  166. %{_libdir}/libsmbios.so
  167. %{_libdir}/libsmbios_c.so
  168. %{_libdir}/pkgconfig/*.pc
  169. %doc _build/out/libsmbios_c++-%{_arch}
  170. %doc _build/out/libsmbios_c-%{_arch}
  171. %files -n smbios-utils
  172. # opensuse 11.1 enforces non-empty file list :(
  173. %defattr(-,root,root,-)
  174. %doc COPYING-GPL COPYING-OSL README
  175. # no other files.
  176. %files -n smbios-utils-bin
  177. %defattr(-,root,root,-)
  178. %doc COPYING-GPL COPYING-OSL README
  179. %doc src/bin/getopts_LICENSE.txt src/include/smbios/config/boost_LICENSE_1_0_txt
  180. %doc doc/pkgheader.sh
  181. #
  182. # legacy C++
  183. %{_sbindir}/dellBiosUpdate-compat
  184. %{_sbindir}/dellLEDCtl
  185. %ifnarch ia64
  186. %{_sbindir}/dellMediaDirectCtl
  187. %endif
  188. #
  189. # new C utilities
  190. %{_sbindir}/smbios-state-byte-ctl
  191. %{_sbindir}/smbios-get-ut-data
  192. %{_sbindir}/smbios-upflag-ctl
  193. %{_sbindir}/smbios-sys-info-lite
  194. %files -n python-smbios -f _build/files-python-smbios
  195. %defattr(-,root,root,-)
  196. %files -n smbios-utils-python -f _build/files-smbios-utils-python
  197. %defattr(-,root,root,-)
  198. %changelog
  199. * Tue Feb 24 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 2.2.28-2
  200. - rebuilt on current VineSeed
  201. - added Japanese summary
  202. * Thu Feb 16 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.2.28-1
  203. - update to 2.2.28
  204. * Sun Apr 24 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 2.2.26-1
  205. - merged with upstream package
  206. * Sat May 24 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 2.0.1-3
  207. - initial build for Vine Linux
  208. * Mon Sep 27 2010 Matt Domsch <mdomsch@fedoraproject.org> - 2.2.26-3
  209. - build for Fedora 15
  210. * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 2.2.19-2
  211. - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
  212. * Fri Jul 06 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.26-1
  213. - implement CSV export of token settings from smbios-token-ctl
  214. * Fri Jul 06 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.25-1
  215. - Fix breakage resulting from improperly fixing up constructors for MemoryAccess/CmosAccess. Fixes CLI utilities.
  216. * Fri Jun 11 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.23-1
  217. - Fixup ABI break where a couple functions that should have been exported were not marked.
  218. * Thu Jun 10 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.22-1
  219. - Fixup bug in reading asset and service tag where it A) read checksum from wrong location and B) used wrong comparison check to validate it
  220. - enable service tag SET for machines that still set service tag in CMOS
  221. - ABI/API - change to -fvisibility=hidden for libsmbios_c.so.*, mark public api's. This removes all non-public symbols that were not formerly part of the ABI from the dynamic link table.
  222. * Mon May 18 2009 Matt Domsch <Matt_Domsch@dell.com> - 2.2.16-3
  223. - split yum plugin into yum-dellsysid package
  224. * Mon Mar 24 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.16-1
  225. - add gcc 4.4 support
  226. * Mon Mar 24 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.15-1
  227. - update to lastest upstream.
  228. - fixes bug in bios update on systems with versions like x.y.z.
  229. * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.2.13-2
  230. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  231. * Tue Feb 3 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.12-1
  232. - Add feature to turn on debugging printf()'s without recompiling by setting
  233. certain environment variables:
  234. LIBSMBIOS_C_DEBUG_OUTPUT_ALL -- all debugging output
  235. or, per module:
  236. LIBSMBIOS_C_DEBUG_CONSTRUCTOR_C
  237. LIBSMBIOS_C_DEBUG_SYSINFO_C
  238. LIBSMBIOS_C_DEBUG_SMBIOS_C
  239. LIBSMBIOS_C_DEBUG_TOKEN_C
  240. LIBSMBIOS_C_DEBUG_MEMORY_C
  241. LIBSMBIOS_C_DEBUG_CMOS_C
  242. LIBSMBIOS_C_DEBUG_SMI_C
  243. * Mon Feb 2 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.12-1
  244. - Add pkgconfig files to -devel
  245. - fixup yum plugin to not parse certain data that causes a crash on some machines (Optiplex 755, others may be affected)
  246. * Thu Jan 15 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.8-1
  247. - revert change in upstream renaming rpm to libsmbios2
  248. * Thu Jan 15 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.7-1
  249. - change source to bz2 format
  250. - Update to latest upstream release. Many changes in the new release:
  251. - python interface
  252. - libsmbios_c interface almost fully implemented
  253. - libsmbios c++ interface deprecated
  254. * Tue Oct 28 2008 Michael E Brown <michael_e_brown at dell.com> - 2.2.0-1
  255. - Spec updates
  256. * Mon Apr 21 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.1-2.1
  257. - obsolete libsmbios-libs as well
  258. * Mon Mar 3 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.1-2
  259. - properly obsolete older versions
  260. * Wed Feb 13 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.1
  261. - Fixup GCC 4.3 compile issues.
  262. * Wed Jan 9 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.0
  263. - ABI incompatible, minor API changes
  264. - sync up libsmbios soname with version #
  265. - move binaries to /usr/sbin as they are only runnable by root
  266. - drop libsmbiosxml lib as it was mostly unused.
  267. - drop autotools generated files out of git and add autogen.sh
  268. - drop tokenCtl binary-- pysmbios has a *much* improved version
  269. * Wed Aug 22 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.9
  270. - Fix a couple of failure-to-check-return on fopen. most were unit-test code
  271. only, but two or three were in regular code.
  272. - Add hinting to the memory class, so that it can intelligently close /dev/mem
  273. file handle when it is not needed (which is most of the time). it only
  274. leaves it open when it is scanning, so speed is not impacted.
  275. * Tue Aug 6 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.8
  276. - new upstream
  277. * Tue Apr 3 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.6
  278. - critical bugfix for dellBiosUpdate utility for packet mode
  279. - autoconf/automake support for automatically building docs
  280. - more readable 'make' lines by splitting out env vars
  281. - remove run_cppunit option... always run unit tests.
  282. - update autoconf/automake utilities to latest version
  283. - fix LDFLAGS to not overwrite user entered LDFLAGS
  284. - add automatic doxygen build of docs
  285. - fix urls of public repos
  286. - remove yum repo page in favor of official page from docs
  287. - split dmi table entry point from smbios table entry point
  288. - support legacy _DMI_ tables
  289. - fix support for EFI-based imacs without proper _SM_ anchor
  290. * Tue Mar 20 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.5
  291. - rpmlint cleanups
  292. - Add dellLEDCtl binary
  293. - update AUTHORS file to add credit for dellLEDCtl
  294. - update doc/DellToken.txt to add a few more useful tokens.
  295. - updated build system to create documentation
  296. - skip cppunit dep on .elX builds (not in EPEL yet)
  297. * Mon Mar 12 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.4-1
  298. - Added dellWirelessCtl binary
  299. - Added 'static' makefile target to build static binaries and clean them as well
  300. - fix for signed/unsigned bug in probes binary. CPU temp misreported
  301. - simplify interface for DELL_CALLING_INTERFACE_SMI, autodetect Port/Magic
  302. - document all of the tokens for controlling wireless on dell notebooks
  303. - enums for SMI args/res to make code match docs better (cbRES1 = res[0], which
  304. was confusing.
  305. - helper functions isTokenActive() and activateToken() to simplify token API.
  306. - Added missing windows .cpp files to the dist tarball for those who compile
  307. windows from dist tarball vs source control
  308. - Add support for EFI based machines without backwards compatible smbios table
  309. entry point in 0xF0000 block.
  310. - Added wirelessSwitchControl() and wirelessRadioControl() API for newer
  311. laptops.
  312. - fixed bug in TokenDA activate() code where it wasnt properly using SMI
  313. (never worked, but apparently wasnt used until now.)
  314. * Tue Oct 3 2006 Michael E Brown <Michael_E_Brown@Dell.com> - 0.13.0-1
  315. - autotools conversion
  316. - add Changelog
  317. * Tue Sep 26 2006 Michael E Brown <michael_e_brown at dell.com> - 0.12.4-1
  318. - Changes per Fedora Packaging Guidelines to prepare to submit to Extras.
  319. - Add in a changelog entry per Fedora Packaging Guidelines...