1 |
commit: d89fb81ef89345975383a728e7f3c1f783afcdee |
2 |
Author: Tomáš Mózes <hydrapolic <AT> gmail <DOT> com> |
3 |
AuthorDate: Tue May 19 10:55:07 2020 +0000 |
4 |
Commit: Yixun Lan <dlan <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon May 25 14:20:17 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d89fb81e |
7 |
|
8 |
app-emulation/xen-pvgrub: bump to 4.12.3 |
9 |
|
10 |
Closes: https://github.com/gentoo/gentoo/pull/15857 |
11 |
Signed-off-by: Tomáš Mózes <hydrapolic <AT> gmail.com> |
12 |
Signed-off-by: Yixun Lan <dlan <AT> gentoo.org> |
13 |
|
14 |
app-emulation/xen-pvgrub/Manifest | 1 + |
15 |
app-emulation/xen-pvgrub/xen-pvgrub-4.12.3.ebuild | 150 ++++++++++++++++++++++ |
16 |
2 files changed, 151 insertions(+) |
17 |
|
18 |
diff --git a/app-emulation/xen-pvgrub/Manifest b/app-emulation/xen-pvgrub/Manifest |
19 |
index 909f0c5ed45..78ebc93c743 100644 |
20 |
--- a/app-emulation/xen-pvgrub/Manifest |
21 |
+++ b/app-emulation/xen-pvgrub/Manifest |
22 |
@@ -4,5 +4,6 @@ DIST newlib-1.16.0.tar.gz 12024353 BLAKE2B 26d3308148fb99baf8ad02eee4cc699cfac69 |
23 |
DIST pciutils-2.2.9.tar.bz2 212265 BLAKE2B 014b664e90c64e7255c9e21fc25a2cc60d57f47ce282fc0331a0481a460b237783bd3774dd0689e1596d4a0be0d2889faad904da01a6f02147464bce1d1b1bc0 SHA512 2b3d98d027e46d8c08037366dde6f0781ca03c610ef2b380984639e4ef39899ed8d8b8e4cd9c9dc54df101279b95879bd66bfd4d04ad07fef41e847ea7ae32b5 |
24 |
DIST polarssl-1.1.4-gpl.tgz 611340 BLAKE2B 613da06dda9e4b86db5a4d616a0a0afee98c907c3c6b352eed3d9e500fc5739e62eb4f6fc32ff02579c6a6de9bd49fcd2c8bd8b2d158a5050cbaa82118d61ef0 SHA512 88da614e4d3f4409c4fd3bb3e44c7587ba051e3fed4e33d526069a67e8180212e1ea22da984656f50e290049f60ddca65383e5983c0f8884f648d71f698303ad |
25 |
DIST xen-4.12.2.tar.gz 26985135 BLAKE2B 530821011a6dd0ac0a99fb135ff5311eb8e975c3791818093b5e250eed7854d153de6d4340197f9b949c0ad2c3d7b2b7180deb42bc71748ff70ff6fad195269d SHA512 7d9e7921271830c9eadf1bb8eca1aec20d343ad7475b0dc3165ef6d681759e7cb70739f8d9f85622a23aef960988820e822267fb198b12ee3dd657ad6164069f |
26 |
+DIST xen-4.12.3.tar.gz 26985230 BLAKE2B 403de519a552f1cd49e5a85b63f48df1b7a47ff8381385860b67df32af0b33be1c13c92ca2234e4479b7f415e711e0f46c396c3f62dfb5b2465d2991723cf6ef SHA512 7bbf4e752477f18143ac9a62fb633b1fbe115a1a9b03d0132f33dfca025bc9b76d9c2e9b66a3e407d14aff161b940b1a82e3e3ca43213798e9dd38b6970194e0 |
27 |
DIST xen-4.13.0.tar.gz 39005191 BLAKE2B cd85bfe549e20447afb8ec6b2ab33ea1893f45392c08737730d7898706748ebb96b2e842b2ff3e4af8c5d8a705e6d25a2bfb8acf0d7cc771805d0cc97757a949 SHA512 5b2ded9a2fe3f7ddf40eed1fa9858baead06233a01eb6099cc45b3c78b6c3823acfe7b731910733e87125dfa49d08c53f74c215fb1b320a92b44b87a0a105225 |
28 |
DIST zlib-1.2.3.tar.gz 496597 BLAKE2B 603020b70cd52b83e48bde420b86e2acfd29d69bf7476eecbeeb07d1b8bcab703d2cbd3eab77772990bddb8c268f13594592ce985798d49e2d6ba25104d49f22 SHA512 021b958fcd0d346c4ba761bcf0cc40f3522de6186cf5a0a6ea34a70504ce9622b1c2626fce40675bc8282cf5f5ade18473656abc38050f72f5d6480507a2106e |
29 |
|
30 |
diff --git a/app-emulation/xen-pvgrub/xen-pvgrub-4.12.3.ebuild b/app-emulation/xen-pvgrub/xen-pvgrub-4.12.3.ebuild |
31 |
new file mode 100644 |
32 |
index 00000000000..90ff022902e |
33 |
--- /dev/null |
34 |
+++ b/app-emulation/xen-pvgrub/xen-pvgrub-4.12.3.ebuild |
35 |
@@ -0,0 +1,150 @@ |
36 |
+# Copyright 1999-2020 Gentoo Authors |
37 |
+# Distributed under the terms of the GNU General Public License v2 |
38 |
+ |
39 |
+EAPI=7 |
40 |
+ |
41 |
+PYTHON_COMPAT=( python2_7 ) |
42 |
+PYTHON_REQ_USE='xml,threads' |
43 |
+ |
44 |
+inherit flag-o-matic multilib python-single-r1 toolchain-funcs |
45 |
+ |
46 |
+XEN_EXTFILES_URL="http://xenbits.xensource.com/xen-extfiles" |
47 |
+LIBPCI_URL=ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci |
48 |
+GRUB_URL=mirror://gnu-alpha/grub |
49 |
+ |
50 |
+UPSTREAM_VER= |
51 |
+[[ -n ${UPSTREAM_VER} ]] && \ |
52 |
+ UPSTREAM_PATCHSET_URI="https://dev.gentoo.org/~dlan/distfiles/${P/-pvgrub/}-upstream-patches-${UPSTREAM_VER}.tar.xz |
53 |
+ https://github.com/hydrapolic/gentoo-dist/raw/master/xen/${P/-pvgrub/}-upstream-patches-${UPSTREAM_VER}.tar.xz" |
54 |
+ |
55 |
+SRC_URI=" |
56 |
+ https://downloads.xenproject.org/release/xen/${PV}/xen-${PV}.tar.gz |
57 |
+ $GRUB_URL/grub-0.97.tar.gz |
58 |
+ $XEN_EXTFILES_URL/zlib-1.2.3.tar.gz |
59 |
+ $LIBPCI_URL/pciutils-2.2.9.tar.bz2 |
60 |
+ $XEN_EXTFILES_URL/lwip-1.3.0.tar.gz |
61 |
+ $XEN_EXTFILES_URL/newlib/newlib-1.16.0.tar.gz |
62 |
+ $XEN_EXTFILES_URL/polarssl-1.1.4-gpl.tgz |
63 |
+ ${UPSTREAM_PATCHSET_URI}" |
64 |
+ |
65 |
+S="${WORKDIR}/xen-${PV}" |
66 |
+ |
67 |
+DESCRIPTION="allows to boot Xen domU kernels from a menu.lst laying inside guest filesystem" |
68 |
+HOMEPAGE="https://www.xenproject.org" |
69 |
+LICENSE="GPL-2" |
70 |
+SLOT="0" |
71 |
+KEYWORDS="~amd64 ~x86" |
72 |
+IUSE="" |
73 |
+ |
74 |
+REQUIRED_USE="${PYTHON_REQUIRED_USE}" |
75 |
+ |
76 |
+DEPEND="sys-devel/gettext |
77 |
+ sys-devel/bin86 |
78 |
+ sys-apps/texinfo |
79 |
+ x11-libs/pixman" |
80 |
+ |
81 |
+RDEPEND="${PYTHON_DEPS} |
82 |
+ >=app-emulation/xen-tools-${PV}" |
83 |
+ |
84 |
+pkg_setup() { |
85 |
+ python-single-r1_pkg_setup |
86 |
+} |
87 |
+ |
88 |
+retar-externals() { |
89 |
+ # Purely to unclutter src_prepare |
90 |
+ local set="grub-0.97.tar.gz lwip-1.3.0.tar.gz newlib-1.16.0.tar.gz polarssl-1.1.4-gpl.tgz zlib-1.2.3.tar.gz" |
91 |
+ |
92 |
+ # eapply can't patch in $WORKDIR, requires a sed; Bug #455194. Patchable, but sed informative |
93 |
+ sed -e s':AR=${AR-"ar rc"}:AR=${AR-"ar"}:' \ |
94 |
+ -i "${WORKDIR}"/zlib-1.2.3/configure || die |
95 |
+ sed -e 's:^AR=ar rc:AR=ar:' \ |
96 |
+ -e s':$(AR) $@:$(AR) rc $@:' \ |
97 |
+ -i "${WORKDIR}"/zlib-1.2.3/{Makefile,Makefile.in} || die |
98 |
+ einfo "zlib Makefile edited" |
99 |
+ |
100 |
+ cd "${WORKDIR}" || die |
101 |
+ tar czp zlib-1.2.3 -f zlib-1.2.3.tar.gz || die |
102 |
+ tar czp grub-0.97 -f grub-0.97.tar.gz || die |
103 |
+ tar czp lwip -f lwip-1.3.0.tar.gz || die |
104 |
+ tar czp newlib-1.16.0 -f newlib-1.16.0.tar.gz || die |
105 |
+ tar czp polarssl-1.1.4 -f polarssl-1.1.4-gpl.tgz || die |
106 |
+ mv $set "${S}"/stubdom/ || die |
107 |
+ einfo "tarballs moved to source" |
108 |
+} |
109 |
+ |
110 |
+src_prepare() { |
111 |
+ # Upstream's patchset |
112 |
+ if [[ -n ${UPSTREAM_VER} ]]; then |
113 |
+ einfo "Try to apply Xen Upstream patch set" |
114 |
+ EPATCH_SUFFIX="patch" \ |
115 |
+ EPATCH_FORCE="yes" \ |
116 |
+ EPATCH_OPTS="-p1" \ |
117 |
+ eapply "${WORKDIR}"/patches-upstream |
118 |
+ fi |
119 |
+ |
120 |
+ # Patch the unmergeable newlib, fix most of the leftover gcc QA issues |
121 |
+ cp "${FILESDIR}"/newlib-implicits.patch stubdom || die |
122 |
+ |
123 |
+ # Patch stubdom/Makefile to patch insource newlib & prevent internal downloading |
124 |
+ eapply "${FILESDIR}"/${PN/-pvgrub/}-4.10-externals.patch |
125 |
+ |
126 |
+ # fix jobserver in Makefile |
127 |
+ eapply "${FILESDIR}"/${PN}-4.8-jserver.patch |
128 |
+ |
129 |
+ #Substitute for internal downloading. pciutils copied only due to the only .bz2 |
130 |
+ cp "${DISTDIR}"/pciutils-2.2.9.tar.bz2 ./stubdom/ || die "pciutils not copied to stubdom" |
131 |
+ retar-externals || die "re-tar procedure failed" |
132 |
+ |
133 |
+ default |
134 |
+} |
135 |
+ |
136 |
+src_configure() { |
137 |
+ local myconf="--prefix=${PREFIX}/usr \ |
138 |
+ --libdir=${PREFIX}/usr/$(get_libdir) \ |
139 |
+ --libexecdir=${PREFIX}/usr/libexec \ |
140 |
+ --disable-werror \ |
141 |
+ --disable-xen" |
142 |
+ |
143 |
+ econf ${myconf} |
144 |
+} |
145 |
+ |
146 |
+src_compile() { |
147 |
+ unset CFLAGS |
148 |
+ if test-flag-CC -fno-strict-overflow; then |
149 |
+ append-flags -fno-strict-overflow |
150 |
+ fi |
151 |
+ |
152 |
+ emake CC="$(tc-getCC)" LD="$(tc-getLD)" AR="$(tc-getAR)" -C tools/include |
153 |
+ emake CC="$(tc-getCC)" LD="$(tc-getLD)" AR="$(tc-getAR)" -C tools/libs |
154 |
+ |
155 |
+ if use x86; then |
156 |
+ emake CC="$(tc-getCC)" LD="$(tc-getLD)" AR="$(tc-getAR)" \ |
157 |
+ XEN_TARGET_ARCH="x86_32" -C stubdom pv-grub |
158 |
+ elif use amd64; then |
159 |
+ emake CC="$(tc-getCC)" LD="$(tc-getLD)" AR="$(tc-getAR)" \ |
160 |
+ XEN_TARGET_ARCH="x86_64" -C stubdom pv-grub |
161 |
+ if has_multilib_profile; then |
162 |
+ multilib_toolchain_setup x86 |
163 |
+ emake CC="$(tc-getCC)" AR="$(tc-getAR)" \ |
164 |
+ XEN_TARGET_ARCH="x86_32" -C stubdom pv-grub |
165 |
+ fi |
166 |
+ fi |
167 |
+} |
168 |
+ |
169 |
+src_install() { |
170 |
+ if use x86; then |
171 |
+ emake XEN_TARGET_ARCH="x86_32" DESTDIR="${D}" -C stubdom install-grub |
172 |
+ fi |
173 |
+ if use amd64; then |
174 |
+ emake XEN_TARGET_ARCH="x86_64" DESTDIR="${D}" -C stubdom install-grub |
175 |
+ if has_multilib_profile; then |
176 |
+ emake XEN_TARGET_ARCH="x86_32" DESTDIR="${D}" -C stubdom install-grub |
177 |
+ fi |
178 |
+ fi |
179 |
+} |
180 |
+ |
181 |
+pkg_postinst() { |
182 |
+ elog "Official Xen Guide and the offical wiki page:" |
183 |
+ elog "https://wiki.gentoo.org/wiki/Xen" |
184 |
+ elog "https://wiki.xen.org/wiki/Main_Page" |
185 |
+} |