configure: fix duplicate of -lrt flag #2
Closed
totoroliu wants to merge 1 commits from
master
into master
pull from: master
merge into: dfaggioli:master
dfaggioli:factory
dfaggioli:v10.0-factory
dfaggioli:v9.2-factory
dfaggioli:v7.1-sle15sp5
dfaggioli:v8.2-sle15sp6
dfaggioli:opensuse-5.2
dfaggioli:v6.2-sle15sp4
dfaggioli:v8.2-sle15sp6-snp-tdx
dfaggioli:v9.1-factory
dfaggioli:factory-tmp
dfaggioli:opensuse-3.1
dfaggioli:v9.0-factory
dfaggioli:v7.2-sle15sp5-tdx
dfaggioli:v8.2-sle15sp6-tdx
dfaggioli:v6.2.0-sle15sp4
dfaggioli:opensuse-2.9
dfaggioli:opensuse-2.6
dfaggioli:opensuse-4.2
dfaggioli:opensuse-7.1
dfaggioli:opensuse-6.2
dfaggioli:opensuse-7.0
dfaggioli:opensuse-2.11
dfaggioli:opensuse-6.1
dfaggioli:opensuse-6.0
dfaggioli:opensuse-1.4
dfaggioli:bsc1179719
dfaggioli:opensuse-5.1
dfaggioli:opensuse-5.0
dfaggioli:opensuse-4.1
dfaggioli:opensuse-4.0
dfaggioli:opensuse-3.0
dfaggioli:opensuse-2.12
dfaggioli:opensuse-2.10
dfaggioli:opensuse-2.8
dfaggioli:opensuse-2.7
dfaggioli:opensuse-2.1
dfaggioli:opensuse-2.5
dfaggioli:opensuse-2.4
dfaggioli:opensuse-2.3
dfaggioli:opensuse-1.6
dfaggioli:opensuse-2.2
dfaggioli:opensuse-2.0
dfaggioli:opensuse-1.7
dfaggioli:opensuse-1.3
dfaggioli:opensuse-1.5
dfaggioli:opensuse-1.1
dfaggioli:stable-1.3
dfaggioli:stable-1.2
dfaggioli:opensuse-1.2
dfaggioli:stable-1.1
dfaggioli:opensuse-1.0
dfaggioli:stable-1.0
dfaggioli:stable-0.15
dfaggioli:stable-0.14
dfaggioli:stable-0.13
dfaggioli:stable-0.12
dfaggioli:stable-0.11
dfaggioli:stable-0.10
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
No description provided.
Delete Branch "master"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
'-lrt' flag duplication would cause 'undefined reference to clock_gettime' error
during compilation time.
Before fix:
... -o qemu-bridge-helper qemu-bridge-helper.o -lrt -pthread -lgthread-2.0 -lrt -lglib-2.0
After fix:
... -o qemu-bridge-helper qemu-bridge-helper.o -pthread -lgthread-2.0 -lrt -lglib-2.0
Reference:
http://hi.baidu.com/sanitywolf/item/7a8b69c1e76dd220a0b50ab1
Hi Rick,
Where are you seeing such a build error? I'm not seeing it in our devel project:
https://build.opensuse.org/package/show/Virtualization/qemu
https://build.opensuse.org/package/show/Virtualization/qemu-linux-user
Are you maybe using GCC 4.9?
Further your patch does not seem to be in upstream qemu.git. If you haven't already, please submit it to qemu-devel according to http://wiki.qemu-project.org/Contribute/SubmitAPatch (note: Signed-off-by is missing on your commit), then we can easily cherry-pick that patch onto our branch if needed.
Thanks,
Andreas
Hi Andreas,
I'm actually using an old gcc 4.6.1.
I just found out you did the fix via SPEC file instead of via upstream qemu.git.
qemu-linux-user.spec:
LINE 186:
-lrt needs to come after -lglib-2.0 to avoid undefined clock_gettime
sed -i "s/-lglib-2.0/-lglib-2.0 -lrt/" config-host.mak
I'll remove the pull request.
Thanks,
Rick
Pull request closed