digitalmars.D - WindowsAPI as dub package
- Paul Z. Barsan (20/20) Sep 19 2014 Hi,
- evilrat (10/32) Sep 19 2014 there is no FULL WinAPI in Phobos(just too big for std lib), but
- Paul Z. Barsan (12/20) Sep 19 2014 Don't get mad buddy, I'm just asking for other opinions...
- winuser (5/27) Sep 19 2014 this is the kind of answer you get from the linux guys. there
- Andrei Alexandrescu (2/5) Sep 19 2014 That's... quite inaccurate. -- Andrei
- ketmar via Digitalmars-d (9/12) Sep 19 2014 windows is the dead cow, so we tend to just ignore the questions about
- Gary Willoughby (14/26) Sep 19 2014 I had the same problem with X11 (as mentioned above) i just
- Paul Z. Barsan (19/27) Sep 19 2014 Someone already did and made a pull request with a dub.json
- Vladimir Panteleev (10/21) Sep 19 2014 Does Dub support Git submodules (can it clone Git repositories
Hi, I've recently used cairoD for drawing and I thought it would be nice to have support for win32 surfaces. In order to add support for this feature I need a winapi-d package for dub.So far I've found some personal mirrors and clones on github such as: https://github.com/AndrejMitrovic/WindowsAPI https://github.com/CS-svnmirror/dsource-bindings-win32 but so far nobody dares to maintain a big pkg like this. Are there more experienced users willing to do this ? The main problem is that the development still takes place on dsource.org. Can dub get packages from svn repositories ? If it doesn't, how can we solve this? Maybe a new github organization like "dub-packagers" to involve more people and avoid to much effort for one man with a personal account? Someone said there is windows API support in phobos. I've seen there are stc.c.windows.windows and core.sys.windows.windows modules but they don't appear in the online documentation (http://dlang.org/phobos/).Are those modules meant to be used by clients and the docs are outdated or is just dmd internal stuff ? Thanks in advance !
Sep 19 2014
On Friday, 19 September 2014 at 12:10:05 UTC, Paul Z. Barsan wrote:Hi, I've recently used cairoD for drawing and I thought it would be nice to have support for win32 surfaces. In order to add support for this feature I need a winapi-d package for dub.So far I've found some personal mirrors and clones on github such as: https://github.com/AndrejMitrovic/WindowsAPI https://github.com/CS-svnmirror/dsource-bindings-win32 but so far nobody dares to maintain a big pkg like this. Are there more experienced users willing to do this ? The main problem is that the development still takes place on dsource.org. Can dub get packages from svn repositories ? If it doesn't, how can we solve this? Maybe a new github organization like "dub-packagers" to involve more people and avoid to much effort for one man with a personal account? Someone said there is windows API support in phobos. I've seen there are stc.c.windows.windows and core.sys.windows.windows modules but they don't appear in the online documentation (http://dlang.org/phobos/).Are those modules meant to be used by clients and the docs are outdated or is just dmd internal stuff ? Thanks in advance !there is no FULL WinAPI in Phobos(just too big for std lib), but everything(almost) required for cairo is already there. why do we need full WinAPI if cairo just uses few structs for non critical stuff like fonts and icons description? and if you REALLY need whole WinAPI just get those dsource bindings and set up as import path in dmd config. as for documentation, i don't think ddoc insert docs for public imports modules like std.c.windows.windows...
Sep 19 2014
On Friday, 19 September 2014 at 12:37:25 UTC, evilrat wrote:there is no FULL WinAPI in Phobos(just too big for std lib), but everything(almost) required for cairo is already there. why do we need full WinAPI if cairo just uses few structs for non critical stuff like fonts and icons description? and if you REALLY need whole WinAPI just get those dsource bindings and set up as import path in dmd config. as for documentation, i don't think ddoc insert docs for public imports modules like std.c.windows.windows...Don't get mad buddy, I'm just asking for other opinions... What if I want to make a library that uses cairoD ? I will carefully instruct all my clients to alter dmd.conf and declare some structs here and there and some export declarations in client code? Sorry, but those are hacks and don't look good in client code. It should work out of the box with dub. The reason for me being sceptical about std.c.windows.windows is that on the linux side of things, cairoD was importing std.c.linux.X11 and on my machine the X11 bindings were not there. They went to deimos and there is an "x11" dub package which is a clone of deimos.X11 ...
Sep 19 2014
this is the kind of answer you get from the linux guys. there seems to be no interest in windows, so - you are on your own. windows is the ugly orphan here. On Friday, 19 September 2014 at 13:11:55 UTC, Paul Z. Barsan wrote:On Friday, 19 September 2014 at 12:37:25 UTC, evilrat wrote:there is no FULL WinAPI in Phobos(just too big for std lib), but everything(almost) required for cairo is already there. why do we need full WinAPI if cairo just uses few structs for non critical stuff like fonts and icons description? and if you REALLY need whole WinAPI just get those dsource bindings and set up as import path in dmd config. as for documentation, i don't think ddoc insert docs for public imports modules like std.c.windows.windows...Don't get mad buddy, I'm just asking for other opinions... What if I want to make a library that uses cairoD ? I will carefully instruct all my clients to alter dmd.conf and declare some structs here and there and some export declarations in client code? Sorry, but those are hacks and don't look good in client code. It should work out of the box with dub. The reason for me being sceptical about std.c.windows.windows is that on the linux side of things, cairoD was importing std.c.linux.X11 and on my machine the X11 bindings were not there. They went to deimos and there is an "x11" dub package which is a clone of deimos.X11 ...
Sep 19 2014
On 9/19/14, 6:29 AM, winuser wrote:this is the kind of answer you get from the linux guys. there seems to be no interest in windows, so - you are on your own. windows is the ugly orphan here.That's... quite inaccurate. -- Andrei
Sep 19 2014
On Fri, 19 Sep 2014 13:29:46 +0000 winuser via Digitalmars-d <digitalmars-d puremagic.com> wrote:this is the kind of answer you get from the linux guys. there seems to be no interest in windows, so - you are on your own. windows is the ugly orphan here.windows is the dead cow, so we tend to just ignore the questions about dead cows. but if we have something to say to help someone, we does that. it's "the open-source attitude", you know, to helping each other. yet we trying to not use windows, so we have very little knowledge of it. and many windows users who have that knowledge choses to hide that knowledge and ranting about "unhelpful linux guys". go on, boys, this actions will surely help other windows users.
Sep 19 2014
On Friday, 19 September 2014 at 12:10:05 UTC, Paul Z. Barsan wrote:Hi, The main problem is that the development still takes place on dsource.org. Can dub get packages from svn repositories ? If it doesn't, how can we solve this? Maybe a new github organization like "dub-packagers" to involve more people and avoid to much effort for one man with a personal account?I had the same problem with X11 (as mentioned above) i just copied the repo from deimos and put it on the dub repository myself. I will only remove it if the official one is moved to there. I would try and contact the maintainers on github, etc. and ask for them to be placed in the dub repository. If you have no luck with that just do it yourself like i did with the x11 repo.Someone said there is windows API support in phobos. I've seen there are stc.c.windows.windows and core.sys.windows.windows modules but they don't appear in the online documentation (http://dlang.org/phobos/).Are those modules meant to be used by clients and the docs are outdated or is just dmd internal stuff ?stc.c.windows.windows is meant to be used by developers and can be contributed to if something is missing. Stuff under the core module: core.sys.windows.windows is usually for internal usage but there's no reason why it can't be utilised by developers. If it's public, use it.
Sep 19 2014
On Friday, 19 September 2014 at 14:04:08 UTC, Gary Willoughby wrote:I would try and contact the maintainers on github, etc. and ask for them to be placed in the dub repository. If you have no luck with that just do it yourself like i did with the x11 repo.Someone already did and made a pull request with a dub.json package description: https://github.com/AndrejMitrovic/WindowsAPI/pull/2 but Andrej Mitrovic said that the dsource developers should handle it. I don't want to bug people and ask the same question.I don't have dub packaging experience , neither a windows operating system to begin with but someday I may need to port to windows and still use dub as a build system.stc.c.windows.windows is meant to be used by developers and can be contributed to if something is missing. Stuff under the core module: core.sys.windows.windows is usually for internal usage but there's no reason why it can't be utilised by developers. If it's public, use it.Yeah but std.c.windows.windows contains only one import to core.sys.windows.windows ( https://github.com/D-Programming-Language/phobos/blob/master/std c/windows/windows.d ) so there is not much to contribute on this module. My last option will be just what you did, clone and publish but it won't be in the near future. I was thinking there are more WindowsAPI users that want to move to dub build system or maybe some dsource developers around here willing to move to github and make it faster.Wishful thinking ...
Sep 19 2014
On Friday, 19 September 2014 at 12:10:05 UTC, Paul Z. Barsan wrote:I've recently used cairoD for drawing and I thought it would be nice to have support for win32 surfaces. In order to add support for this feature I need a winapi-d package for dub.So far I've found some personal mirrors and clones on github such as: https://github.com/AndrejMitrovic/WindowsAPI https://github.com/CS-svnmirror/dsource-bindings-win32 but so far nobody dares to maintain a big pkg like this. Are there more experienced users willing to do this ?Does Dub support Git submodules (can it clone Git repositories with --recursive)? If so, you could create a Dub package with a submodule which tracks the master branch of the dsource-bindings-win32 mirror.The main problem is that the development still takes place on dsource.org.I think the long-term plan is to move the entire bindings (sans DirectX, probably) into Druntime. But it's a good deal of work (esp. considering backwards compatibility with the existing declarations) and no one has done it yet.
Sep 19 2014