Thread overview
combining libraries into 1 or 1 for each system?
Sep 19, 2019
Shadowblitz16
Sep 19, 2019
Mike Parker
Sep 19, 2019
Shadowblitz16
Sep 19, 2019
Mike Parker
Sep 19, 2019
Shadowblitz16
September 19, 2019
let's say I have a project the relies on multiple packages..
is it possible to combine these libraries into a single one (or 1 per os) for final shipment of a program?
September 19, 2019
On Thursday, 19 September 2019 at 03:44:28 UTC, Shadowblitz16 wrote:
> let's say I have a project the relies on multiple packages..
> is it possible to combine these libraries into a single one (or 1 per os) for final shipment of a program?

I assume you're referring to dub packages, in which case any dependencies you have will usually be configured to compile as static libraries. That means they'll be compiled into the executable without any extra effort on your part.

If they're configured as dynamic libraries, you'll need to ship the dynamic library with your executable or manually edit the configurations to compile as static libraries.

If they're bindings to C libraries, you'll need to ship the C dynamic libraries unless you statically link them.

If none of this answers your question, please clarify what you mean by "multiple packages".
September 19, 2019
On Thursday, 19 September 2019 at 05:16:33 UTC, Mike Parker wrote:
> On Thursday, 19 September 2019 at 03:44:28 UTC, Shadowblitz16 wrote:
>> let's say I have a project the relies on multiple packages..
>> is it possible to combine these libraries into a single one (or 1 per os) for final shipment of a program?
>
> I assume you're referring to dub packages, in which case any dependencies you have will usually be configured to compile as static libraries. That means they'll be compiled into the executable without any extra effort on your part.
>
> If they're configured as dynamic libraries, you'll need to ship the dynamic library with your executable or manually edit the configurations to compile as static libraries.
>
> If they're bindings to C libraries, you'll need to ship the C dynamic libraries unless you statically link them.
>
> If none of this answers your question, please clarify what you mean by "multiple packages".

I mean I don't want to have multiple dependency dll's but instead just my own dll with the dependencies packed inside.

of course dll is only for windows so I would like this done for mac and linux too
September 19, 2019
On Thursday, 19 September 2019 at 18:28:25 UTC, Shadowblitz16 wrote:

> I mean I don't want to have multiple dependency dll's but instead just my own dll with the dependencies packed inside.
>
> of course dll is only for windows so I would like this done for mac and linux too

Then statically link all your dependencies.
September 19, 2019
On Thursday, 19 September 2019 at 19:10:26 UTC, Mike Parker wrote:
> On Thursday, 19 September 2019 at 18:28:25 UTC, Shadowblitz16 wrote:
>
>> I mean I don't want to have multiple dependency dll's but instead just my own dll with the dependencies packed inside.
>>
>> of course dll is only for windows so I would like this done for mac and linux too
>
> Then statically link all your dependencies.

ok cool I will look into this.