Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 926289 - sys-fs/mdadm-4.3 - mdadm.c:1363:18: error: call to undeclared function 'basename' and other failures
Summary: sys-fs/mdadm-4.3 - mdadm.c:1363:18: error: call to undeclared function 'basen...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard: not a musl-1.2.5 regression
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-06 23:51 UTC by ernsteiswuerfel
Modified: 2024-05-20 08:25 UTC (History)
2 users (show)

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


Attachments
build.log (mdadm-4.2-r3:20240306-234528.log,3.24 KB, text/plain)
2024-03-06 23:51 UTC, ernsteiswuerfel
Details
emerge --info (file_926289.txt,7.42 KB, text/plain)
2024-03-06 23:51 UTC, ernsteiswuerfel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ernsteiswuerfel archtester 2024-03-06 23:51:03 UTC
Created attachment 886835 [details]
build.log

[...]
make -j1 PKG_CONFIG=x86_64-gentoo-linux-musl-pkg-config CC=clang CWFLAGS=-Wall 'CXFLAGS=-Os -march=x86-64-v2 -pipe' UDEVDIR=/lib/udev SYSTEMD_DIR=/lib/systemd/system COROSYNC=-DNO_COROSYNC DLM=-DNO_DLM STRIP= all 
clang -Wall -Os -march=x86-64-v2 -pipe -DSendmail=\""/usr/sbin/sendmail -t"\" -DCONFFILE=\"/etc/mdadm.conf\" -DCONFFILE2=\"/etc/mdadm/mdadm.conf\" -DMAP_DIR=\"/run/mdadm\" -DMAP_FILE=\"map\" -DMDMON_DIR=\"/run/mdadm\" -DFAILED_SLOTS_DIR=\"/run/mdadm/failed-slots\" -DNO_COROSYNC -DNO_DLM    -DUSE_PTHREADS  -D_LARGEFILE64_SOURCE -DBINDIR=\"/sbin\"  -o mdadm.o -c mdadm.c
mdadm.c:1363:18: error: call to undeclared function 'basename'; ISO C99 and
      later do not support implicit function declarations [-Wimplicit-function-declaration]
 1363 |                         char *bname = basename(devlist->devname);
      |                                       ^
mdadm.c:1363:10: error: incompatible integer to pointer conversion
      initializing 'char *' with an expression of type 'int' [-Wint-conversion]
 1363 |                         char *bname = basename(devlist->devname);
      |                               ^       ~~~~~~~~~~~~~~~~~~~~~~~~~~
2 errors generated.
make: *** [Makefile:193: mdadm.o] Error 1
Comment 1 ernsteiswuerfel archtester 2024-03-06 23:51:59 UTC
Created attachment 886836 [details]
emerge --info
Comment 2 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2024-03-14 03:39:10 UTC
cannot reproduce
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-03-14 08:27:19 UTC
You need musl-1.2.5.
Comment 4 Andreas K. Hüttel archtester gentoo-dev 2024-04-30 19:31:50 UTC
util.c: In function 'get_md_name':
util.c:1031:29: error: 'NAME_MAX' undeclared (first use in this function); did you mean 'MD_NAME_MAX'?
 1031 |         static char devname[NAME_MAX];
      |                             ^~~~~~~~
      |                             MD_NAME_MAX
util.c:1031:29: note: each undeclared identifier is reported only once for each function it appears in
util.c:1031:21: warning: unused variable 'devname' [-Wunused-variable]
 1031 |         static char devname[NAME_MAX];
      |                     ^~~~~~~