From: Jan Schukat <shookie@email.de>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 13848@debbugs.gnu.org
Subject: bug#13848: Statically linking guile-2.0.
Date: Tue, 05 Mar 2013 01:54:12 +0100 [thread overview]
Message-ID: <51354234.4000208@email.de> (raw)
In-Reply-To: <87vc994y8f.fsf@gnu.org>
[-- Attachment #1: Type: text/plain, Size: 6127 bytes --]
Ok, I did some more work on the linux and mingw side. My little test
project now compiles and works under linux, provided in gc.c I remove
the static qualifiers from GC_set_finalize_on_demand,
GC_get_heap_usage_safe, GC_get_free_space_divisor and
GC_set_finalizer_notifier. That still gave a warning at linking time,
but any combination of preprocessor guards caused either compile errors
or link errors.
Also, when building guile-2.9 with --disable-posix, there comes a
lisp-compile error when the standard modules are made:
GUILEC ice-9/popen.go
Backtrace:
In ice-9/eval.scm:
376: 19 [eval # #]
In srfi/srfi-1.scm:
619: 18 [for-each #<procedure a389618 at ice-9/eval.scm:405:20 (a)> #]
In ice-9/eval.scm:
376: 17 [eval # #]
470: 16 [lp (#<fluid 23>) ("")]
In system/base/target.scm:
59: 15 [with-target "i686-pc-linux-gnu" ...]
In system/base/compile.scm:
147: 14 [compile-file "ice-9/popen.scm" #:output-file ...]
43: 13 [call-once #<procedure a434b40 at system/base/compile.scm:56:5
()>]
In ice-9/boot-9.scm:
171: 12 [with-throw-handler #t ...]
In system/base/compile.scm:
59: 11 [#<procedure a434b20 at system/base/compile.scm:58:9 ()>]
150: 10 [#<procedure a434b60 at system/base/compile.scm:148:8 (port)>
#<input-output: ice-9/popen.go.HBtyxJ 6>]
199: 9 [read-and-compile #<input: ice-9/popen.scm 5> #:from ...]
211: 8 [lp (#<tree-il (let # # ...)>) #<directory (ice-9 popen)
a4f2a68> ...]
177: 7 [lp (#<procedure compile-tree-il (x e opts)>) (eval-when # #) ...]
In ice-9/boot-9.scm:
2131: 6 [save-module-excursion #<procedure a50b9f0 at
language/scheme/compile-tree-il.scm:29:3 ()>]
In language/scheme/compile-tree-il.scm:
31: 5 [#<procedure a50b9f0 at
language/scheme/compile-tree-il.scm:29:3 ()>]
In ice-9/psyntax.scm:
1091: 4 [expand-top-sequence ((eval-when # #)) () ((top)) ...]
976: 3 [scan ((eval-when # #)) () ((top)) ...]
270: 2 [scan ((load-extension # "scm_init_popen")) () ((top)) ...]
In unknown file:
?: 1 [load-extension "libguile-2.0" "scm_init_popen"]
In ice-9/boot-9.scm:
106: 0 [#<procedure a434b00 at ice-9/boot-9.scm:97:6 (thrown-k .
args)> misc-error ...]
ice-9/boot-9.scm:106:20: In procedure #<procedure a434b00 at
ice-9/boot-9.scm:97:6 (thrown-k . args)>:
ice-9/boot-9.scm:106:20: In procedure dynamic-pointer: Symbol not found:
scm_init_popen
make[3]: *** [ice-9/popen.go] Error 1
make[3]: Leaving directory `/home/shookie/guiletest/lib/guile-2.0/module'
make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory `/home/shookie/guiletest/lib/guile-2.0'
make[1]: *** [install] Error 2
make[1]: Leaving directory `/home/shookie/guiletest/lib/guile-2.0'
make: *** [lib/lib/libguile-2.0.a] Error 2
When I leave out that option it (the test project) builds and runs fine
on linux now though.
On mingw, I still have to define the struct timespec:
diff --recursive guile-2.0/lib/stat-time.h guile-2.0.7/lib/stat-time.h
26,32d25
< #ifndef _TIMESPEC_DEFINED
< struct timespec {
< time_t tv_sec;
< long tv_nsec;
< };
< #endif
<
diff --recursive guile-2.0/libguile/random.c guile-2.0.7/libguile/random.c
668c668
< scm_from_ulong(getpid()), /* process ID */
---
> scm_getpid (), /* process ID */
diff --recursive guile-2.0/libguile/threads.c guile-2.0.7/libguile/threads.c
70,75d69
< #ifndef _TIMESPEC_DEFINED
< struct timespec {
< time_t tv_sec;
< long tv_nsec;
< };
< #endif
With that it builds.
When I run it with --program-suffix=.exe it also copies guild.exe
(without it fails while trying), but then fails when it tries to run it
without the suffix.
So I run it again without the --program-suffix, and since the files are
copied in the previous build it starts them, but then they fail like this:
but then fails installing the lisp modules:
GEN guile-procedures.texi
Throw without catch before boot:
Throw to key system-error with args ("canonicalize-path" "~A" ("No such
file or directory") (2))Aborting.
This application has requested the Runtime to terminate it in an unusual
way.
Please contact the application's support team for more information.
make[4]: *** [guile-procedures.texi] Error 1
make[4]: Leaving directory
`/c/Users/shookie/guiletest/lib/guile-2.0/libguile'
make[3]: *** [install] Error 2
make[3]: Leaving directory
`/c/Users/shookie/guiletest/lib/guile-2.0/libguile'
make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory `/c/Users/shookie/guiletest/lib/guile-2.0'
make[1]: *** [install] Error 2
make[1]: Leaving directory `/c/Users/shookie/guiletest/lib/guile-2.0'
make: *** [lib/lib/libguile-2.0.a] Error 2
I attached the new updated test-project tgz.
In summary, I still think on mingw the configure script gets very
confused about paths and file names.
Regards
Jan Schukat
On 03/02/2013 04:28 PM, Ludovic Courtès wrote:
> Hello,
>
> Thanks for the report.
>
> Jan Schukat<shookie@email.de> skribis:
>
>> But then on install (processing .texi files) guile.exe fails with this
>> message:
>>
>> "Throw without catch before boot:
>> Throw to key system-error with args ("canonicalize-path" "~A" ("No
>> such file or directory") (2))Aborting.
> [...]
>
>> Calling guile.exe directly gives this message:
>>
>> "Throw without catch before boot:
>> Throw to key misc-error with args ("primitive-load-path" "Unable to
>> find file ~S in load path" ("ice-9/boot-9") #f)Aborting.
> Does it happen when running the installed Guile? That is, you
> successfully run ‘make’ and ‘make install’ (and ideally ‘make check’),
> and it’s the installed ‘guile’ binary that produces this message?
>
> As most Unix and GNU packages, Guile expects to be installed in the
> place specified by --prefix. If you install it elsewhere, it will fail
> to find its companion files, such as ice-9/boot-9.scm. So you really
> must install it in --prefix, and leave it there. Is it what you did?
>
> (Note that this restriction can be worked around by techniques such as
> found in
> <http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/patches/guile-relocatable.patch>.)
>
> Thanks,
> Ludo’.
[-- Attachment #2: guiletest.tgz --]
[-- Type: application/x-compressed-tar, Size: 2980 bytes --]
next prev parent reply other threads:[~2013-03-05 0:54 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-01 16:19 bug#13848: Statically linking guile-2.0 Jan Schukat
2013-03-02 15:28 ` Ludovic Courtès
2013-03-03 23:20 ` Jan Schukat
2013-03-05 0:54 ` Jan Schukat [this message]
2013-03-05 10:22 ` Ludovic Courtès
2013-03-05 15:44 ` Jan Schukat
2013-03-05 17:25 ` Ludovic Courtès
2013-03-05 22:25 ` Jan Schukat
2013-03-06 23:12 ` Ludovic Courtès
2013-03-09 13:44 ` Jan Schukat
2013-03-09 23:06 ` Andy Wingo
2013-03-09 23:57 ` shookie
2013-03-10 4:09 ` shookie
2013-03-10 17:32 ` Andy Wingo
2013-03-10 18:54 ` shookie
2013-03-10 19:23 ` Andy Wingo
2013-03-10 21:17 ` shookie
2013-03-10 22:03 ` shookie
2013-03-10 22:53 ` Andy Wingo
2013-03-11 0:07 ` shookie
2013-03-11 1:43 ` shookie
2013-03-11 8:26 ` Andy Wingo
2013-03-11 9:30 ` shookie
2013-03-13 9:30 ` Andy Wingo
2013-03-13 19:04 ` bug#13848: Aw: " Jan Schukat
2013-03-16 1:36 ` Jan Schukat
2013-03-29 19:35 ` Ludovic Courtès
2013-03-30 0:20 ` Jan Schukat
2013-03-30 21:27 ` Ludovic Courtès
2013-04-05 23:14 ` Jan Schukat
2013-04-07 10:20 ` Ludovic Courtès
2013-04-07 16:20 ` bug#13848: Aw: " Jan Schukat
2013-04-07 18:22 ` Andy Wingo
2013-04-07 19:18 ` bug#13848: Aw: " Jan Schukat
2013-04-07 20:00 ` Ludovic Courtès
2013-04-07 21:06 ` bug#13848: Aw: " Jan Schukat
2013-04-08 7:48 ` Ludovic Courtès
2013-03-10 17:38 ` shookie
2013-03-10 17:38 ` shookie
2013-03-14 13:54 ` Ludovic Courtès
2013-03-09 9:32 ` Andy Wingo
2013-03-09 15:42 ` Jan Schukat
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51354234.4000208@email.de \
--to=shookie@email.de \
--cc=13848@debbugs.gnu.org \
--cc=ludo@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).