Re: git: 4671249405c0 - main - net/rubygem-omniauth-auth0: Fix build failure

From: Po-Chuan Hsieh <sunpoet_at_freebsd.org>
Date: Wed, 06 Jul 2022 14:35:00 UTC
On Thu, Jun 30, 2022 at 10:32 PM Matthias Fechner <mfechner@freebsd.org>
wrote:

> The branch main has been updated by mfechner:
>
> URL:
> https://cgit.FreeBSD.org/ports/commit/?id=4671249405c05bb65dfec261eb645081ea72fdf5
>
> commit 4671249405c05bb65dfec261eb645081ea72fdf5
> Author:     Matthias Fechner <mfechner@FreeBSD.org>
> AuthorDate: 2022-06-30 14:28:33 +0000
> Commit:     Matthias Fechner <mfechner@FreeBSD.org>
> CommitDate: 2022-06-30 14:32:13 +0000
>
>     net/rubygem-omniauth-auth0: Fix build failure


>     Fixes a build regression after:
>     56e085ca55a831ab56e2e6b417bf230c827fd2e5
>

I think this commit is incorrect.
I could build this port successfully with rubygem-omniauth-oauth2 (1.8.0)
Please provide the error message.

Furthermore, the only difference between omniauth-oauth2 1.7.3 and 1.8.0
[1] is the change of omniauth from ">=1.9<3" to ">=2<3"
where security/rubygem-omniauth is 2.1.0 already.
I don't know how it can fix build failure.

[1] https://github.com/omniauth/omniauth-oauth2/compare/v1.7.3...v1.8.0

---
>  net/Makefile                             |  1 +
>  net/rubygem-omniauth-auth0/Makefile      |  2 +-
>  net/rubygem-omniauth-oauth2-v1/Makefile  | 21 +++++++++++++++++++++
>  net/rubygem-omniauth-oauth2-v1/distinfo  |  3 +++
>  net/rubygem-omniauth-oauth2-v1/pkg-descr |  3 +++
>  5 files changed, 29 insertions(+), 1 deletion(-)
>
> diff --git a/net/Makefile b/net/Makefile
> index ff664b428e4c..593acd3099e9 100644
> --- a/net/Makefile
> +++ b/net/Makefile
> @@ -1335,6 +1335,7 @@
>      SUBDIR += rubygem-omniauth-kerberos
>      SUBDIR += rubygem-omniauth-oauth
>      SUBDIR += rubygem-omniauth-oauth2
> +    SUBDIR += rubygem-omniauth-oauth2-v1
>      SUBDIR += rubygem-omniauth-openid
>      SUBDIR += rubygem-omniauth-salesforce
>      SUBDIR += rubygem-omniauth-twitter
> diff --git a/net/rubygem-omniauth-auth0/Makefile
> b/net/rubygem-omniauth-auth0/Makefile
> index 3dcbfe3cfd09..3a599be8b787 100644
> --- a/net/rubygem-omniauth-auth0/Makefile
> +++ b/net/rubygem-omniauth-auth0/Makefile
> @@ -10,7 +10,7 @@ COMMENT=      Authentication broker supporting different
> identity providers
>
>  LICENSE=       MIT
>
> -RUN_DEPENDS=   rubygem-omniauth-oauth2>=1.1:net/rubygem-omniauth-oauth2
>

That should be >=1.4<2 to match upstream (~> 1.4).
And net/rubygem-omniauth-oauth2 (1.8.0) fits the range.

+RUN_DEPENDS=
>  rubygem-omniauth-oauth2-v1>=1.4<2:net/rubygem-omniauth-oauth2-v1
>
>  NO_ARCH=       yes
>  USE_RUBY=      yes
> diff --git a/net/rubygem-omniauth-oauth2-v1/Makefile
> b/net/rubygem-omniauth-oauth2-v1/Makefile
> new file mode 100644
> index 000000000000..206e479fd106
> --- /dev/null
> +++ b/net/rubygem-omniauth-oauth2-v1/Makefile
> @@ -0,0 +1,21 @@
> +PORTNAME=      omniauth-oauth2
> +PORTVERSION=   1.7.3
> +CATEGORIES=    net rubygems
> +MASTER_SITES=  RG
> +PKGNAMESUFFIX= -v1
> +
> +MAINTAINER=    ruby@FreeBSD.org
> +COMMENT=       Abstract OAuth2 strategy for OmniAuth
> +
> +LICENSE=       MIT
> +LICENSE_FILE=  ${WRKSRC}/LICENSE.md
> +
> +RUN_DEPENDS=   rubygem-oauth2>=1.4<3:net/rubygem-oauth2 \
> +               rubygem-omniauth>=1.9<3:security/rubygem-omniauth
> +
> +USES=          gem
> +USE_RUBY=      yes
> +
> +NO_ARCH=       yes
> +
> +.include <bsd.port.mk>
> diff --git a/net/rubygem-omniauth-oauth2-v1/distinfo
> b/net/rubygem-omniauth-oauth2-v1/distinfo
> new file mode 100644
> index 000000000000..fa8118af6754
> --- /dev/null
> +++ b/net/rubygem-omniauth-oauth2-v1/distinfo
> @@ -0,0 +1,3 @@
> +TIMESTAMP = 1656597551
> +SHA256 (rubygem/omniauth-oauth2-1.7.3.gem) =
> 3f5a8f99fa72e0f91d2abd7475ceb972a4ae67ed59e049f314c0c1bad81f4745
> +SIZE (rubygem/omniauth-oauth2-1.7.3.gem) = 11776
> diff --git a/net/rubygem-omniauth-oauth2-v1/pkg-descr
> b/net/rubygem-omniauth-oauth2-v1/pkg-descr
> new file mode 100644
> index 000000000000..cb95d71cba5a
> --- /dev/null
> +++ b/net/rubygem-omniauth-oauth2-v1/pkg-descr
> @@ -0,0 +1,3 @@
> +An abstract OAuth2 strategy for OmniAuth.
> +
> +WWW: https://github.com/omniauth/omniauth-oauth2
>