Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 912446 - sys-apps/shadow-4.14.0: undefined reference to `mallocarray' on arm
Summary: sys-apps/shadow-4.14.0: undefined reference to `mallocarray' on arm
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: ARM Linux
: Normal normal
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-08-18 08:35 UTC by Christian Bricart
Modified: 2023-09-19 00:55 UTC (History)
7 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,135.00 KB, text/x-log)
2023-08-18 08:36 UTC, Christian Bricart
Details
emerge --info '=sys-apps/shadow-4.14.0::gentoo' (emerge.info,6.50 KB, text/plain)
2023-08-19 00:49 UTC, Robert Marmorstein
Details
Build log (sys-apps:shadow-4.14.0:20230819-004434.log,106.46 KB, text/x-log)
2023-08-19 00:53 UTC, Robert Marmorstein
Details
Ebuild for sys-apps/shadow with the patch (shadow-9999.ebuild,7.17 KB, text/plain)
2023-09-12 02:57 UTC, Robert Marmorstein
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Bricart 2023-08-18 08:35:05 UTC
emerge sys-apps//shadow-4.14.0 on ~arm fails in link phase:

…
libtool: link: armv7a-unknown-linux-gnueabihf-gcc -isystem /usr/include/bsd -DLIBBSD_OVERLAY -march=armv8-a+crc+simd -mtune=cortex-a53 -mlibarch=armv8-a+crc+simd -mfloat-abi=hard -mfpu=vfpv3-d16 -mtls-dialect=gnu -marm -dumpbase -O2 -pipe -Wl,-O1 -o grpck grpck.o  -Wl,--as-needed ../libmisc/.libs/libmisc.a -lcrypt -lsystemd ../lib/.libs/libshadow.a -lbsd
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-groupio.o): in function `merge_group_entries':
groupio.c:(.text+0x934): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-groupio.o): in function `split_groups':
groupio.c:(.text+0xd04): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-groupmem.o): in function `__gr_dup':
groupmem.c:(.text+0x18): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: groupmem.c:(.text+0x11c): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-sssd.o): in function `sssd_flush_cache':
sssd.c:(.text+0xb8): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-sgetgrent.o): in function `list':
sgetgrent.c:(.text+0x6c): undefined reference to `reallocarrayf'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-sgetgrent.o): in function `sgetgrent':
sgetgrent.c:(.text+0x20c): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-sgroupio.o): in function `__sgr_dup':
sgroupio.c:(.text+0x110): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: sgroupio.c:(.text+0x2f0): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-commonio.o): in function `commonio_lock_nowait':
commonio.c:(.text+0xce0): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: commonio.c:(.text+0xcfc): undefined reference to `mallocarray'
/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/13/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-commonio.o):commonio.c:(.text+0x15dc): more undefined references to `mallocarray' follow
collect2: error: ld returned 1 exit status
make[2]: *** [Makefile:1088: grpck] Error 1
make[2]: Leaving directory '/var/tmp/portage/sys-apps/shadow-4.14.0/work/shadow-4.14.0/src'
make[1]: *** [Makefile:462: all-recursive] Error 1
make[1]: Leaving directory '/var/tmp/portage/sys-apps/shadow-4.14.0/work/shadow-4.14.0'
make: *** [Makefile:390: all] Error 2


Reproducible: Always




any ~sys-apps/shadow-4.13 merges just fine
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-08-18 08:36:04 UTC
Please include the full build.log and emerge --info.
Comment 2 Christian Bricart 2023-08-18 08:36:15 UTC
Created attachment 868172 [details]
build.log
Comment 3 Christian Bricart 2023-08-18 08:37:58 UTC
Portage 3.0.50 (python 3.12.0-candidate-1, default/linux/arm/17.0/armv7a/systemd/merged-usr, gcc-13, glibc-2.37-r4, 6.1.45-v7+ armv7l)
=================================================================
System uname: Linux-6.1.45-v7+-armv7l-ARMv7_Processor_rev_4_-v7l-with-glibc2.37
KiB Mem:      989132 total,    257812 free
KiB Swap:    2621432 total,   2621432 free
Timestamp of repository gentoo: Fri, 18 Aug 2023 08:00:01 +0000
Head commit of repository gentoo: 2a645c41d8dc19514e9e8dfb7f61b3a1e1b006b7
Head commit of repository meins: 711bcc74ebcac18c3a49ce4778cb1ca0ca577a1c

sh bash 5.2_p15-r6
ld GNU ld (Gentoo 2.41 p2) 2.41.0
distcc 3.4 armv7a-unknown-linux-gnueabihf [disabled]
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.2_p15-r6::gentoo
dev-lang/perl:             5.38.0-r1::gentoo
dev-lang/python:           3.11.4::gentoo, 3.12.0_rc1_p1::gentoo
dev-lang/rust-bin:         1.71.1::gentoo
dev-util/cmake:            3.27.3::gentoo
dev-util/meson:            1.2.1-r1::gentoo
sys-apps/baselayout:       2.14::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-apps/systemd:          254.1-r1::gentoo
sys-devel/autoconf:        2.71-r7::gentoo
sys-devel/automake:        1.16.5-r1::gentoo
sys-devel/binutils:        2.41-r1::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/gcc:             13.2.0::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/libtool:         2.4.7-r1::gentoo
sys-devel/make:            4.4.1-r1::gentoo
sys-kernel/linux-headers:  6.4::gentoo (virtual/os-headers)
sys-libs/glibc:            2.37-r4::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    volatile: True
    sync-rsync-extra-opts: 
    sync-rsync-verify-max-age: 24
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-metamanifest: no

meins
    location: /usr/local/portage
    sync-type: git
    sync-uri: git@gitlab.aachalon.net:shiva/local-portage
    masters: gentoo
    priority: 0
    volatile: True

ACCEPT_KEYWORDS="arm ~arm"
ACCEPT_LICENSE="*"
CBUILD="armv7a-unknown-linux-gnueabihf"
CFLAGS="-march=armv8-a+crc+simd -mtune=cortex-a53 -mlibarch=armv8-a+crc+simd -mfloat-abi=hard -mfpu=vfpv3-d16 -mtls-dialect=gnu -marm -dumpbase -O2 -pipe"
CHOST="armv7a-unknown-linux-gnueabihf"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d"
CXXFLAGS="-march=armv8-a+crc+simd -mtune=cortex-a53 -mlibarch=armv8-a+crc+simd -mfloat-abi=hard -mfpu=vfpv3-d16 -mtls-dialect=gnu -marm -dumpbase -O2 -pipe"
DISTDIR="/var/cache/distfiles"
EMERGE_DEFAULT_OPTS="--autounmask=n --quiet-build=y"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2 -pipe -march=armv7-a"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe -march=armv7-a"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
MAKEOPTS="-j1"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
SHELL="/bin/bash"
USE="acl arm bzip2 cli crypt dri fortran gdbm iconv ipv6 ncurses nls nptl openmp pam pcre readline seccomp ssl systemd test-rust udev unicode xattr zlib" ADA_TARGET="gnat_2021" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_ARM="edsp neon thumb thumb2 v4 v5 v6 v7 vfp vfp-d32 vfpv3 vfpv4" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-4" LUA_TARGETS="lua5-4" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11 python3_12" RUBY_TARGETS="ruby31" VIDEO_CARDS="exynos fbdev omap dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 4 Robert Marmorstein 2023-08-19 00:48:20 UTC
I'm also seeing this on x86_64:

libtool: link: x86_64-pc-linux-gnu-gcc -isystem /usr/include/bsd -DLIBBSD_OVERLAY -march=native -Os -pipe -Wl,-O1 -o grpck grpck.o  -Wl,--as-needed ../libmisc/.libs/libmisc.a -lcrypt ../lib/.libs/libshadow.a -lbsd
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: ../lib/.libs/libshadow.a(libshadow_la-groupio.o): in function `group_open_hook':
groupio.c:(.text+0xe7): undefined reference to `mallocarray'
Comment 5 Robert Marmorstein 2023-08-19 00:49:36 UTC
Created attachment 868180 [details]
emerge --info '=sys-apps/shadow-4.14.0::gentoo'
Comment 6 Robert Marmorstein 2023-08-19 00:53:55 UTC
Created attachment 868181 [details]
Build log
Comment 7 Alejandro Colomar 2023-08-25 09:42:32 UTC
See also: <https://github.com/shadow-maint/shadow/pull/792>

Christian, Robert, please test and confirm if that fixes the problem for you.
Comment 8 Robert Förster 2023-08-27 16:00:14 UTC
the linked PR does indeed fix the problem, thanks!
Comment 9 Boris Staletic 2023-09-10 06:23:45 UTC
I have also encountered this linking error. Will try the proposed patch after the rest of the system updates.
Comment 10 Boris Staletic 2023-09-10 09:54:04 UTC
Applying patch from pull request 792 resulted in 

make[2]: *** No rule to make target 'alloc.c', needed by 'libmisc_la-alloc.lo'.  Stop.

I have applied the patch by the means of

wget https://patch-diff.githubusercontent.com/raw/shadow-maint/shadow/pull/792.patch -O /etc/portage/patches/sys-apps/shadow-4.14.0-r2/792.patch

Applying pulls 793 and 794 did not apply cleanly.
Comment 11 Boris Staletic 2023-09-10 10:32:01 UTC
I have also found that -O flags affect the reproducibility of the original issue.

-O0, -Os and -Oz lead to the linker not being able to find mallocarray.
-O1, -O2 and -O3 lead to a successful upgrade.
Comment 12 Alejandro Colomar 2023-09-10 12:17:07 UTC
(In reply to Boris Staletic from comment #11)
> I have also found that -O flags affect the reproducibility of the original
> issue.
> 
> -O0, -Os and -Oz lead to the linker not being able to find mallocarray.
> -O1, -O2 and -O3 lead to a successful upgrade.

That's because the function is defined inline, so with high optimization levels, the call is inlined, and no longer needed.

```
$ grepc mallocarray
./lib/alloc.c:37:
extern inline void *mallocarray(size_t nmemb, size_t size);


./lib/alloc.h:60:
ATTR_MALLOC(free)
inline void *mallocarray(size_t nmemb, size_t size);


./lib/alloc.h:87:
inline void *
mallocarray(size_t nmemb, size_t size)
{
	return reallocarray(NULL, nmemb, size);
}
```
Comment 13 Alejandro Colomar 2023-09-10 12:17:53 UTC
(In reply to Boris Staletic from comment #10)
> Applying patch from pull request 792 resulted in 
> 
> make[2]: *** No rule to make target 'alloc.c', needed by
> 'libmisc_la-alloc.lo'.  Stop.
> 
> I have applied the patch by the means of
> 
> wget
> https://patch-diff.githubusercontent.com/raw/shadow-maint/shadow/pull/792.
> patch -O /etc/portage/patches/sys-apps/shadow-4.14.0-r2/792.patch
> 
> Applying pulls 793 and 794 did not apply cleanly.

You need to apply two patches:

$ git cherry-pick c34c2606 093fb605
Comment 14 Robert Marmorstein 2023-09-10 15:28:07 UTC
Sorry -- I'm not getting notifications about this for some reason and didn't see the reply.  Where do I run the git cherry-pick from?  My portage is configured to use rsync still, if that's related...

Thanks!
Comment 15 Alejandro Colomar 2023-09-10 16:13:28 UTC
(In reply to Robert Marmorstein from comment #14)
> Sorry -- I'm not getting notifications about this for some reason and didn't
> see the reply.  Where do I run the git cherry-pick from?  My portage is
> configured to use rsync still, if that's related...

I'm talking about the upstream git project, not the Gentoo package.  I created a branch and tag with the fixes, and sent an email to the upstream mailing list and the upstream maintainers, CCing all of you.  It contains a proposal for an upstream 4.14.1 release.

If you package that tag, it should be free of build problems, but it's yet not an official release (I didn't bump the version number, for example), so use it only for testing purposes, please.

Cheers,
Alex
Comment 16 Alejandro Colomar 2023-09-10 16:18:35 UTC
(In reply to Alejandro Colomar from comment #15)
> I'm talking about the upstream git project, not the Gentoo package.  I
> created a branch and tag with the fixes, and sent an email to the upstream
> mailing list and the upstream maintainers, CCing all of you.  It contains a
> proposal for an upstream 4.14.1 release.
> 
> If you package that tag, it should be free of build problems, but it's yet
> not an official release (I didn't bump the version number, for example), so
> use it only for testing purposes, please.
> 
> Cheers,
> Alex

Link: <https://lists.sr.ht/~hallyn/shadow/%3C6bf2bb62-e0a9-45ae-9b6d-aa08ff626520%40kernel.org%3E>
Comment 17 Robert Marmorstein 2023-09-11 12:16:41 UTC
I cherry picked those two commits, but my build fails:

/bin/sh ../libtool  --tag=CC   --mode=compile x86_64-pc-linux-gnu-gcc  -I. -I..    -I..  -isystem /usr/include/bsd -DLIBBSD_OVERLAY -lcrypt  -march=native -Os -pipe -c -o libshadow_la-mail.lo `test -f 'mail.c' || echo './'`mail.c
make[2]: *** No rule to make target 'mempcpy.c', needed by 'libshadow_la-mempcpy.lo'.  Stop.
Comment 18 Robert Marmorstein 2023-09-11 12:35:08 UTC
I tried instead, to pull from git://www.alejandro-colomar.es/src/alx/shadow/shadow.git

But my connection times out -- I'll try again later.

Thanks so much for working on this!
Comment 19 Alejandro Colomar 2023-09-11 13:00:00 UTC
(In reply to Robert Marmorstein from comment #18)
> I tried instead, to pull from
> git://www.alejandro-colomar.es/src/alx/shadow/shadow.git
> 
> But my connection times out -- I'll try again later.
> 
> Thanks so much for working on this!

Hmm, that's strange; the server is up and running.  Can you ping?  Maybe it's the distance.  You could try cloning from the official shadow repo, and then just add mine as a remote to fetch only those few commits.
Comment 20 Alejandro Colomar 2023-09-11 13:06:08 UTC
(In reply to Robert Marmorstein from comment #17)
> I cherry picked those two commits, but my build fails:
> 
> /bin/sh ../libtool  --tag=CC   --mode=compile x86_64-pc-linux-gnu-gcc  -I.
> -I..    -I..  -isystem /usr/include/bsd -DLIBBSD_OVERLAY -lcrypt 
> -march=native -Os -pipe -c -o libshadow_la-mail.lo `test -f 'mail.c' || echo
> './'`mail.c
> make[2]: *** No rule to make target 'mempcpy.c', needed by
> 'libshadow_la-mempcpy.lo'.  Stop.

Can you please specify how I can reproduce this under Debian Sid?  Maybe some flags that I can pass to either make or configure?  It is working for me.

```
alx@asus5775:~/src/shadow/shadow/4.14$ git log -1
commit 014536f5d55df33fc032d7a14d9f9d975d569722 (HEAD -> tmp, tag: 4.14.0)
Author: Serge Hallyn <serge@hallyn.com>
Date:   Tue Aug 15 21:38:30 2023 -0500

    release 4.14.0
    
    Signed-off-by: Serge Hallyn <serge@hallyn.com>
alx@asus5775:~/src/shadow/shadow/4.14$ git cherry-pick c34c2606 093fb605 | grep '^[^ ]'
[tmp dcf39726] lib, libmisc: Move source files to lib (where their headers were)
Auto-merging lib/prototypes.h
Auto-merging src/su.c
[tmp 821db7c9] lib: Merge libmisc into libshadow
alx@asus5775:~/src/shadow/shadow/4.14$ git log --oneline --graph -3
* 821db7c9 (HEAD -> tmp) lib: Merge libmisc into libshadow
* dcf39726 lib, libmisc: Move source files to lib (where their headers were)
* 014536f5 (tag: 4.14.0) release 4.14.0
alx@asus5775:~/src/shadow/shadow/4.14$ time ./autogen.sh |& wc -l; echo $?
348

real	0m13.613s
user	0m10.496s
sys	0m2.144s
0
alx@asus5775:~/src/shadow/shadow/4.14$ time make -j |& wc -l; echo $?
8097

real	1m27.043s
user	4m45.645s
sys	0m19.418s
0
```
Comment 21 Mike Gilbert gentoo-dev 2023-09-11 15:24:37 UTC
Hi, Gentoo dev here.

I was able to reproduce the issue by setting setting "-Os" in CFLAGS.

I can confirm that applying c34c2606 and 093fb605 on top of a 4.14.0 tarball resolves the issue. I did need to run autoreconf to regenerate the build system.

Given the significant changes to the layout here, I would prefer to wait for a new source tarball to be generated based on a release upstream.
Comment 22 Robert Marmorstein 2023-09-12 02:00:07 UTC
(In reply to Alejandro Colomar from comment #19)
> (In reply to Robert Marmorstein from comment #18)
> > I tried instead, to pull from
> > git://www.alejandro-colomar.es/src/alx/shadow/shadow.git
> > 
> > But my connection times out -- I'll try again later.
> > 
> > Thanks so much for working on this!
> 
> Hmm, that's strange; the server is up and running.  Can you ping?  Maybe
> it's the distance.  You could try cloning from the official shadow repo, and
> then just add mine as a remote to fetch only those few commits.

Using http:// instead of git:// or https:// works for me.  Let me build and see if I can confirm that fixes the issue.
Comment 23 Robert Marmorstein 2023-09-12 02:57:51 UTC
Created attachment 870328 [details]
Ebuild for sys-apps/shadow with the patch

I can confirm that this works for me.  I've attached the custom ebuild I used to verify.  Thanks, Alejandro (and everyone else who worked on this)!
Comment 24 Alejandro Colomar 2023-09-12 12:20:57 UTC
(In reply to Robert Marmorstein from comment #22)
> (In reply to Alejandro Colomar from comment #19)
> > (In reply to Robert Marmorstein from comment #18)
> > > I tried instead, to pull from
> > > git://www.alejandro-colomar.es/src/alx/shadow/shadow.git
> > > 
> > > But my connection times out -- I'll try again later.
> > > 
> > > Thanks so much for working on this!
> > 
> > Hmm, that's strange; the server is up and running.  Can you ping?  Maybe
> > it's the distance.  You could try cloning from the official shadow repo, and
> > then just add mine as a remote to fetch only those few commits.
> 
> Using http:// instead of git:// or https:// works for me.  Let me build and
> see if I can confirm that fixes the issue.

Hmm, that's curious; git:// is faster for me (in a local network) --although of course, I use ssh://--.  git:// is being served by git-daemon(1), while http:// is being served by cgit.

And yup, I don't yet serve https://.

(In reply to Robert Marmorstein from comment #23)
> Created attachment 870328 [details]
> Ebuild for sys-apps/shadow with the patch
> 
> I can confirm that this works for me.  I've attached the custom ebuild I
> used to verify.

I can see some https:// reference in that ebuild; here's the line:

	git request-pull 4.14.0 https://www.alejandro-colomar.es/src/alx/shadow/shadow.git 4.14+alx4.14.1-rc1

I think that should be replaced by http://, as I don't serve HTTPS.

> Thanks, Alejandro (and everyone else who worked on this)!

It's a pleasure!  :-}
Comment 25 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-09-17 04:23:01 UTC
Any news on a 4.14.1?
Comment 26 Larry the Git Cow gentoo-dev 2023-09-19 00:55:26 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=75209a50623aa5538ecbf940c20e69d55b0693f1

commit 75209a50623aa5538ecbf940c20e69d55b0693f1
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2023-09-19 00:54:05 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2023-09-19 00:55:24 +0000

    sys-apps/shadow: backport build fixes
    
    Closes: https://bugs.gentoo.org/912446
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 .../shadow/files/shadow-4.14.0-bug912446.patch     | 1305 ++++++++++++++++++++
 ...ow-4.14.0-r2.ebuild => shadow-4.14.0-r3.ebuild} |   12 +-
 2 files changed, 1314 insertions(+), 3 deletions(-)