|
Posted by Jerry Stuckle on 07/21/07 02:56
Henk verhoeven wrote:
> NC wrote:
>> On Jul 20, 5:30 am, Martin Larsen <martin+spamfree+lar...@bigfoot.com>
>> wrote:
> (..)
>>
>> With PHP, the PHP interpreter is the functional analog of the word
>> processor (it is a program that processes user-submitted data); PHP
>> scripts, functionally, are documents (user-submitted data); an include/
>> require is akin to an instruction to include a subdocument into the
>> main document.
>>
>>> Anyway, in your opinion, does the mechanism rememble dynamic
>>> or static linking most?
>>
>> Neither. Static linking and dynamic linking are terms applicable only
>> to compiled languages; in case of an interpreted language, they are
>> only meaningful when applied to the interpreter, not to scripts it
>> parses.
> >
> Hi,
>
> This may be true from a strict technical definition, but juridical
> reasoning may not be that strict. It is unlikely that the php
> interpreter will parse each line of code every time it interprets it.
> Most interpreters use some kind of intermediate code. As not everything
> is included at once, there will be a program in intermediate code being
> executed when a require_once occurs. Then the required code is parsed
> (maybe partially, but that is irrelevant) and the resulting intermediate
> code may be executed. If the included file holds functions the functions
> must be added to some sort of function lookup table so that the
> interpreter can find them and jump into them quickly whan a call is
> made. From a juridical point of view this adding to the lookup table can
> easily be seen as linking.
>
Actually, it does. Unless you have implemented a PHP optimizer, every
PHP file is interpreted every time you load the file. There is no
intermediate code.
> Furtermore i believe te Free Software Foundation does not define
> 'linking' in strict compiler-linker terms. There is no problem if the
> interpreter is GPL: for the interpreter the interpreted program is then
> seen as data. But if your program is making calls to functions in a
> GPL-ed library...
>
Perhaps the FSF doesn't define "linking". But it has had a standard
definition which has remained unchanged since I started programming -
around 40 years ago. The FSF is not the last word in definitions!
> "A consequence is that if you choose to use GPL'd Perl modules or Java
> classes in your program, you must release the program in a
> GPL-compatible way, regardless of the license used in the Perl or Java
> interpreter that the combined Perl or Java program will run on." See
> http://www.gnu.org/licenses/gpl-faq.html#IfInterpreterIsGPL
>
> (The terms "use" and "release" may also not be what you think. Here it
> becomes really tricky, i rather avoid making comments on that)
>
Which has absolutely nothing to do with whether something is statically
or dynamically linked.
> BTW, running a program that is using a GPL-ed library on your own public
> website might have consequences with the new version of GPL (gpl3), see
> http://www.gnu.org/licenses/gpl-faq.html#UnreleasedMods
>
Again, nothing to do with the current discussion.
> Does anybody know if that 'wording' made it to the final release?
>
> Greetings,
>
> Henk Verhoeven,
> www.phpPeanuts.org.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
[Back to original message]
|