Fedora Remix maintained by the Rochester Institute of Technology (RIT) Linux Users Group, targeted at users new to Linux and RIT students, faculty, and staff
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

120 lines
3.9 KiB

7 years ago
  1. %global release_name TigerOS
  2. %global dist_version 25
  3. Summary: TigerOS release files
  4. Name: tigeros-release
  5. Version: 26
  6. Release: 1.0
  7. License: MIT
  8. Group: System Environment/Base
  9. Source0: LICENSE
  10. Source1: README.developers
  11. Source2: README.TigerOS-Release-Notes
  12. Source3: README.license
  13. Source4: 85-display-manager.preset
  14. Source5: 90-default.preset
  15. Source6: 99-default-disable.preset
  16. Obsoletes: redhat-release
  17. Provides: redhat-release
  18. Provides: system-release
  19. Provides: system-release(%{version})
  20. Requires: fedora-repos(%{version})
  21. BuildArch: noarch
  22. Conflicts: fedora-release
  23. %description
  24. TigerOS release files such as yum configs and various /etc/ files that
  25. define the release. This package explicitly is a replacement for the
  26. trademarked release package, if you are unable for any reason to abide by the
  27. trademark restrictions on that release package.
  28. %package notes
  29. Summary: Release Notes
  30. License: Open Publication
  31. Group: System Environment/Base
  32. Provides: system-release-notes = %{version}-%{release}
  33. Conflicts: fedora-release-notes
  34. %description notes
  35. TigerOS release notes package. This package explicitly is a replacement
  36. for the trademarked release-notes package, if you are unable for any reason
  37. to abide by the trademark restrictions on that release-notes
  38. package. Please note that there is no actual useful content here.
  39. %prep
  40. %setup -c -T
  41. cp -a %{SOURCE0} %{SOURCE1} %{SOURCE2} %{SOURCE3} %{SOURCE4} %{SOURCE5} %{SOURCE6} .
  42. %build
  43. %install
  44. install -d %{buildroot}/etc
  45. echo "TigerOS release %{version} (%{release_name})" > %{buildroot}/etc/fedora-release
  46. echo "cpe:/o:TigerOS:TigerOS:%{version}" > %{buildroot}/etc/system-release-cpe
  47. cp -p %{buildroot}/etc/fedora-release %{buildroot}/etc/issue
  48. echo "Kernel \r on an \m (\l)" >> %{buildroot}/etc/issue
  49. cp -p %{buildroot}/etc/issue %{buildroot}/etc/issue.net
  50. echo >> %{buildroot}/etc/issue
  51. ln -s fedora-release %{buildroot}/etc/redhat-release
  52. ln -s fedora-release %{buildroot}/etc/system-release
  53. mkdir -p %{buildroot}/usr/lib/systemd/system-preset/
  54. cat << EOF >>%{buildroot}/usr/lib/os-release
  55. NAME=TigerOS
  56. VERSION="%{version} (%{release_name})"
  57. ID=TigerOS
  58. VERSION_ID=%{version}
  59. PRETTY_NAME="TigerOS %{version} (%{release_name})"
  60. ANSI_COLOR="0;34"
  61. CPE_NAME="cpe:/o:TigerOS:TigerOS:%{version}"
  62. EOF
  63. # Create the symlink for /etc/os-release
  64. ln -s ../usr/lib/os-release %{buildroot}/etc/os-release
  65. # Set up the dist tag macros
  66. install -d -m 755 %{buildroot}%{_rpmconfigdir}/macros.d
  67. cat >> %{buildroot}%{_rpmconfigdir}/macros.d/macros.dist << EOF
  68. # dist macros.
  69. %%fedora %{dist_version}
  70. %%dist .fc%{dist_version}
  71. %%fc%{dist_version} 1
  72. EOF
  73. # Add presets
  74. # Default system wide
  75. install -m 0644 85-display-manager.preset %{buildroot}%{_prefix}/lib/systemd/system-preset/
  76. install -m 0644 90-default.preset %{buildroot}%{_prefix}/lib/systemd/system-preset/
  77. install -m 0644 99-default-disable.preset %{buildroot}%{_prefix}/lib/systemd/system-preset/
  78. %clean
  79. rm -rf %{buildroot}
  80. %files
  81. %defattr(-,root,root,-)
  82. %license LICENSE README.license
  83. %config %attr(0644,root,root) /usr/lib/os-release
  84. /etc/os-release
  85. %config %attr(0644,root,root) /etc/fedora-release
  86. /etc/redhat-release
  87. /etc/system-release
  88. %config %attr(0644,root,root) /etc/system-release-cpe
  89. %config(noreplace) %attr(0644,root,root) /etc/issue
  90. %config(noreplace) %attr(0644,root,root) /etc/issue.net
  91. %attr(0644,root,root) %{_rpmconfigdir}/macros.d/macros.dist
  92. %{_prefix}/lib/systemd/system-preset/85-display-manager.preset
  93. %{_prefix}/lib/systemd/system-preset/90-default.preset
  94. %{_prefix}/lib/systemd/system-preset/99-default-disable.preset
  95. %files notes
  96. %defattr(-,root,root,-)
  97. %doc README.TigerOS-Release-Notes
  98. %changelog
  99. * Wed Aug 30 2017 Aidan Kahrs <axk4545@rit.edu> - 26-1.0
  100. - rebuild for Fedora 26
  101. * Sun Apr 23 2017 Aidan Kahrs <axk4545@rit.edu> 1.0
  102. - initial package for tigeros-release and tigeros-release-notes