-
-
Save vegardsjo/3906446 to your computer and use it in GitHub Desktop.
Wrapper for ld to make dmd accept -L"-framework=name"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import std.process; | |
| import std.regex; | |
| import std.array; | |
| const string executable = "ld.orig"; | |
| void main(string argv[]) | |
| { | |
| auto reg = regex(r"-framework=([^ ]+)", "g"); | |
| auto cmdline = replace(argv[1..$].join(" "), reg, r"-framework $1"); | |
| execvp(executable, cmdline.split()); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment