Re: How hide console in dub.sdl under windows 11?

2023-05-25 Thread Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn

On 26/05/2023 2:21 AM, ryuukk_ wrote:

dub is too dumb, i think "sourceFiles" only accept .d


Thats not true at all, its aware of what is a linker file and passes 
that off to the linker automatically:


https://github.com/dlang/dub/blob/6dd0508d90b3c072e26fcd59fedd757205603071/source/dub/compilers/utils.d#L43

This should work with .def, if it doesn't there is a bug and needs 
reporting.


https://github.com/dlang/dub/blob/6dd0508d90b3c072e26fcd59fedd757205603071/source/dub/generators/build.d#L632


Re: How to deal with interdependent dlang PRs?

2023-05-25 Thread Dennis via Digitalmars-d-learn

On Thursday, 25 May 2023 at 15:37:00 UTC, Quirin Schroll wrote:

Is there a process? I can’t be the first one running into this.


Doing it in 3 PRs is the process. This is one of the reasons why 
druntime was merged into dmd's repository. I remember someone 
saying that if you name the git branches the same, the CI checks 
out the PR's corresponding branch in other repositories, but I 
have no experience doing this so I'm not sure it will work.




How to deal with interdependent dlang PRs?

2023-05-25 Thread Quirin Schroll via Digitalmars-d-learn
I have 2 PRs, [one on 
dlang/dlang.org](https://github.com/dlang/dlang.org/pull/3446) 
and [one on dlang/dmd](https://github.com/dlang/dmd/pull/15245). 
The latter fails a test because an example on the (current) 
dlang.org fails. The dlang.org PR changes the example, and fails 
likewise it’s based on the changes in the dmd PR.


One measure I could think of:
1. Create a new dlang.org PR that (temporarily) removes the 
offending example; that one should not fail tests.
2. When it has been merged, the dmd PR will not fail anymore and 
can be merged.
3. The original dlang.org PR "reintroduces" the example with 
appropriate changes. It won’t fail because the compiler has been 
changed.


This seems a little convoluted. Is there a process? I can’t be 
the first one running into this.


Re: How hide console in dub.sdl under windows 11?

2023-05-25 Thread ryuukk_ via Digitalmars-d-learn

On Thursday, 25 May 2023 at 08:37:40 UTC, John Xu wrote:

For dmd, I can use a no_console.def file, which has:

EXETYPE NT
SUBSYSTEM WINDOWS


Then `dmd my.d no_console.def` to hide console.

But how do I realize it with dub.sdl ? Adding no_console.def to
"sourceFiles", doesn't help.


you can do that:

```json
"lflags-windows": [
"/SUBSYSTEM:windows",
],
```

dub is too dumb, i think "sourceFiles" only accept .d



Re: How hide console in dub.sdl under windows 11?

2023-05-25 Thread a11e99z via Digitalmars-d-learn

On Thursday, 25 May 2023 at 08:37:40 UTC, John Xu wrote:

For dmd, I can use a no_console.def file, which has:

EXETYPE NT
SUBSYSTEM WINDOWS


Then `dmd my.d no_console.def` to hide console.

But how do I realize it with dub.sdl ? Adding no_console.def to
"sourceFiles", doesn't help.


redirect to nul?
```command -args >nul 2>&1```


Re: ImportC for libuv

2023-05-25 Thread a11e99z via Digitalmars-d-learn

On Wednesday, 24 May 2023 at 18:49:02 UTC, a11e99z wrote:

someone might find it interesting how to use ImportC in life:

[https://issues.dlang.org/show_bug.cgi?id=23935](https://issues.dlang.org/show_bug.cgi?id=23935)


ADD
pragma pack issue
[https://issues.dlang.org/show_bug.cgi?id=23936](https://issues.dlang.org/show_bug.cgi?id=23936)


How hide console in dub.sdl under windows 11?

2023-05-25 Thread John Xu via Digitalmars-d-learn

For dmd, I can use a no_console.def file, which has:

EXETYPE NT
SUBSYSTEM WINDOWS


Then `dmd my.d no_console.def` to hide console.

But how do I realize it with dub.sdl ? Adding no_console.def to
"sourceFiles", doesn't help.