I’m trying to build a driver for a USB to HDMI adapter…
Bus 001 Device 010: ID 534d:6021 MacroSilicon VGA Display Adapter
NOTE: “lsusb” output.
… but this error is occurring…
Fatal error: Invalid --compress-debug-sections option: `zstd'
…as can be seen in the full output below…
[eduardolac@eduardolac-pc ms912x]$ make all -j
make CHECK="/usr/bin/sparse" -C /lib/modules/6.5.5-1-MANJARO/build M=/home/eduardolac/Data1/Temp/20231016.1224.0/ms912x modules
make[1]: Entering directory '/usr/lib/modules/6.5.5-1-MANJARO/build'
CC [M] /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_registers.o
CC [M] /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_connector.o
CC [M] /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_transfer.o
CC [M] /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_drv.o
Assembler messages:
Fatal error: Invalid --compress-debug-sections option: `zstd'
make[3]: *** [scripts/Makefile.build:243: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_connector.o] Error 1
make[3]: *** Waiting for unfinished jobs....
Assembler messages:
Fatal error: Invalid --compress-debug-sections option: `zstd'
make[3]: *** [scripts/Makefile.build:243: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_registers.o] Error 1
Assembler messages:
Fatal error: Invalid --compress-debug-sections option: `zstd'
make[3]: *** [scripts/Makefile.build:243: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_transfer.o] Error 1
Assembler messages:
Fatal error: Invalid --compress-debug-sections option: `zstd'
make[3]: *** [scripts/Makefile.build:243: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_drv.o] Error 1
make[2]: *** [/usr/lib/modules/6.5.5-1-MANJARO/build/Makefile:2034: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x] Error 2
make[1]: *** [Makefile:234: __sub-make] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.5.5-1-MANJARO/build'
make: *** [Makefile:15: modules] Error 2
The “ld” available on my system does not support the “zstd” option for the “compress-debug-sections” parameter…
[eduardolac@eduardolac-pc ms912x]$ ld --help | grep "compress-debug-sections"
--compress-debug-sections=[none|zlib|zlib-gnu|zlib-gabi]
… but the “binutils” package (which contains “ld”) that I have installed on my OS is version 2.41-3, which according to this documentation
( GNU Binary Utilities ) already supports the “zstd” option for the “compress-debug-sections” parameter.
The Kernel I have installed is 6.5.X .
Please help me with this.
Thanks!
Further…
https://askubuntu.com/a/1488791/134723
opened 04:15AM - 17 Oct 23 UTC
closed 06:01PM - 17 Oct 23 UTC
Any ideas on how to resolve this issue?
I'm using Manjaro with Linux Kernel 6… .5.5-1.
Thanks! S2
```
[eduardolac@eduardolac-pc ms912x]$ make all
make CHECK="/usr/bin/sparse" -C /lib/modules/6.5.5-1-MANJARO/build M=/home/eduardolac/Data1/Temp/20231016.1224.0/ms912x modules
make[1]: Entering directory '/usr/lib/modules/6.5.5-1-MANJARO/build'
CC [M] /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_registers.o
Assembler messages:
Fatal error: Invalid --compress-debug-sections option: `zstd'
make[3]: *** [scripts/Makefile.build:243: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x/ms912x_registers.o] Error 1
make[2]: *** [/usr/lib/modules/6.5.5-1-MANJARO/build/Makefile:2034: /home/eduardolac/Data1/Temp/20231016.1224.0/ms912x] Error 2
make[1]: *** [Makefile:234: __sub-make] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.5.5-1-MANJARO/build'
make: *** [Makefile:15: modules] Error 2
```
cscs
17 October 2023 19:52
2
Odd. Here its there:
$ pacman -Qo ld
/usr/bin/ld is owned by binutils 2.41-3
$ ld --help | grep "compress-debug-sections"
--compress-debug-sections=[none|zlib|zlib-gnu|zlib-gabi|zstd]
Maybe you can print out the binutils you have:
pacman -Qi binutils
1 Like
Certainly @cscs !
[eduardolac@eduardolac-pc ~]$ pacman -Qi binutils
Name : binutils
Version : 2.41-3
Description : A set of programs to assemble and manipulate binary and object files
Architecture : x86_64
URL : https://www.gnu.org/software/binutils/
Licenses : GPL3 GPL FDL1.3 custom:FSFAP
Groups : None
Provides : libctf.so=0-64 libgprofng.so=0-64 libsframe.so=1-64
Depends On : glibc jansson libelf zlib zstd
Optional Deps : debuginfod: for debuginfod server/client functionality [installed]
Required By : debtap gcc gcc11 gcc12 mkinitcpio
Optional For : bauh inxi
Conflicts With : binutils-multilib
Replaces : binutils-multilib
Installed Size : 40,87 MiB
Packager : Frederik Schwan <freswa@archlinux.org>
Build Date : sex 04 ago 2023 12:39:55
Install Date : seg 11 set 2023 10:41:51
Install Reason : Explicitly installed
Install Script : No
Validated By : Signature
PLUS: if I use Kernel 6.6 (“linux-amd-drm-fixes” and “linux-amd-drm-fixes-headers” packages in Manjaro), I can build “ms912x”…
cscs
17 October 2023 20:49
4
Yeah, that looks to be the one, and it even depends on zstd …
Maybe if we meditate on it a bit …
Om mani padme hum … Om mani padme hum …
Om mani padme hum … Om … hmm, … donuts!
I discovered something curious…
The “ld --version” says Binutils 2.38, but the Binutils I have installed is 2.41-3…
[eduardolac@eduardolac-pc ms912x]$ ld --version
GNU ld (GNU Binutils) 2.38
Copyright (C) 2022 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) a later version.
This program has absolutely no warranty.
The problem occurs because the “ld” binary used in my case, for some reason, was provided by “Homebrew”…
[eduardolac@eduardolac-pc ms912x]$ pacman -Qo ld
error: No package owns /home/linuxbrew/.linuxbrew/bin/ld
So the solution, for me, was to remove “Homebrew”, as I wasn’t using it for anything…
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall.sh)"
And as a precaution I reinstalled binutils…
yay -Rdd binutils
yay -S binutils
So finally, just open and close the terminal and voilà…
[eduardolac@eduardolac-pc ~]$ ld --version
GNU ld (GNU Binutils) 2.41.0
Copyright (C) 2023 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) a later version.
This program has absolutely no warranty.
Thanks!
[Ref(s).: https://stackoverflow.com/a/64722984/3223785 ]
The shortcut to the solution would then have been
which ld
Of course you have to know that you have made changes to system path - but you would know right?
2 Likes
system
Closed
22 October 2023 18:59
10
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.