Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 768237 - sys-devel/gdb-10.1[-client,server] build failure: *** No rule to make target '../gnulib/import/libgnu.a', needed by 'gdbserver.exe'
Summary: sys-devel/gdb-10.1[-client,server] build failure: *** No rule to make target ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-02-01 15:33 UTC by Oleh Kravchenko
Modified: 2021-02-09 14:08 UTC (History)
1 user (show)

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


Attachments
emerge --info (emerge.info,2.59 KB, application/x-info)
2021-02-01 15:33 UTC, Oleh Kravchenko
Details
The complete build log (build.log,12.15 KB, text/x-log)
2021-02-01 15:34 UTC, Oleh Kravchenko
Details
/usr/i686-w64-mingw32/tmp/portage/sys-libs/ncurses-6.2_p20210123/temp/build.log (build.log,70.76 KB, text/plain)
2021-02-07 13:18 UTC, Oleh Kravchenko
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oleh Kravchenko 2021-02-01 15:33:51 UTC
Created attachment 685434 [details]
emerge --info

LC_ALL=C CHOST=i686-w64-mingw32 cross-emerge sys-devel/gdb

> * ERROR: sys-devel/gdb-10.1::gentoo failed (install phase):
> *   emake failed
> * 
> * If you need support, post the output of `emerge --info '=sys-devel/gdb-10.1::gentoo'`,
> * the complete build log and the output of `emerge -pqv '=sys-devel/gdb-10.1::gentoo'`.
> * The complete build log is located at '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/temp/build.log'.
> * The ebuild environment file is located at '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/temp/environment'.
> * Working directory: '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/work/gdb-10.1/gdbserver'
> * S: '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/work/gdb-10.1'
Comment 1 Oleh Kravchenko 2021-02-01 15:34:57 UTC
Created attachment 685437 [details]
The complete build log
Comment 2 Sergei Trofimovich (RETIRED) gentoo-dev 2021-02-06 15:08:44 UTC
The build failure is:

/bin/sh ./../gdbsupport/create-version.sh ./../gdb \
        i686-w64-mingw32 i686-w64-mingw32 version-generated.cc
make: *** No rule to make target '../gnulib/import/libgnu.a', needed by 'gdbserver.exe'.  Stop.
make: *** Waiting for unfinished jobs....

Do you know if it's a regression or it never worked for you? I'm not sure building gdb for windows works without tweaks.
Comment 3 Sergei Trofimovich (RETIRED) gentoo-dev 2021-02-06 15:48:27 UTC
Reproduced with USE='-client server'. As a workaround try USE='client server'. Might work as is for you (it did for me).
Comment 4 Sergei Trofimovich (RETIRED) gentoo-dev 2021-02-06 15:51:20 UTC
Also does not seem to be specific for mingw32. Fails the same on x86_64-pc-linux-gnu.
Comment 5 Oleh Kravchenko 2021-02-06 20:20:45 UTC
9.2 worked very well:

> LC_ALL=C CHOST=i686-w64-mingw32 cross-emerge sys-devel/gdb -pv
> 
> These are the packages that would be merged, in order:
> 
> Calculating dependencies... done!
> [ebuild     U  ] sys-devel/gdb-10.1::gentoo [9.2::gentoo] to /usr/i686-w64-mingw32/ USE="server -cet% -client -lzma -multitarget -nls -python -source-highlight -test -vanilla -xml -xxhash" PYTHON_SINGLE_TARGET="-python3_7 -python3_8 -python3_9% (-python3_6%)" 0 KiB
> 
> Total: 1 package (1 upgrade), Size of downloads: 0 KiB
> 
>  * IMPORTANT: 3 news items need reading for repository 'gentoo'.
>  * Use eselect news read to view new items.
Comment 6 Oleh Kravchenko 2021-02-06 20:49:43 UTC
> As a workaround try USE='client server'. 
Doesn't work for me:

> LC_ALL=C CHOST=i686-w64-mingw32 cross-emerge sys-devel/gdb -1qva
> -
>  * IMPORTANT: 3 news items need reading for repository 'gentoo'.
>  * Use eselect news read to view new items.
> 
> [ebuild  N    ] sys-libs/ncurses-6.2_p20210123 to /usr/i686-w64-mingw32/ USE="cxx minimal unicode -ada -debug -doc -gpm -profile -split-usr -static-libs -test -threads -tinfo -trace" 
> [ebuild  N    ] sys-libs/zlib-1.2.11-r3 to /usr/i686-w64-mingw32/ USE="-minizip -split-usr -static-libs" 
> [ebuild  N    ] dev-libs/gmp-6.2.1 to /usr/i686-w64-mingw32/ USE="asm cxx -doc -pic -static-libs" 
> [ebuild  N    ] dev-libs/mpfr-4.1.0 to /usr/i686-w64-mingw32/ USE="-static-libs" 
> [ebuild  N    ] sys-libs/readline-8.1 to /usr/i686-w64-mingw32/ USE="unicode -split-usr -static-libs -utils" 
> [ebuild     U ] sys-devel/gdb-10.1 [9.2] to /usr/i686-w64-mingw32/ USE="client* server -cet% -lzma -multitarget -nls -python -source-highlight -test -vanilla -xml -xxhash" PYTHON_SINGLE_TARGET="-python3_7 -python3_8 -python3_9% (-python3_6%)" 
> 
> Would you like to merge these packages? [Yes/No] 
> Sorry, response '-' not understood. [Yes/No] 
> >>> Verifying ebuild manifests
> >>> Emerging (1 of 6) sys-libs/ncurses-6.2_p20210123::gentoo for /usr/i686-w64-mingw32/
> >>> Failed to emerge sys-libs/ncurses-6.2_p20210123 for /usr/i686-w64-mingw32/, Log file:
> >>>  '/usr/i686-w64-mingw32/tmp/portage/sys-libs/ncurses-6.2_p20210123/temp/build.log'
Comment 7 Sergei Trofimovich (RETIRED) gentoo-dev 2021-02-07 07:12:26 UTC
(In reply to Oleh Kravchenko from comment #5)
> 9.2 worked very well:
> 
> > LC_ALL=C CHOST=i686-w64-mingw32 cross-emerge sys-devel/gdb -pv
> > 
> > These are the packages that would be merged, in order:
> > 
> > Calculating dependencies... done!
> > [ebuild     U  ] sys-devel/gdb-10.1::gentoo [9.2::gentoo] to /usr/i686-w64-mingw32/ USE="server -cet% -client -lzma -multitarget -nls -python -source-highlight -test -vanilla -xml -xxhash" PYTHON_SINGLE_TARGET="-python3_7 -python3_8 -python3_9% (-python3_6%)" 0 KiB

Yeah, It probably had no gnulib depend in gdbserver and our hack of partial build worked. We might not be as lucky for 10.1.

(In reply to Oleh Kravchenko from comment #6)
> > As a workaround try USE='client server'. 
> Doesn't work for me:
> 
> > LC_ALL=C CHOST=i686-w64-mingw32 cross-emerge sys-devel/gdb -1qva
> > -
> >  * IMPORTANT: 3 news items need reading for repository 'gentoo'.
> >  * Use eselect news read to view new items.
> > 
> > [ebuild  N    ] sys-libs/ncurses-6.2_p20210123 to /usr/i686-w64-mingw32/ USE="cxx minimal unicode -ada -debug -doc -gpm -profile -split-usr -static-libs -test -threads -tinfo -trace" 
...
> > >>> Failed to emerge sys-libs/ncurses-6.2_p20210123 for /usr/i686-w64-mingw32/, Log file:
> > >>>  '/usr/i686-w64-mingw32/tmp/portage/sys-libs/ncurses-6.2_p20210123/temp/build.log'

That looks like a separate issue. The package builds fine for me.

Can you upload a build log? If it's a user configuration issue we might be able to fix it here. Otherwise if should be fixed by a gentoo ncurses maintainer.
Comment 8 Oleh Kravchenko 2021-02-07 13:18:11 UTC
Created attachment 685956 [details]
/usr/i686-w64-mingw32/tmp/portage/sys-libs/ncurses-6.2_p20210123/temp/build.log

Here is a full build log for sys-libs/ncurses-6.2_p20210123 to /usr/i686-w64-mingw32/
Comment 9 Sergei Trofimovich (RETIRED) gentoo-dev 2021-02-08 19:31:47 UTC
(In reply to Oleh Kravchenko from comment #8)
> Created attachment 685956 [details]
> /usr/i686-w64-mingw32/tmp/portage/sys-libs/ncurses-6.2_p20210123/temp/build.
> log
> 
> Here is a full build log for sys-libs/ncurses-6.2_p20210123 to
> /usr/i686-w64-mingw32/

Aha, that is probably a bug #711590. The workaround should be https://bugs.gentoo.org/711590#c3: install into host and target the same ncurses version.
Comment 10 Oleh Kravchenko 2021-02-09 10:04:51 UTC
I've successfully merged this after removing ~${ARCH} from ACCEPT_KEYWORDS in /usr/i686-w64-mingw32/etc/portage/make.conf file:
> LC_ALL=C CHOST=i686-w64-mingw32 USE="client server" cross-emerge sys-devel/gdb

Nevertheless, I can't build only a server:
> LC_ALL=C CHOST=i686-w64-mingw32 USE="-client server" cross-emerge sys-devel/gdb
> ...
> configure: WARNING: unrecognized options: --disable-dependency-tracking, --disable-binutils, --disable-etc, --disable-gas, --disable-gold, --disable-gprof, --disable-ld, --without-debuginfod, --disable-cet
>  * Skipping make test/check due to ebuild restriction.
> /bin/sh ./../gdbsupport/create-version.sh ./../gdb \
>         i686-w64-mingw32 i686-w64-mingw32 version-generated.cc
> make: *** No rule to make target '../gnulib/import/libgnu.a', needed by 'gdbserver.exe'.  Stop.
> make: *** Waiting for unfinished jobs....
>  * ERROR: sys-devel/gdb-10.1::gentoo failed (install phase):
>  *   emake failed
>  * 
>  * If you need support, post the output of `emerge --info '=sys-devel/gdb-10.1::gentoo'`,
>  * the complete build log and the output of `emerge -pqv '=sys-devel/gdb-10.1::gentoo'`.
>  * The complete build log is located at '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/temp/build.log'.
>  * The ebuild environment file is located at '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/temp/environment'.
>  * Working directory: '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/work/gdb-10.1/gdbserver'
>  * S: '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/work/gdb-10.1'
>  * QA Notice: Unrecognized configure options:
>  * 
>  *      --disable-dependency-tracking
>  *      --disable-binutils
>  *      --disable-etc
>  *      --disable-gas
>  *      --disable-gold
>  *      --disable-gprof
>  *      --disable-ld
>  *      --without-debuginfod
>  *      --disable-cet
>  *      --disable-dependency-tracking
>  *      --disable-binutils
>  *      --disable-etc
>  *      --disable-gas
>  *      --disable-gold
>  *      --disable-gprof
>  *      --disable-ld
>  *      --without-debuginfod
>  *      --disable-cet
> 
>  * Messages for package sys-devel/gdb-10.1 merged to /usr/i686-w64-mingw32/:
> 
>  * ERROR: sys-devel/gdb-10.1::gentoo failed (install phase):
>  *   emake failed
>  * 
>  * If you need support, post the output of `emerge --info '=sys-devel/gdb-10.1::gentoo'`,
>  * the complete build log and the output of `emerge -pqv '=sys-devel/gdb-10.1::gentoo'`.
>  * The complete build log is located at '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/temp/build.log'.
>  * The ebuild environment file is located at '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/temp/environment'.
>  * Working directory: '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/work/gdb-10.1/gdbserver'
>  * S: '/usr/i686-w64-mingw32/tmp/portage/sys-devel/gdb-10.1/work/gdb-10.1'
Comment 11 Larry the Git Cow gentoo-dev 2021-02-09 14:08:57 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2aa76f92308d2b745bf47b9ca94937f125301691

commit 2aa76f92308d2b745bf47b9ca94937f125301691
Author:     Sergei Trofimovich <slyfox@gentoo.org>
AuthorDate: 2021-02-09 14:08:24 +0000
Commit:     Sergei Trofimovich <slyfox@gentoo.org>
CommitDate: 2021-02-09 14:08:51 +0000

    sys-devel/gdb: force USE=client on
    
    From gcc-10 gdbserver requires top-level gnulib. That broke
    USE="server -client" case which was implemented in a hacky
    way in Gentoo ebuild.
    
    Instead of trying to fix it we resort to always enabling
    USE=client. It's a heavyweight workaround.
    
    Reported-by: Oleh Kravchenko
    Closes: https://bugs.gentoo.org/768237
    Package-Manager: Portage-3.0.14, Repoman-3.0.2
    Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>

 sys-devel/gdb/gdb-10.1.ebuild | 115 +++++++++++++++++-------------------------
 sys-devel/gdb/gdb-9999.ebuild | 115 +++++++++++++++++-------------------------
 sys-devel/gdb/metadata.xml    |   1 -
 3 files changed, 94 insertions(+), 137 deletions(-)