All of lore.kernel.org
 help / color / mirror / Atom feed
From: bugzilla-daemon@kernel.org
To: kvm@vger.kernel.org
Subject: [Bug 218026] New: Compile failure in kvm-unit-tests about "ld: Error: unable to disambiguate: -no-pie"
Date: Thu, 19 Oct 2023 07:02:24 +0000	[thread overview]
Message-ID: <bug-218026-28872@https.bugzilla.kernel.org/> (raw)

https://bugzilla.kernel.org/show_bug.cgi?id=218026

            Bug ID: 218026
           Summary: Compile failure in kvm-unit-tests about "ld: Error:
                    unable to disambiguate: -no-pie"
           Product: Virtualization
           Version: unspecified
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: high
          Priority: P3
         Component: kvm
          Assignee: virtualization_kvm@kernel-bugs.osdl.org
          Reporter: ruifeng.gao@intel.com
        Regression: No

Environment:
CPU Architecture: x86_64
Host OS: CentOS Stream 9
binutils: binutils-2.36.1-4.el9.x86_64
kvm-unit-tests source: https://gitlab.com/kvm-unit-tests/kvm-unit-tests.git
Branch: master
Commit: 09e8c119b4cd7b615ea0ece16c92c79054dfb38d

Bug Detailed Description:
kvm-unit-tests can not be compiled due to "ld: Error: unable to disambiguate:
-no-pie". 
Checked ld version:
[root@emr-2s7 kvm-unit-tests]# ld --version
GNU ld version 2.36.1-4.el9
With older version (i.e., GNU ld version 2.35.2-39.el9), it can be compiled
well. Initially suspected, it should be a compiling issue.

Reproducing Steps:
git clone https://gitlab.com/kvm-unit-tests/kvm-unit-tests.git
cd kvm-unit-tests
./configure
make standalone

Actual Result:
...
rotector    -Wno-frame-address   -fno-pic  -Wclobbered 
-Wunused-but-set-parameter  -Wmissing-parameter-type  -Wold-style-declaration
-Woverride-init -Wmissing-prototypes -Wstrict-prototypes -std=gnu99
-ffreestanding -I /root/grf/kvm-unit-tests/lib -I
/root/grf/kvm-unit-tests/lib/x86 -I lib   -c -o x86/vmexit.o x86/vmexit.c
gcc -mno-red-zone -mno-sse -mno-sse2  -fcf-protection=full -m64 -O1 -g -MMD -MP
-MF x86/.cstart64.d -fno-strict-aliasing -fno-common -Wall -Wwrite-strings
-Wempty-body -Wuninitialized -Wignored-qualifiers -Wno-missing-braces -Werror 
-fno-omit-frame-pointer  -fno-stack-protector    -Wno-frame-address   -fno-pic 
-Wclobbered  -Wunused-but-set-parameter  -Wmissing-parameter-type 
-Wold-style-declaration -Woverride-init -Wmissing-prototypes
-Wstrict-prototypes -std=gnu99 -ffreestanding -I /root/grf/kvm-unit-tests/lib
-I /root/grf/kvm-unit-tests/lib/x86 -I lib -c -nostdlib -o x86/cstart64.o
x86/cstart64.S
ld -nostdlib  -no-pie -z noexecstack -m elf_x86_64 -T
/root/grf/kvm-unit-tests/x86/flat.lds -o x86/vmexit.elf \
        x86/vmexit.o x86/cstart64.o lib/libcflat.a
ld: Error: unable to disambiguate: -no-pie (did you mean --no-pie ?)
make: *** [/root/grf/kvm-unit-tests/x86/Makefile.common:70: x86/vmexit.elf]
Error 1


Expected Result:
The kvm-unit-tests suite should be compiled successfully.

-- 
You may reply to this email to add a comment.

You are receiving this mail because:
You are watching the assignee of the bug.

                 reply	other threads:[~2023-10-19  7:02 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-218026-28872@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@kernel.org \
    --cc=kvm@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.