www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - I need "windowsx.d" Someone can send It to me?

reply Marcone <marcone email.com> writes:
I need windowsx.d but for I don't know the reason is not in dmd. 
Someone that have it can send to me? I don't know convert 
windowsx.h to windowsx.d
Sep 25 2020
next sibling parent reply Denis Feklushkin <denis.feklushkin gmail.com> writes:
On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
Try to convert C header into D file by dpp tool.
Sep 25 2020
parent reply Marcone <marcone email.com> writes:
On Friday, 25 September 2020 at 17:00:04 UTC, Denis Feklushkin 
wrote:
 On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
Try to convert C header into D file by dpp tool.
When I try dpp in this tutorial: Windows Install http://releases.llvm.org/6.0.1/LLVM-6.0.1-win64.exe into C:\Program Files\LLVM\, making sure to tick the "Add LLVM to the system PATH for all users" option. Make sure you have LDC installed somewhere. Compile with dub build --compiler=C:\path\to\bin\ldc2.exe. Copy C:\Program Files\LLVM\bin\libclang.dll next to the d++.exe in the bin directory. When I try this command: Compile with dub build --compiler=C:\path\to\bin\ldc2.exe I get this error: Neither a package description file, nor source/app.d was found in D:\Downloads Please run DUB from the root directory of an existing package, or run "dub init --help" to get information on creating a new package. No valid root package found - aborting.
Sep 25 2020
parent reply Denis Feklushkin <feklushkin.denis gmail.com> writes:
On Saturday, 26 September 2020 at 00:40:21 UTC, Marcone wrote:
 On Friday, 25 September 2020 at 17:00:04 UTC, Denis Feklushkin 
 wrote:
 On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know 
 convert windowsx.h to windowsx.d
Try to convert C header into D file by dpp tool.
When I try dpp in this tutorial:
URL? If you have DUB and compiler installed try to run: dub fetch dpp dub build dpp dub run dpp -- --help It works on Linux for me
Sep 25 2020
parent Marcone <marcone email.com> writes:
On Saturday, 26 September 2020 at 01:43:00 UTC, Denis Feklushkin 
wrote:
 On Saturday, 26 September 2020 at 00:40:21 UTC, Marcone wrote:
 On Friday, 25 September 2020 at 17:00:04 UTC, Denis Feklushkin 
 wrote:
 On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know 
 convert windowsx.h to windowsx.d
Try to convert C header into D file by dpp tool.
When I try dpp in this tutorial:
URL? If you have DUB and compiler installed try to run: dub fetch dpp dub build dpp dub run dpp -- --help It works on Linux for me
Good, but don't work converted file windowsx.h to windowsx.d.
Sep 25 2020
prev sibling next sibling parent John Chapman <johnch_atms hotmail.com> writes:
On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
windowsx.h is mostly a bunch of macros that forward to functions elsewhere in the SDK. Yes, it's handy, but you can get by without it in case you don't manage to get it translated to D. Open windowsx.h in your editor, find the macro you want to use, look across to the right to see what the macro expands to, and use that in your code instead. A lot of the macros that simply cast between HBITMAP, HPALETTE, HFONT, HPEN, HGDIOBJ etc are redundant because in D they're all just aliases for void*.
Sep 25 2020
prev sibling next sibling parent reply Imperatorn <johan_forsberg_86 hotmail.com> writes:
On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
You don't want to just include it? https://atilaoncode.blog/2018/04/09/include-c-headers-in-d-code/
Sep 27 2020
parent Andre Pany <andre s-e-a-p.de> writes:
On Sunday, 27 September 2020 at 07:55:56 UTC, Imperatorn wrote:
 On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
You don't want to just include it? https://atilaoncode.blog/2018/04/09/include-c-headers-in-d-code/
Dpp is not able to translate macros (maybe in the future). Macros needs to be translated manually. Kind regards Andre
Sep 27 2020
prev sibling next sibling parent Imperatorn <johan_forsberg_86 hotmail.com> writes:
On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
https://wiki.dlang.org/Bindings#Binding_generators
Sep 27 2020
prev sibling next sibling parent Denis Feklushkin <denis.feklushkin gmail.com> writes:
On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
Maybe it is already available on code.dlang.org?
Sep 27 2020
prev sibling parent reply Imperatorn <johan_forsberg_86 hotmail.com> writes:
On Friday, 25 September 2020 at 15:03:56 UTC, Marcone wrote:
 I need windowsx.d but for I don't know the reason is not in 
 dmd. Someone that have it can send to me? I don't know convert 
 windowsx.h to windowsx.d
I converting it using VisualD: https://pastebin.com/jzwKRnKZ Try it, maybe it works
Sep 27 2020
parent Elronnd <elronnd elronnd.net> writes:
On Sunday, 27 September 2020 at 18:30:10 UTC, Imperatorn wrote:
 I converting it using VisualD:
 https://pastebin.com/jzwKRnKZ

 Try it, maybe it works
Somehow, I don't think this is going to fly: static if(__cplusplus) { extern (C) { /* Assume C declarations for C++ */ } /* __cplusplus */
Sep 28 2020