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

share/verilator/include/verilated.mk contains non-existent AR=/usr/local/bin/ar on FreeBSD #4213

Closed
yurivict opened this issue May 21, 2023 · 7 comments
Labels
new New issue not seen by maintainers

Comments

@yurivict
Copy link
Contributor

On FreeBSD it installs the file share/verilator/include/verilated.mk with this line:

AR = /usr/local/bin/ar

The build should find the ar executable and use it, for example:

$ which ar
/usr/bin/ar

Version: 5.010
FreeBSD 13.2 STABLE

@yurivict yurivict added the new New issue not seen by maintainers label May 21, 2023
@christopher-bowman
Copy link

yes making the change in share/verilator/include/verilated.mk seems to work for me (I just didn't know where to look, thank you)

@igalic
Copy link

igalic commented May 21, 2023

it might be good to change this to

AR ?= /usr/bin/ar

i reckon many package build systems might set that variable

@yurivict
Copy link
Contributor Author

I think that this line should be just:

AR = ar

to allow the PATH variable to determine the path.

@wsnyder
Copy link
Member

wsnyder commented May 22, 2023

Note it comes from whatever ./configure determines. You can override it with "./configure AR=ar".

@yurivict
Copy link
Contributor Author

Note it comes from whatever ./configure determines. You can override it with "./configure AR=ar".

Then this is a bug in configure because /usr/local/bin/ar doesn't exist on this platform.

@wsnyder
Copy link
Member

wsnyder commented May 22, 2023

What does ./configure print?

 checking for ar... ar

You can add echos or whatever to debug the shell code in "configure" that computes this. Most likely you do have a $AR variable, or ar is in your $PATH. This code shouldn't be able to pull "/usr/local/bin" from nowhere.

@yurivict
Copy link
Contributor Author

I found what the problem was.

For whatever reason verilator's port build requires ar from binutils. But binutils wasn't present at the runtime, so /usr/local/bin/ar provided by binutils isn't present.

Some time back binutils was added as dependency to solve some problem, I don't remember what problem that was.

I will correct the port.

Thank you for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new New issue not seen by maintainers
Projects
None yet
Development

No branches or pull requests

4 participants