When trying to compile with OpenCSW GCC, I'm getting the following error:

ld: fatal: file crt1.o: open failed: No such file or directory

This error occurs on an Intel host, but not on a SPARC host. What should provide the file?

This question is marked "community wiki".

asked 19 Apr '12, 11:39

automaciej's gravatar image

automaciej ♦♦
93273037
accept rate: 55%


the package "lint" contains the file for Opensolaris snv_134

permanent link

answered 19 Apr '12, 11:45

Seemone's gravatar image

Seemone
161
accept rate: 0%

Hi,
it's been some time since this questions was asked, by I happend to stumble on this same issue yesterday on a kind of fresh Solaris 10 x86 install. First check that package SUNWarc is installed (I think it should be always installed, I guess..):
bash-3.2# pkgchk -l SUNWarc|grep ^Pathname |awk '{print $2}'|grep crt1 /usr/lib/amd64/crt1.o /usr/lib/amd64/gcrt1.o /usr/lib/crt1.o /usr/lib/gcrt1.o Then check if you did set up correctly your compilation flags, particularly LDFLAGS, something like:
LDFLAGS="-L/opt/csw/lib -L/lib/ -L/usr/lib"

Note: Maybe I'm wrong here, or this might not be all what's needed - I did so much hacking around yesterday and the day before, I don't remember exactly what I did to solve this (and I forgot to take notes on this particular problem).

permanent link

answered 03 Mar '16, 11:41

Gerardo's gravatar image

Gerardo
112
accept rate: 0%

edited 03 Mar '16, 12:47

Ah! ..And I think the linker your PATH points to is also important; try to include /usr/ccs/bin/ in your PATH.

permanent link

answered 03 Mar '16, 12:50

Gerardo's gravatar image

Gerardo
112
accept rate: 0%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×2
×2

question asked: 19 Apr '12, 11:39

question was seen: 16,367 times

last updated: 03 Mar '16, 12:50

powered by OSQA