On 7/18/21 10:28 AM, Vindex wrote:

> ```
> ldc2 source/main.d -ofmyprogram -L-l:libmylib.so.0
> Error: file "thing.json" cannot be found or not in a path specified with -J
> ```
>
> Is the actual inclusion of the file on import deferred until the link step?

I wonder whether it's an ldc thing related to its link-time powers?

> I could insert the entire json into the file, but I would hate to do that.

I insert two many-megabytes long tar.gz files in there. :) I unzip and untar the files into a cache directory to use at runtime. I just works. The zipped version of a json file may be very small.

I my case, the files are gzip'ped during the build stage and I unzip with

  https://dlang.org/phobos/std_zlib.html

Ali

Reply via email to