We simplified the SRC_URI handling via https://gitweb.gentoo.org/repo/gentoo.git/commit/dev-lang/php?id=1402e128c523180f57ce7bc22567ca28b6930a9f but it seems like we lost an easy way to test new PHP versions. Before, it was enough to copy php-7.0.x.ebuild to php-7.0.y_rc1.ebuild and it worked. It would be great to make it easy to test new alpha/beta/rc releases. Thank you
It should only be a two-line change... that function I removed was the worst of both worlds: it was larger than the code it replaced *and* it had to be copy/pasted into each ebuild, so it didn't deduplicate the logic. If we ever have another beta or rc in the tree, this is probably the extent of what I'll do. It makes the pre-release ebuilds different by two lines, but it saves us from having to copy/paste a big function into every ebuild. (The S=... line even works for the stable releases, so it could be a one-line difference.) 7.0.9-r2.ebuild php-7.1.0_beta2.ebuild --- php-7.0.9-r2.ebuild 2016-08-05 18:36:25.725030125 -0400 +++ php-7.1.0_beta2.ebuild 2016-08-16 19:07:46.696582893 -0400 @@ -8,7 +8,8 @@ DESCRIPTION="The PHP language runtime engine" HOMEPAGE="http://php.net/" -SRC_URI="http://php.net/distributions/${P}.tar.xz" +SRC_URI="https://downloads.php.net/~davey/${P/_/}.tar.xz" +S="${WORKDIR}/${P/_/}" LICENSE="PHP-3" SLOT="$(get_version_component_range 1-2)" KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
The sad thing is that rc versions are upper case, so this will not work on that case. And many of the different RC/beta releases are on different places (developers homedirs). The only place it's consistent is github actually (except the case difference in alpha/beta vs RC). I know that we can test new releases by changing the ebuild, I was just referring to that before it was possible to do it without changing the ebuild at all. Maybe we will never have those versions in the official tree, but I like to deploy rc versions to our developers so they can test it and it was "super easy". But I understand that the code was a bit messy, thanks for taking care of php ;)
(In reply to Tomáš Mózes from comment #2) > The sad thing is that rc versions are upper case, so this will not work on > that case. Use uppercase "RC" in the ebuild file name =) If you really prefer it lowercase, you can do something like... MY_P="${P/_/}"; MY_P="${MY_P/rc/RC}" and the use $MY_P instead of $P in $SRC_URI and $S. That should work on alphas and betas, too. > And many of the different RC/beta releases are on different > places (developers homedirs). The only place it's consistent is github > actually (except the case difference in alpha/beta vs RC). The php_get_uri() function that we have in php-5.6.24.ebuild doesn't work on the newer alphas/betas either, so you would still have to write your own SRC_URI for those. I don't think the location for pre-releases will ever be consistent.
(In reply to Michael Orlitzky from comment #3) > (In reply to Tomáš Mózes from comment #2) > > The sad thing is that rc versions are upper case, so this will not work on > > that case. > > Use uppercase "RC" in the ebuild file name =) Yes I was trying to, but: # ebuild php-7.0.10_RC1.ebuild manifest ebuild: php-7.0.10_RC1.ebuild: dev-lang/php-7.0.10_RC1: does not follow correct package syntax > > If you really prefer it lowercase, you can do something like... > > MY_P="${P/_/}"; MY_P="${MY_P/rc/RC}" > > and the use $MY_P instead of $P in $SRC_URI and $S. That should work on > alphas and betas, too. > > > And many of the different RC/beta releases are on different > > places (developers homedirs). The only place it's consistent is github > > actually (except the case difference in alpha/beta vs RC). > > The php_get_uri() function that we have in php-5.6.24.ebuild doesn't work on > the newer alphas/betas either, so you would still have to write your own > SRC_URI for those. I don't think the location for pre-releases will ever be > consistent. Only if we use github :)
(In reply to Tomáš Mózes from comment #4) > > > > The php_get_uri() function that we have in php-5.6.24.ebuild doesn't work on > > the newer alphas/betas either, so you would still have to write your own > > SRC_URI for those. I don't think the location for pre-releases will ever be > > consistent. > > Only if we use github :) The pre- and github releases are all missing the pre-generated autotools files that come with the final releases on php.net. As a result, the pre-releases have a few more dependencies (like bison, flex, m4, and libtool) than the final releases. Moreover, an ebuild for the pre-releases needs to inherit autotools.eclass and run eautoreconf to generate "./configure" and friends. Until now, we inherited that eclass anyway, but I'm afraid I just made a move in the opposite direction with v7.1.0. By fixing an upstream bug (heimdal detection), I was able to clean house in src_prepare and ultimately eliminate autotools.eclass from the php-7.1.0 ebuild. I also cleaned up the dependencies, so now the 7.1.0 ebuild is truly unfit to be used for a pre- or github release. I just pushed the new version a few minutes ago, so who knows what will happen, but if it looks like we can keep the simplified ebuild for the releases in the tree, I may have to eventually call it and just say that we won't do this. Sorry =(
Thanks for the explanation,I wasn't aware of these information. Let's close it then :) and thanks for bumping 7.1.0, our devs were already asking for it :)