unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Peter TB Brett <peter@peter-b.co.uk>
To: 22406@debbugs.gnu.org
Subject: bug#22406: Cannot compile for Windows x64 due to LLP64 model
Date: Tue, 19 Jan 2016 13:50:17 +0000	[thread overview]
Message-ID: <569E3F19.9000502@peter-b.co.uk> (raw)

It is not currently possible to compile Guile 2.0.11 for Windows x64 (in 
particular 64-bit Windows running on the x86-64 arch).

Most operating systems' C libraries for x86-64 use an "LP64" model, 
where sizeof(long int) == sizeof(void *) == 8.

However, for backwards-compatibility reasons, Windows uses an "LLP64" 
model, where sizeof(long long int) == sizeof(void *) == 8 and 
sizeof(long int) == 4.

Guile 2.0.11 can't cope with this; the libguile build fails due to this 
code:

 > static SCM
 > scm_i_inum2big (scm_t_inum x)
 > {
 >   /* Return a newly created bignum initialized to X. */
 >   SCM z = make_bignum ();
 > #if SIZEOF_VOID_P == SIZEOF_LONG
 >   mpz_init_set_si (SCM_I_BIG_MPZ (z), x);
 > #else
 >   /* Note that in this case, you'll also have to check all mpz_*_ui and
 >      mpz_*_si invocations in Guile. */
 > #error creation of mpz not implemented for this inum size
 > #endif
 >   return z;
 > }

http://git.savannah.gnu.org/cgit/guile.git/tree/libguile/numbers.c?id=v2.0.11#n272

Some work appears to be required before using 64-bit Guile on Windows 
x64 is possible.


-- 
Dr Peter Brett <peter@peter-b.co.uk>





             reply	other threads:[~2016-01-19 13:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-19 13:50 Peter TB Brett [this message]
2016-01-26 16:02 ` bug#22406: Cannot compile for Windows x64 due to LLP64 model Mark H Weaver
2016-01-26 17:38   ` Mark H Weaver
2016-06-20 20:01 ` Mark H Weaver

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=569E3F19.9000502@peter-b.co.uk \
    --to=peter@peter-b.co.uk \
    --cc=22406@debbugs.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).