libsmbios-vl.spec 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405
  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 3
  7. %define micro 0
  8. %define extra %{nil}
  9. %define pot_file libsmbios
  10. %define lang_dom libsmbios-2.3-x86_64
  11. %define release_version 2.3.0
  12. %define release_name libsmbios
  13. Name: %{release_name}
  14. Version: %{release_version}
  15. Release: 1%{?_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.xz
  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. mkdir -p %{buildroot}/%{_bindir}
  109. cp -a $TOPDIR/src/include/* %{buildroot}/%{_includedir}/
  110. cp -a out/public-include/* %{buildroot}/%{_includedir}/
  111. rm -f %{buildroot}/%{_libdir}/lib*.{la,a}
  112. find %{buildroot}/%{_includedir} out/libsmbios_c++ out/libsmbios_c -exec touch -r $TOPDIR/configure.ac {} \;
  113. mv out/libsmbios_c++ out/libsmbios_c++-%{_arch}
  114. mv out/libsmbios_c out/libsmbios_c-%{_arch}
  115. rename %{pot_file}.mo %{lang_dom}.mo $(find %{buildroot}/%{_datadir} -name %{pot_file}.mo)
  116. %find_lang %{lang_dom}
  117. touch files-yum-dellsysid
  118. touch files-smbios-utils-python
  119. touch files-python-smbios
  120. # backwards compatible:
  121. ln -s %{_sbindir}/dellWirelessCtl %{buildroot}/%{_bindir}/dellWirelessCtl
  122. ln -s smbios-sys-info %{buildroot}/%{_sbindir}/getSystemId
  123. ln -s smbios-wireless-ctl %{buildroot}/%{_sbindir}/dellWirelessCtl
  124. ln -s smbios-lcd-brightness %{buildroot}/%{_sbindir}/dellLcdBrightness
  125. ln -s smbios-rbu-bios-update %{buildroot}/%{_sbindir}/dellBiosUpdate
  126. cat > files-python-smbios <<-EOF
  127. %doc COPYING-GPL COPYING-OSL README
  128. %{python_sitelib}/*
  129. EOF
  130. cat > files-smbios-utils-python <<-EOF
  131. %doc COPYING-GPL COPYING-OSL README
  132. %doc src/bin/getopts_LICENSE.txt src/include/smbios/config/boost_LICENSE_1_0_txt
  133. %doc doc/pkgheader.sh
  134. %dir %{_sysconfdir}/libsmbios
  135. %config(noreplace) %{_sysconfdir}/libsmbios/*
  136. # python utilities
  137. %{_sbindir}/smbios-sys-info
  138. %{_sbindir}/smbios-token-ctl
  139. %{_sbindir}/smbios-passwd
  140. %{_sbindir}/smbios-wakeup-ctl
  141. %{_sbindir}/smbios-wireless-ctl
  142. %{_sbindir}/smbios-rbu-bios-update
  143. %{_sbindir}/smbios-lcd-brightness
  144. %{_sbindir}/smbios-keyboard-ctl
  145. %{_sbindir}/smbios-thermal-ctl
  146. # symlinks: backwards compat
  147. %{_sbindir}/dellLcdBrightness
  148. %{_sbindir}/getSystemId
  149. %{_sbindir}/dellWirelessCtl
  150. %{_sbindir}/dellBiosUpdate
  151. # used by HAL in old location, so keep it around until HAL is updated.
  152. %{_bindir}/dellWirelessCtl
  153. # data files
  154. %{_datadir}/smbios-utils
  155. EOF
  156. %clean
  157. rm -rf %{buildroot}
  158. %post -n %{release_name} -p /sbin/ldconfig
  159. %postun -n %{release_name} -p /sbin/ldconfig
  160. %files -f _build/%{lang_dom}.lang
  161. %defattr(-,root,root,-)
  162. %{_libdir}/libsmbios_c.so.*
  163. %{_libdir}/libsmbios.so.*
  164. %files -n libsmbios-devel -f _build/buildlogs.txt
  165. %defattr(-,root,root,-)
  166. %doc COPYING-GPL COPYING-OSL README src/bin/getopts_LICENSE.txt src/include/smbios/config/boost_LICENSE_1_0_txt
  167. %{_includedir}/smbios
  168. %{_includedir}/smbios_c
  169. %{_libdir}/libsmbios.so
  170. %{_libdir}/libsmbios_c.so
  171. %{_libdir}/pkgconfig/*.pc
  172. %doc _build/out/libsmbios_c++-%{_arch}
  173. %doc _build/out/libsmbios_c-%{_arch}
  174. %files -n smbios-utils
  175. # opensuse 11.1 enforces non-empty file list :(
  176. %defattr(-,root,root,-)
  177. %doc COPYING-GPL COPYING-OSL README
  178. # no other files.
  179. %files -n smbios-utils-bin
  180. %defattr(-,root,root,-)
  181. %doc COPYING-GPL COPYING-OSL README
  182. %doc src/bin/getopts_LICENSE.txt src/include/smbios/config/boost_LICENSE_1_0_txt
  183. %doc doc/pkgheader.sh
  184. #
  185. # legacy C++
  186. %{_sbindir}/dellBiosUpdate-compat
  187. %{_sbindir}/dellLEDCtl
  188. %ifnarch ia64
  189. %{_sbindir}/dellMediaDirectCtl
  190. %endif
  191. #
  192. # new C utilities
  193. %{_sbindir}/smbios-state-byte-ctl
  194. %{_sbindir}/smbios-get-ut-data
  195. %{_sbindir}/smbios-upflag-ctl
  196. %{_sbindir}/smbios-sys-info-lite
  197. %files -n python-smbios -f _build/files-python-smbios
  198. %defattr(-,root,root,-)
  199. %files -n smbios-utils-python -f _build/files-smbios-utils-python
  200. %defattr(-,root,root,-)
  201. %changelog
  202. * Sat Jul 2 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.3.0-1
  203. - new upstream release.
  204. * Tue Feb 24 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 2.2.28-2
  205. - rebuilt on current VineSeed
  206. - added Japanese summary
  207. * Thu Feb 16 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.2.28-1
  208. - update to 2.2.28
  209. * Sun Apr 24 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 2.2.26-1
  210. - merged with upstream package
  211. * Sat May 24 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 2.0.1-3
  212. - initial build for Vine Linux
  213. * Mon Sep 27 2010 Matt Domsch <mdomsch@fedoraproject.org> - 2.2.26-3
  214. - build for Fedora 15
  215. * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 2.2.19-2
  216. - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
  217. * Fri Jul 06 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.26-1
  218. - implement CSV export of token settings from smbios-token-ctl
  219. * Fri Jul 06 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.25-1
  220. - Fix breakage resulting from improperly fixing up constructors for MemoryAccess/CmosAccess. Fixes CLI utilities.
  221. * Fri Jun 11 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.23-1
  222. - Fixup ABI break where a couple functions that should have been exported were not marked.
  223. * Thu Jun 10 2010 Michael Brown <michael-e_brown at dell.com> - 2.2.22-1
  224. - 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
  225. - enable service tag SET for machines that still set service tag in CMOS
  226. - 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.
  227. * Mon May 18 2009 Matt Domsch <Matt_Domsch@dell.com> - 2.2.16-3
  228. - split yum plugin into yum-dellsysid package
  229. * Mon Mar 24 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.16-1
  230. - add gcc 4.4 support
  231. * Mon Mar 24 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.15-1
  232. - update to lastest upstream.
  233. - fixes bug in bios update on systems with versions like x.y.z.
  234. * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.2.13-2
  235. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  236. * Tue Feb 3 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.12-1
  237. - Add feature to turn on debugging printf()'s without recompiling by setting
  238. certain environment variables:
  239. LIBSMBIOS_C_DEBUG_OUTPUT_ALL -- all debugging output
  240. or, per module:
  241. LIBSMBIOS_C_DEBUG_CONSTRUCTOR_C
  242. LIBSMBIOS_C_DEBUG_SYSINFO_C
  243. LIBSMBIOS_C_DEBUG_SMBIOS_C
  244. LIBSMBIOS_C_DEBUG_TOKEN_C
  245. LIBSMBIOS_C_DEBUG_MEMORY_C
  246. LIBSMBIOS_C_DEBUG_CMOS_C
  247. LIBSMBIOS_C_DEBUG_SMI_C
  248. * Mon Feb 2 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.12-1
  249. - Add pkgconfig files to -devel
  250. - fixup yum plugin to not parse certain data that causes a crash on some machines (Optiplex 755, others may be affected)
  251. * Thu Jan 15 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.8-1
  252. - revert change in upstream renaming rpm to libsmbios2
  253. * Thu Jan 15 2009 Michael E Brown <michael_e_brown at dell.com> - 2.2.7-1
  254. - change source to bz2 format
  255. - Update to latest upstream release. Many changes in the new release:
  256. - python interface
  257. - libsmbios_c interface almost fully implemented
  258. - libsmbios c++ interface deprecated
  259. * Tue Oct 28 2008 Michael E Brown <michael_e_brown at dell.com> - 2.2.0-1
  260. - Spec updates
  261. * Mon Apr 21 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.1-2.1
  262. - obsolete libsmbios-libs as well
  263. * Mon Mar 3 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.1-2
  264. - properly obsolete older versions
  265. * Wed Feb 13 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.1
  266. - Fixup GCC 4.3 compile issues.
  267. * Wed Jan 9 2008 Michael E Brown <michael_e_brown at dell.com> - 2.0.0
  268. - ABI incompatible, minor API changes
  269. - sync up libsmbios soname with version #
  270. - move binaries to /usr/sbin as they are only runnable by root
  271. - drop libsmbiosxml lib as it was mostly unused.
  272. - drop autotools generated files out of git and add autogen.sh
  273. - drop tokenCtl binary-- pysmbios has a *much* improved version
  274. * Wed Aug 22 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.9
  275. - Fix a couple of failure-to-check-return on fopen. most were unit-test code
  276. only, but two or three were in regular code.
  277. - Add hinting to the memory class, so that it can intelligently close /dev/mem
  278. file handle when it is not needed (which is most of the time). it only
  279. leaves it open when it is scanning, so speed is not impacted.
  280. * Tue Aug 6 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.8
  281. - new upstream
  282. * Tue Apr 3 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.6
  283. - critical bugfix for dellBiosUpdate utility for packet mode
  284. - autoconf/automake support for automatically building docs
  285. - more readable 'make' lines by splitting out env vars
  286. - remove run_cppunit option... always run unit tests.
  287. - update autoconf/automake utilities to latest version
  288. - fix LDFLAGS to not overwrite user entered LDFLAGS
  289. - add automatic doxygen build of docs
  290. - fix urls of public repos
  291. - remove yum repo page in favor of official page from docs
  292. - split dmi table entry point from smbios table entry point
  293. - support legacy _DMI_ tables
  294. - fix support for EFI-based imacs without proper _SM_ anchor
  295. * Tue Mar 20 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.5
  296. - rpmlint cleanups
  297. - Add dellLEDCtl binary
  298. - update AUTHORS file to add credit for dellLEDCtl
  299. - update doc/DellToken.txt to add a few more useful tokens.
  300. - updated build system to create documentation
  301. - skip cppunit dep on .elX builds (not in EPEL yet)
  302. * Mon Mar 12 2007 Michael E Brown <michael_e_brown at dell.com> - 0.13.4-1
  303. - Added dellWirelessCtl binary
  304. - Added 'static' makefile target to build static binaries and clean them as well
  305. - fix for signed/unsigned bug in probes binary. CPU temp misreported
  306. - simplify interface for DELL_CALLING_INTERFACE_SMI, autodetect Port/Magic
  307. - document all of the tokens for controlling wireless on dell notebooks
  308. - enums for SMI args/res to make code match docs better (cbRES1 = res[0], which
  309. was confusing.
  310. - helper functions isTokenActive() and activateToken() to simplify token API.
  311. - Added missing windows .cpp files to the dist tarball for those who compile
  312. windows from dist tarball vs source control
  313. - Add support for EFI based machines without backwards compatible smbios table
  314. entry point in 0xF0000 block.
  315. - Added wirelessSwitchControl() and wirelessRadioControl() API for newer
  316. laptops.
  317. - fixed bug in TokenDA activate() code where it wasnt properly using SMI
  318. (never worked, but apparently wasnt used until now.)
  319. * Tue Oct 3 2006 Michael E Brown <Michael_E_Brown@Dell.com> - 0.13.0-1
  320. - autotools conversion
  321. - add Changelog
  322. * Tue Sep 26 2006 Michael E Brown <michael_e_brown at dell.com> - 0.12.4-1
  323. - Changes per Fedora Packaging Guidelines to prepare to submit to Extras.
  324. - Add in a changelog entry per Fedora Packaging Guidelines...