-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Add Macports legacy software options to builder #26691
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
base: master
Are you sure you want to change the base?
Changes from 1 commit
a719f46
b66889d
5241426
3fff57d
c1ec04b
29325a4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -199,6 +199,12 @@ fn (mut v Builder) setup_ccompiler_options(ccompiler string) { | |
| if os.uname().machine == 'Power Macintosh' { | ||
| user_darwin_ppc = true | ||
| } | ||
|
|
||
| // Mac OS 10.4 and older requires Macports legacy software to build programs | ||
| if user_darwin_version <= 8 { | ||
| ccoptions.args << "-I./thirdparty/legacy/include/LegacySupport/" | ||
| ccoptions.args << "./thirdparty/legacy/lib/libMacportsLegacySupport.a" | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
The archive is added to Useful? React with 👍 / 👎.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 👎 It works just fine on Mac OS 10.4.
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perhaps, but wouldn't it be better to have the second line start with
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I tried this and used this code: |
||
| } | ||
| } | ||
| ccoptions.debug_mode = v.pref.is_debug | ||
| ccoptions.guessed_compiler = v.pref.ccompiler | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These new flags use
./thirdparty/legacy/..., which is resolved from the caller's current working directory rather than the V installation/repo root.setup_ccompiler_optionsruns for normalvbuilds from arbitrary project folders, so on Darwin <= 8 this will often point to missing files and fail with header/library not found errors. Please build these paths from@VEXEROOT/v.pref.vroot(and quote them) like other thirdparty references.Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is always a good idea. Just in case, somehow, the current directory gets changed, such that
./thirdpartyis no longer correct.