Message ID | 1472660696-21640-1-git-send-email-fabrice.fontaine@orange.com |
---|---|
State | Superseded |
Headers | show |
> From: "Fabrice Fontaine" <fontaine.fabrice@gmail.com> > To: buildroot@buildroot.org > Cc: "Fabrice Fontaine" <fabrice.fontaine@orange.com> > Sent: Wednesday, August 31, 2016 1:24:56 PM > Subject: [Buildroot] [PATCH 6/6] gtest: retrieve package from github > https://googletest.googlecode.com/files is no more available, so update > gtest.mk and gtest.hash to retrieve googletest source code as a tar.gz > (and not a zip) from github as https://googletest.googlecode.com is now > a redirection to https://github.com/google/googletest. > > Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com> > --- > package/gtest/gtest.hash | 4 ++-- > package/gtest/gtest.mk | 9 ++------- > 2 files changed, 4 insertions(+), 9 deletions(-) > > diff --git a/package/gtest/gtest.hash b/package/gtest/gtest.hash > index 8ff79cb..79e31e4 100644 > --- a/package/gtest/gtest.hash > +++ b/package/gtest/gtest.hash > @@ -1,2 +1,2 @@ > -# From > http://code.google.com/p/googletest/downloads/detail?name=gtest-1.7.0.zip&can=2&q= > -sha1 f85f6d2481e2c6c4a18539e391aa4ea8ab0394af gtest-1.7.0.zip > +# Locally computed: > +sha256 f73a6546fdf9fce9ff93a5015e0333a8af3062a152a9ad6bcb772c96687016cc > gtest-release-1.7.0.tar.gz > diff --git a/package/gtest/gtest.mk b/package/gtest/gtest.mk > index 11aa7e9..eb30905 100644 > --- a/package/gtest/gtest.mk > +++ b/package/gtest/gtest.mk > @@ -5,9 +5,8 @@ > ################################################################################ > > # Make sure this remains the same version as the gmock one > -GTEST_VERSION = 1.7.0 > -GTEST_SOURCE = gtest-$(GTEST_VERSION).zip > -GTEST_SITE = http://googletest.googlecode.com/files > +GTEST_VERSION = release-1.7.0 > +GTEST_SITE = $(call github,google,googletest,$(GTEST_VERSION)) > GTEST_INSTALL_STAGING = YES > GTEST_INSTALL_TARGET = NO > GTEST_LICENSE = BSD-3c > @@ -22,10 +21,6 @@ GTEST_LICENSE_FILES = LICENSE > # the gtest sources. > GTEST_CONF_OPTS = -DBUILD_SHARED_LIBS=OFF > > -define GTEST_EXTRACT_CMDS > - $(UNZIP) $(DL_DIR)/$(GTEST_SOURCE) -d $(BUILD_DIR) > -endef > - > define GTEST_INSTALL_STAGING_CMDS > $(INSTALL) -D -m 0755 $(@D)/libgtest.a $(STAGING_DIR)/usr/lib/libgtest.a > $(INSTALL) -D -m 0755 $(@D)/libgtest_main.a > $(STAGING_DIR)/usr/lib/libgtest_main.a > -- > 2.7.4 GMock needs to be fixed too. I attempted to do this before (http://patchwork.ozlabs.org/patch/586130/) but it was refused, unfortunately. Carlos Santos (Casantos) DATACOM, P&D
On 06-09-16 15:58, Carlos Santos wrote: >> From: "Fabrice Fontaine" <fontaine.fabrice@gmail.com> >> To: buildroot@buildroot.org >> Cc: "Fabrice Fontaine" <fabrice.fontaine@orange.com> >> Sent: Wednesday, August 31, 2016 1:24:56 PM >> Subject: [Buildroot] [PATCH 6/6] gtest: retrieve package from github > >> https://googletest.googlecode.com/files is no more available, so update >> gtest.mk and gtest.hash to retrieve googletest source code as a tar.gz >> (and not a zip) from github as https://googletest.googlecode.com is now >> a redirection to https://github.com/google/googletest. >> >> Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com> [snip] > GMock needs to be fixed too. I attempted to do this before (http://patchwork.ozlabs.org/patch/586130/) but it was refused, unfortunately. Quoting Yann from that patchwork entry: > As I understand it, gtest and gmock are being phased out as separate > packages, and are to be replaced with the googletest package. > > So why don't we directly add "googletest" and get rid of gtest and > gmock, rather than fix them to eventually get rid of them? In that contet, I think it's a sane idea to have this commit as a first step, and do the bump to v1.8.0 (which implies merging gtest and gmock) in a second step. Fabrice, care to work on that? If you do, here are some tips: - GMOCK should become a suboption of GTEST: BR2_PACKAGE_GTEST_GMOCK. - A legacy entry should be added for it. - gmock now has a usable cmake and builds gtest implicitly. - host-gmock is tricky - but perhaps it's no longer needed. Regards, Arnout
> From: "fabrice fontaine" <fabrice.fontaine@orange.com> > To: "Arnout Vandecappelle" <arnout@mind.be>, "Carlos Santos" <casantos@datacom.ind.br>, "Fabrice Fontaine" > <fontaine.fabrice@gmail.com> > Cc: buildroot@buildroot.org > Sent: Wednesday, September 7, 2016 11:40:24 AM > Subject: RE: [Buildroot] [PATCH 6/6] gtest: retrieve package from github > Dear Arnout, > > I sent a new patch merging gmock inside gtest. > However, I did not quite understand what is a "legacy entry", did you mean that > we should keep a package/gmock/Config.in with a BR2_PACKAGE_GMOCK that should > enable BR2_PACKAGE_GTEST_GMOCK? A legacy entry would be an entry in Config.in.legacy, Read the description at the beginning of that file. Carlos Santos (Casantos) DATACOM, P&D
> From: "Arnout Vandecappelle" <arnout@mind.be> > To: "Carlos Santos" <casantos@datacom.ind.br>, "Fabrice Fontaine" <fontaine.fabrice@gmail.com> > Cc: "Fabrice Fontaine" <fabrice.fontaine@orange.com>, buildroot@buildroot.org > Sent: Tuesday, September 6, 2016 5:40:58 PM > Subject: Re: [Buildroot] [PATCH 6/6] gtest: retrieve package from github > On 06-09-16 15:58, Carlos Santos wrote: >>> From: "Fabrice Fontaine" <fontaine.fabrice@gmail.com> >>> To: buildroot@buildroot.org >>> Cc: "Fabrice Fontaine" <fabrice.fontaine@orange.com> >>> Sent: Wednesday, August 31, 2016 1:24:56 PM >>> Subject: [Buildroot] [PATCH 6/6] gtest: retrieve package from github >> >>> https://googletest.googlecode.com/files is no more available, so update >>> gtest.mk and gtest.hash to retrieve googletest source code as a tar.gz >>> (and not a zip) from github as https://googletest.googlecode.com is now >>> a redirection to https://github.com/google/googletest. >>> >>> Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com> > [snip] >> GMock needs to be fixed too. I attempted to do this before >> (http://patchwork.ozlabs.org/patch/586130/) but it was refused, unfortunately. > > Quoting Yann from that patchwork entry: >> As I understand it, gtest and gmock are being phased out as separate >> packages, and are to be replaced with the googletest package. >> >> So why don't we directly add "googletest" and get rid of gtest and >> gmock, rather than fix them to eventually get rid of them? > > In that contet, I think it's a sane idea to have this commit as a first step, > and do the bump to v1.8.0 (which implies merging gtest and gmock) in a second > step. It can be done, even though I don't think it's really necessary to do this. > Fabrice, care to work on that? If you do, here are some tips: > > - GMOCK should become a suboption of GTEST: BR2_PACKAGE_GTEST_GMOCK. > - A legacy entry should be added for it. > - gmock now has a usable cmake and builds gtest implicitly. > - host-gmock is tricky - but perhaps it's no longer needed. I just sent an updated patch with a proposed solution for the gmock host-gmock packages using virtual packages, so no legacy entry is necessary. Carlos Santos (Casantos) DATACOM, P&D
diff --git a/package/gtest/gtest.hash b/package/gtest/gtest.hash index 8ff79cb..79e31e4 100644 --- a/package/gtest/gtest.hash +++ b/package/gtest/gtest.hash @@ -1,2 +1,2 @@ -# From http://code.google.com/p/googletest/downloads/detail?name=gtest-1.7.0.zip&can=2&q= -sha1 f85f6d2481e2c6c4a18539e391aa4ea8ab0394af gtest-1.7.0.zip +# Locally computed: +sha256 f73a6546fdf9fce9ff93a5015e0333a8af3062a152a9ad6bcb772c96687016cc gtest-release-1.7.0.tar.gz diff --git a/package/gtest/gtest.mk b/package/gtest/gtest.mk index 11aa7e9..eb30905 100644 --- a/package/gtest/gtest.mk +++ b/package/gtest/gtest.mk @@ -5,9 +5,8 @@ ################################################################################ # Make sure this remains the same version as the gmock one -GTEST_VERSION = 1.7.0 -GTEST_SOURCE = gtest-$(GTEST_VERSION).zip -GTEST_SITE = http://googletest.googlecode.com/files +GTEST_VERSION = release-1.7.0 +GTEST_SITE = $(call github,google,googletest,$(GTEST_VERSION)) GTEST_INSTALL_STAGING = YES GTEST_INSTALL_TARGET = NO GTEST_LICENSE = BSD-3c @@ -22,10 +21,6 @@ GTEST_LICENSE_FILES = LICENSE # the gtest sources. GTEST_CONF_OPTS = -DBUILD_SHARED_LIBS=OFF -define GTEST_EXTRACT_CMDS - $(UNZIP) $(DL_DIR)/$(GTEST_SOURCE) -d $(BUILD_DIR) -endef - define GTEST_INSTALL_STAGING_CMDS $(INSTALL) -D -m 0755 $(@D)/libgtest.a $(STAGING_DIR)/usr/lib/libgtest.a $(INSTALL) -D -m 0755 $(@D)/libgtest_main.a $(STAGING_DIR)/usr/lib/libgtest_main.a
https://googletest.googlecode.com/files is no more available, so update gtest.mk and gtest.hash to retrieve googletest source code as a tar.gz (and not a zip) from github as https://googletest.googlecode.com is now a redirection to https://github.com/google/googletest. Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com> --- package/gtest/gtest.hash | 4 ++-- package/gtest/gtest.mk | 9 ++------- 2 files changed, 4 insertions(+), 9 deletions(-)