Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.package_note-fluent-package-5.0.1-1.amzn2023.x86_64.ld is no exist #590

Open
wdxal opened this issue Sep 22, 2023 · 2 comments
Open

.package_note-fluent-package-5.0.1-1.amzn2023.x86_64.ld is no exist #590

wdxal opened this issue Sep 22, 2023 · 2 comments

Comments

@wdxal
Copy link

wdxal commented Sep 22, 2023

OS:AmaonLinux2023
Version:5.0.1-1(LTS)
Install:
Step 1:
curl -fsSL https://toolbelt.treasuredata.com/sh/install-amazon2023-fluent-package5-lts.sh | sh
Step 2:
fluent-gem install mysql2

Error:
$ cat /opt/fluent/lib/ruby/gems/3.2.0/extensions/x86_64-linux/3.2.0/mysql2-0.5.5/mkmf.log
LD_LIBRARY_PATH=.:/opt/fluent/lib "gcc -o conftest -I/opt/fluent/include/ruby-3.2.0/x86_64-linux -I/opt/fluent/include/ruby-3.2.0/ruby/backward -I/opt/fluent/include/ruby-3.2.0 -I. -O2 -ftree-vectorize -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC conftest.c -L. -L/opt/fluent/lib -Wl,-rpath,/opt/fluent/lib -L. -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT,/root/rpmbuild/BUILD/fluent-package-5.0.1/.package_note-fluent-package-5.0.1-1.amzn2023.x86_64.ld -fstack-protector-strong -rdynamic -Wl,-export-dynamic -Wl,--no-as-needed -m64 -Wl,-rpath,/opt/fluent/lib -L/opt/fluent/lib -lruby -lm -lpthread -lc"
/usr/bin/ld: cannot open linker script file /root/rpmbuild/BUILD/fluent-package-5.0.1/.package_note-fluent-package-5.0.1-1.amzn2023.x86_64.ld: No such file or directory
collect2: error: ld returned 1 exit status
checked program was:
/* begin */
1: #include "ruby.h"
2:
3: int main(int argc, char *argv)
4: {
5: return !!argv[argc];
6: }
/
end */

Q:
From the error message, the file(.package_note-fluent-package-5.0.1-1.amzn2023.x86_64.ld) is required when installing the mysql2 plug-in. Is this file created when fluent-package is installed?

@kenhys
Copy link
Contributor

kenhys commented Oct 12, 2023

Is this file created when fluent-package is installed?

No, fluent-package doesn't install such a file.

Reported problem was reproducible. 🤔

@rm-you
Copy link

rm-you commented Mar 28, 2024

I am having almost exactly the same problem.
Amazon Linux 2023
Linux ip-10-200-0-210.ec2.internal 6.1.79-99.167.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Mar 12 18:15:55 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

$ cat /opt/fluent/lib/ruby/gems/3.2.0/extensions/x86_64-linux/3.2.0/msgpack-1.3.3/mkmf.log LD_LIBRARY_PATH=.:/opt/fluent/lib "gcc -o conftest -I/opt/fluent/include/ruby-3.2.0/x86_64-linux -I/opt/fluent/include/ruby-3.2.0/ruby/backward -I/opt/fluent/include/ruby-3.2.0 -I. -O2 -ftree-vectorize -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC conftest.c -L. -L/opt/fluent/lib -Wl,-rpath,/opt/fluent/lib -L. -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT,/root/rpmbuild/BUILD/fluent-package-5.0.2/.package_note-fluent-package-5.0.2-1.amzn2023.x86_64.ld -fstack-protector-strong -rdynamic -Wl,-export-dynamic -Wl,--no-as-needed -m64 -Wl,-rpath,/opt/fluent/lib -L/opt/fluent/lib -lruby -lm -lpthread -lc" /usr/bin/ld: cannot open linker script file /root/rpmbuild/BUILD/fluent-package-5.0.2/.package_note-fluent-package-5.0.2-1.amzn2023.x86_64.ld: No such file or directory collect2: error: ld returned 1 exit status checked program was: /* begin */ 1: #include "ruby.h" 2: 3: int main(int argc, char **argv) 4: { 5: return !!argv[argc]; 6: } /* end */

Can be reproduced for me by installing anything that requires msgpack (or just installing msgpack). Probably other things too, that's just my repro case. This whole directory structure starting with /root/rpmbuild does not exist, probably something hardcoded somewhere in an install script?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants