Re: DMD license question

2017-08-08 Thread Jacob Carlborg via Digitalmars-d

On 2017-08-08 22:50, Jacob Carlborg wrote:

On 2017-08-08 16:28, meppl wrote:


in case your main application is written in D, too:  how do you avoid
symbol name collisions?


D symbols are mangled to include the package and module name. That will
make a collision less likely.



The pseudo-handles RTLD_DEFAULT and RTLD_NEXT [1] might be of use as well.

[1] https://linux.die.net/man/3/dlsym

--
/Jacob Carlborg


Re: DMD license question

2017-08-08 Thread Jacob Carlborg via Digitalmars-d

On 2017-08-08 16:28, meppl wrote:


in case your main application is written in D, too:  how do you avoid
symbol name collisions?


D symbols are mangled to include the package and module name. That will 
make a collision less likely.


--
/Jacob Carlborg


Re: DMD license question

2017-08-08 Thread Andre Pany via Digitalmars-d

On Tuesday, 8 August 2017 at 14:28:30 UTC, meppl wrote:

On Monday, 7 August 2017 at 21:28:52 UTC, Andre Pany wrote:

Hi,

as DMD is now under Boost Software License, can I distribute 
it as part of my commercial product?


I want to provide script support within my application. The 
idea is to compile the scripts (D coding) to shared libraries 
and load the shared libraries into the main program.


Kind regards
André


in case your main application is written in D, too:  how do you 
avoid symbol name collisions?


I think it would be nice to load shared libraries while 
runtime, but i cant, because the symbol names of the imports 
get duplicated which is not allowed. And D intentionally has no 
namespace-feature for this


Yes, the main program is in D too. I haven't started prototyping 
yet, but as far as I know there are some limitations with D 
calling conventions. Therefore I plan to use Std calling 
convention instead.


Kind regards
André


Re: DMD license question

2017-08-08 Thread meppl via Digitalmars-d

...


okay, the actual problem is i create libraries multiple times. i 
think dub doesnt allow me to explicitly build the 
depency-libraries as shared libraries (to avoid the 
multiplication). then maybe an alternate build system would make 
it possible. however, i wont employ this for now.


Re: DMD license question

2017-08-08 Thread meppl via Digitalmars-d

On Monday, 7 August 2017 at 21:28:52 UTC, Andre Pany wrote:

Hi,

as DMD is now under Boost Software License, can I distribute it 
as part of my commercial product?


I want to provide script support within my application. The 
idea is to compile the scripts (D coding) to shared libraries 
and load the shared libraries into the main program.


Kind regards
André


in case your main application is written in D, too:  how do you 
avoid symbol name collisions?


I think it would be nice to load shared libraries while runtime, 
but i cant, because the symbol names of the imports get 
duplicated which is not allowed. And D intentionally has no 
namespace-feature for this


Re: DMD license question

2017-08-08 Thread Joakim via Digitalmars-d

On Tuesday, 8 August 2017 at 08:55:51 UTC, Jacob Carlborg wrote:

On 2017-08-07 23:56, Joakim wrote:

Yes, the idea of the Boost Software License is that you don't 
have to
ask such questions.  Boost allows you to do anything you want 
with the
source, whether embedding, modifying, etc. and you don't have 
to ask
anyone for permission or even mention that you're using 
someone else's

software to your users, as the BSD advertising clause requires.


That's not entirely true. The license and copyright notice need 
to be included somewhere if you're distributing the source 
code. If you're _only_ distributing machine code, the license 
or copyright need not to be included.


Right, that's what I got at with the second paragraph.  In his 
case, the dmd binary wouldn't require anything, and as long as he 
doesn't strip the copyright/licence notices from the included 
druntime/phobos source, he's fine.  His own D source, of course, 
would be under any license he chose.


Re: DMD license question

2017-08-08 Thread Jacob Carlborg via Digitalmars-d

On 2017-08-07 23:56, Joakim wrote:


Yes, the idea of the Boost Software License is that you don't have to
ask such questions.  Boost allows you to do anything you want with the
source, whether embedding, modifying, etc. and you don't have to ask
anyone for permission or even mention that you're using someone else's
software to your users, as the BSD advertising clause requires.


That's not entirely true. The license and copyright notice need to be 
included somewhere if you're distributing the source code. If you're 
_only_ distributing machine code, the license or copyright need not to 
be included.


--
/Jacob Carlborg


Re: DMD license question

2017-08-08 Thread Andre Pany via Digitalmars-d

On Monday, 7 August 2017 at 21:56:01 UTC, Joakim wrote:

On Monday, 7 August 2017 at 21:28:52 UTC, Andre Pany wrote:

[...]


Yes, the idea of the Boost Software License is that you don't 
have to ask such questions.  Boost allows you to do anything 
you want with the source, whether embedding, modifying, etc. 
and you don't have to ask anyone for permission or even mention 
that you're using someone else's software to your users, as the 
BSD advertising clause requires.


[...]


Thanks a lot for the information.

Kind regards
André


Re: DMD license question

2017-08-07 Thread Joakim via Digitalmars-d

On Monday, 7 August 2017 at 21:28:52 UTC, Andre Pany wrote:

Hi,

as DMD is now under Boost Software License, can I distribute it 
as part of my commercial product?


I want to provide script support within my application. The 
idea is to compile the scripts (D coding) to shared libraries 
and load the shared libraries into the main program.


Kind regards
André


Yes, the idea of the Boost Software License is that you don't 
have to ask such questions.  Boost allows you to do anything you 
want with the source, whether embedding, modifying, etc. and you 
don't have to ask anyone for permission or even mention that 
you're using someone else's software to your users, as the BSD 
advertising clause requires.


Boost gives you the freedom to do almost anything you want, with 
the only exception that you cannot claim the copyright to the 
source or binary as your own.  Given that you can use it almost 
any way you want, ie basically all rights under copyright have 
been given to you, there would be no point in claiming the 
copyright anyway, only a false claim that you wrote it too.


Re: DMD license question

2017-08-07 Thread Walter Bright via Digitalmars-d

On 8/7/2017 2:28 PM, Andre Pany wrote:
as DMD is now under Boost Software License, can I distribute it as part of my 
commercial product?


Yes.


DMD license question

2017-08-07 Thread Andre Pany via Digitalmars-d

Hi,

as DMD is now under Boost Software License, can I distribute it 
as part of my commercial product?


I want to provide script support within my application. The idea 
is to compile the scripts (D coding) to shared libraries and load 
the shared libraries into the main program.


Kind regards
André