diff options
| author | Mike Wey | 2017-05-25 20:20:06 +0200 |
|---|---|---|
| committer | Mike Wey | 2017-05-25 20:20:06 +0200 |
| commit | 4df3136229de711838646a65b6cf040226eeb7cb (patch) | |
| tree | a2ee596419028cd458325d224439854f8b82063e /dub.json | |
| parent | 87c811161c608f8428ff8e399c60f9672c6cfc7e (diff) | |
Add dub support.
dub will generate the import library of 32bit windows (OMF), the other
windows targets might need some more work.
See: #12
Diffstat (limited to 'dub.json')
| -rw-r--r-- | dub.json | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/dub.json b/dub.json new file mode 100644 index 0000000..68f6288 --- /dev/null +++ b/dub.json @@ -0,0 +1,34 @@ +{ + "name": "dmagick", + "description": "An ImageMagick binding for the D Programming Language.", + "authors": ["Mike Wey"], + "license": "Zlib", + "targetType": "library", + "sourcePaths": ["dmagick"], + "importPaths": ["dmagick"], + "libs": ["MagickCore"], + "configurations": [ + { + "name": "windows", + "platforms": ["windows"], + "sourceFiles-x86": ["MagickCore.lib"], + "preGenerateCommands": [ + "powershell -Command \"get-content $PACKAGE_DIR/dmagick/c/magickVersion.d.in | %{$$_ -replace '@MagickLibVersion@','700'} | %{$$_ -replace '@MagickLibVersionText@','7.0.0'} | %{$$_ -replace '@QuantumDepth@','16'} | %{$$_ -replace '@HDRI@','false'} | Set-Content $PACKAGE_DIR/dmagick/c/magickVersion.d.in\"" + ], + "preGenerateCommands-x86": [ + "@echo @for %%i in (%1) do @if NOT \"%%~$PATH:i\"==\"\" @copy \"%%~$PATH:i\" $PACKAGE_DIR/ > copydll.bat", + "copydll CORE_RL_magick_.dll", + "implib /s $PACKAGE_DIR/MagickCore.lib $PACKAGE_DIR/CORE_RL_magick_.dll", + "@del copydll.bat", + "del $PACKAGE_DIR/CORE_RL_magick_.dll" + ] + + }, + { + "name": "other", + "preGenerateCommands": [ + "PACKAGE_DIR=$PACKAGE_DIR $PACKAGE_DIR/build-aux/magickVersion.sh" + ] + } + ] +} |
