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

Examples-Makefile optional compiler assignment #143

Merged
merged 2 commits into from
May 14, 2023
Merged

Examples-Makefile optional compiler assignment #143

merged 2 commits into from
May 14, 2023

Conversation

SoujiThenria
Copy link
Contributor

Notice

  • I understand the code that I have edited, and have the means
    to test it before making changes to Concord.

What?

This pull request changes the assignment of the CC variable to gcc only if CC is not already set to something.

Why?

No other Makefile in this project includes a specific assignment for the CC variable and uses the one defined by the system or the user.
If no gcc is installed on the system, e.g. clang concord will build but the examples not.

How?

The assignment is optional and will be set to gcc if CC is not defined.

Testing?

Testing was done by building Concord and the examples.

@tarbomb
Copy link
Collaborator

tarbomb commented Mar 12, 2023

Why not just cc instead of gcc?

@SoujiThenria
Copy link
Contributor Author

Why not just cc instead of gcc?

gcc is the current value. I thought there might be a reason for that.
I wouldn't mind changing it to cc.

@tarbomb
Copy link
Collaborator

tarbomb commented Mar 12, 2023

Ah, alright. Yeah, cc is going to be better. This is probably something we should've done from the get-go.

@lcsmuller lcsmuller merged commit 2a362d1 into Cogmasters:master May 14, 2023
@Ratakor
Copy link
Contributor

Ratakor commented Jul 9, 2023

Actually this line could be removed because make already set CC by default thus doing CC ?= nul will have no effect too.

@SoujiThenria
Copy link
Contributor Author

That is true. It is also nowhere set separately besides gencodecs/Makefile. Using the default value set by make would be consistent throughout the project.

@HackerSmacker
Copy link
Collaborator

The system-wide make rules are supposed to set CC, but, if /usr/share/mk is nonexistent or broken, boom... yeah, this ought to be changed. the ?= method is clunky!

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

Successfully merging this pull request may close these issues.

5 participants