* Re: libguile on Windows
@ 2005-10-10 23:43 Dylan Nicholson
0 siblings, 0 replies; 10+ messages in thread
From: Dylan Nicholson @ 2005-10-10 23:43 UTC (permalink / raw)
Cc: guile-user
>> Thank you so much. Now I get
>>
>> Backtrace:
>> In unknown file:
>> ?: 0* [for-each #<procedure set-system-module! (m s)> ...
>> ?: 1* (list the-root-module the-scm-module)
>>
>> <unnamed port>: In expression (list the-root-module the-scm-module):
>> <unnamed port>: Unbound variable: list
>>
>>
> Thought I knew what the problem was here, but no such luck...
>
> The line
> scm_c_define_gsubr (s_list, 0, 0, 1, (SCM (*)()) scm_list_copy);
>
> from list.x didn't compile at first, so I tried commenting it out, then
> adding
> static char s_list[]="list";
>
> to list.c (it was only in read.c)
>
> Still, seems like at least some progress!
>
I replaced the line listed above from list.x with
scm_c_define_gsubr (s_scm_list, 0, 0, 1, (SCM (*)()) scm_list);
And now the following C++ program runs and prints "Hello world":
#include <iostream>
#include "libguile.h"
#include "libguile\gh.h"
static void
main_with_guile (void *, int argc, char ** argv)
{
std::cout << "Hello ";
scm_c_eval_string("(display \"world!\n\")");
}
int main(int argc, char* argv[])
{
scm_boot_guile (argc, argv, main_with_guile, 0);
return 0;
}
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: libguile on Windows
@ 2005-10-10 23:23 Dylan Nicholson
2005-10-10 23:40 ` Neil Jerram
0 siblings, 1 reply; 10+ messages in thread
From: Dylan Nicholson @ 2005-10-10 23:23 UTC (permalink / raw)
Cc: guile-user
>>
>> .x files are attached. These are from the 1.6.x branch in CVS, so may
>> not match your codebase exactly, but any discrepancies should be
>> trivial to resolve - let me know if you need help with any such
>> problems.
>>
>> Neil
>>
> Thank you so much. Now I get
>
> Backtrace:
> In unknown file:
> ?: 0* [for-each #<procedure set-system-module! (m s)> ...
> ?: 1* (list the-root-module the-scm-module)
>
> <unnamed port>: In expression (list the-root-module the-scm-module):
> <unnamed port>: Unbound variable: list
>
>
Thought I knew what the problem was here, but no such luck...
The line
scm_c_define_gsubr (s_list, 0, 0, 1, (SCM (*)()) scm_list_copy);
from list.x didn't compile at first, so I tried commenting it out, then
adding
static char s_list[]="list";
to list.c (it was only in read.c)
Still, seems like at least some progress!
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: libguile on Windows
2005-10-10 23:23 Dylan Nicholson
@ 2005-10-10 23:40 ` Neil Jerram
[not found] ` <00e301c5cdf5$02aa3d40$6b01a8c0@DORIAN>
0 siblings, 1 reply; 10+ messages in thread
From: Neil Jerram @ 2005-10-10 23:40 UTC (permalink / raw)
Cc: guile-user
[-- Attachment #1: Type: text/plain, Size: 612 bytes --]
"Dylan Nicholson" <dylannic@bigpond.net.au> writes:
> Thought I knew what the problem was here, but no such luck...
>
> The line
> scm_c_define_gsubr (s_list, 0, 0, 1, (SCM (*)()) scm_list_copy);
>
> from list.x didn't compile at first, so I tried commenting it out,
> then adding
> static char s_list[]="list";
>
> to list.c (it was only in read.c)
>
> Still, seems like at least some progress!
Please try the attached instead. These ones are from my own Windows
(MSVC) build of Guile 1.6.4, so they will hopefully work. (And in
particular, the entry for "list" is a bit different!)
Regards,
Neil
[-- Attachment #2: x files 2 --]
[-- Type: application/octet-stream, Size: 12189 bytes --]
[-- Attachment #3: Type: text/plain, Size: 140 bytes --]
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: libguile on Windows
@ 2005-10-10 22:52 Dylan Nicholson
2005-10-10 23:09 ` Neil Jerram
0 siblings, 1 reply; 10+ messages in thread
From: Dylan Nicholson @ 2005-10-10 22:52 UTC (permalink / raw)
Cc: guile-user
Sorry for the top-post, but now I'm pretty sure I know what the problem is.
I wasn't sure how to create the .x files, so I simply created them all as
blank files!
Obviously this isn't right, so if anyone can send me the .x files, or simple
instructions on how to create them *without* any GNU tools, that would be
great.
----- Original Message -----
From: "Dylan Nicholson" <dylannic@bigpond.net.au>
To: "Neil Jerram" <neil@ossau.uklinux.net>
Cc: <guile-user@gnu.org>
Sent: Tuesday, October 11, 2005 8:38 AM
Subject: Re: libguile on Windows
>> ----- Original Message -----
>> From: "Neil Jerram" <neil@ossau.uklinux.net>
>>>
>>> Can you hack the code somehow so that the debug and backtrace options
>>> are set:
>>>
>>> SCM_DEVAL_P = 1;
>>> SCM_BACKTRACE_P = 1;
>>> SCM_RESET_DEBUG_MODE;
>>>
>>> (This would have to be after the init functions for debug.c.)
>>
>> I just get
>>
>> Backtrace:
>> In unknown file:
>> ?: 0*
>>
>> Then an access violation trying to access a null pointer in unmemocopy
>> (eval.c, line 1291). unmemocopy calls itself recursively using
>> SCM_CAR( ), and at some point SCM_CAR returns 0, which unmemocopy can't
>> handle.
>>
>> This happens no matter where I put the code (e.g. before callling
>> scm_boot_guile or just before scm_load_startup_files())
>>
> Ok, I added an extra test to unmemocopy (to test that the argument is
> null), and now I get
>
> Backtrace:
> In unknown file:
> ?: 0* (define begin-deprecated (procedure->memoizing-macro (lambda #
> #)))
>
> <unnamed port>: In expression (define begin-deprecated
> (procedure->memoizing-macro #)):
> <unnamed port>: Unbound variable: define
>
>
> Hope that means more to you than it does to me! I don't understand why I
> needed to
> change unmemocopy though.
>
>
>
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: libguile on Windows
2005-10-10 22:52 Dylan Nicholson
@ 2005-10-10 23:09 ` Neil Jerram
0 siblings, 0 replies; 10+ messages in thread
From: Neil Jerram @ 2005-10-10 23:09 UTC (permalink / raw)
Cc: guile-user
"Dylan Nicholson" <dylannic@bigpond.net.au> writes:
> Sorry for the top-post, but now I'm pretty sure I know what the problem is.
>
> I wasn't sure how to create the .x files, so I simply created them all
> as blank files!
> Obviously this isn't right, so if anyone can send me the .x files, or
> simple instructions on how to create them *without* any GNU tools,
> that would be great.
Yes, that'll be it. I'll send these to you off-list.
Neil
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: libguile on Windows
@ 2005-10-10 22:38 Dylan Nicholson
0 siblings, 0 replies; 10+ messages in thread
From: Dylan Nicholson @ 2005-10-10 22:38 UTC (permalink / raw)
Cc: guile-user
> ----- Original Message -----
> From: "Neil Jerram" <neil@ossau.uklinux.net>
>>
>> Can you hack the code somehow so that the debug and backtrace options
>> are set:
>>
>> SCM_DEVAL_P = 1;
>> SCM_BACKTRACE_P = 1;
>> SCM_RESET_DEBUG_MODE;
>>
>> (This would have to be after the init functions for debug.c.)
>
> I just get
>
> Backtrace:
> In unknown file:
> ?: 0*
>
> Then an access violation trying to access a null pointer in unmemocopy
> (eval.c, line 1291). unmemocopy calls itself recursively using
> SCM_CAR( ), and at some point SCM_CAR returns 0, which unmemocopy can't
> handle.
>
> This happens no matter where I put the code (e.g. before callling
> scm_boot_guile or just before scm_load_startup_files())
>
Ok, I added an extra test to unmemocopy (to test that the argument is null),
and now I get
Backtrace:
In unknown file:
?: 0* (define begin-deprecated (procedure->memoizing-macro (lambda # #)))
<unnamed port>: In expression (define begin-deprecated
(procedure->memoizing-macro #)):
<unnamed port>: Unbound variable: define
Hope that means more to you than it does to me! I don't understand why I
needed to
change unmemocopy though.
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 10+ messages in thread
[parent not found: <001f01c5ca06$9a957db0$6401a8c0@DORIAN>]
end of thread, other threads:[~2005-10-11 22:37 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-10 23:43 libguile on Windows Dylan Nicholson
-- strict thread matches above, loose matches on Subject: below --
2005-10-10 23:23 Dylan Nicholson
2005-10-10 23:40 ` Neil Jerram
[not found] ` <00e301c5cdf5$02aa3d40$6b01a8c0@DORIAN>
2005-10-11 22:37 ` Neil Jerram
2005-10-10 22:52 Dylan Nicholson
2005-10-10 23:09 ` Neil Jerram
2005-10-10 22:38 Dylan Nicholson
[not found] <001f01c5ca06$9a957db0$6401a8c0@DORIAN>
[not found] ` <87vf07afac.fsf@ossau.uklinux.net>
2005-10-09 21:53 ` Dylan Nicholson
2005-10-10 16:47 ` Neil Jerram
2005-10-10 22:19 ` Dylan Nicholson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).