-
-
Notifications
You must be signed in to change notification settings - Fork 143
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
rdmd: Support -shared in the same way as -lib #458
Conversation
Thanks for your pull request, @CyberShadow! Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub run digger -- build "master + tools#458" |
rdmd.d
Outdated
@@ -27,13 +27,15 @@ version (Posix) | |||
enum objExt = ".o"; | |||
enum binExt = ""; | |||
enum libExt = ".a"; | |||
enum dllExt = ".so"; |
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 should be .dylib
when built on Mac, otherwise looks good
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.
Good catch, fixed.
rdmd.d
Outdated
@@ -360,7 +367,7 @@ size_t indexOfProgram(string[] args) | |||
{ | |||
auto arg = args[i]; | |||
if (!arg.startsWith('-', '@') && | |||
!arg.endsWith(".obj", ".o", ".lib", ".a", ".def", ".map", ".res") && | |||
!arg.endsWith(".obj", ".o", ".lib", ".a", ".dll", ".so", ".def", ".map", ".res") && |
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.
ditto
changelog/rdmd_shared.dd
Outdated
@@ -0,0 +1,3 @@ | |||
rdmd supports `-shared` | |||
|
|||
rdmd now understands DMD's `-shared` switch, and sets the default output file name appropriately (`.dll` or `so` depending on the platform), in the same way as `-lib`. |
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.
I missed one on the changelog too, not that it really matters.
Feel free to merge when green.
ece2670
to
c950a65
Compare
-shared
is used #454