Closed ollydev closed 4 years ago
Do you mean programs built by sw or sw binary itself?
Programs built by SW. It would be similar to how the win-mt
flag is done, just passing a extra option to the compiler?
There is no such flag at the moment.
There is -os flag. Probably we could support version there.
Like -os macos-10.14
. What do you think? Is it understandable for you, other users?
That would be perfect.
It's the following in cmake:
SET(CMAKE_OSX_DEPLOYMENT_TARGET "10.13" CACHE STRING "Minimum OS X deployment version" FORCE)
Yes, but we also need or be able to control: 1) win sdk version 2) linux kernel version
...using some uniform syntax.
-os
looks good to me too.
I'm not sure other OS really apply to this. There doesn't exists flags for the other compilers (gcc, cl.exe) if you want a different kernel/sdk. You have to reinstall.
If this is correct maybe a new flag like -macos-version 10.13
would be more sufficient.
There doesn't exists flags for the other compilers (gcc, cl.exe) if you want a different kernel/sdk.
Yes, but sw will handle this in different ways for different OSes. For example, for windows it will set specific sdk version dependency. For linux - something else. (Maybe syscall list or linux kernel headers version.)
https://github.com/SoftwareNetwork/sw/commit/ac7229536a141084951bfdb638c68084e125a1db
You can try it on macos.
Pass -os macos-10.13
or other version.
Even -os macos-10.14,macos-10.15
.
Add -trace
to see commands as is to check for command line flag there.
Everything apart from macOS is broken if you're not aware: https://github.com/SoftwareNetwork/sw/runs/1115062720
Downloading database from origin remote
/home/runner/work/_temp/d9e4c3d7-5f74-4f9d-b4cb-71ec6ed09d87.sh: line 1: 4266 Segmentation fault (core dumped) ./sw -static build
Yes, I see. Cannot repro yet.
-os macos-10.13
worked well. Thanks! 😄
Feel free to report any other issues or feature requests!
Would it be possible to get an option to set MacOS target? I believe currently anything built with SW only runs on the latest macos version.
I think the option for apple clang is:
-mmacosx-version-min=<value> Set Mac OS X deployment target
Thanks