Subject: 24.2.92; does not compile in 32-bit --with-wide-int on intel Mac OS X 10.6.8 (Snow Leopard)

From: Peter Dyballa <[email-masked]>
Date: Sun, 13 Jan 2013 16:14:30 +0100

Hello!

Configuring like this in 64-bit for the X11, Mac/AppKit, and NS variants leads to a working GNU Emacsen:

	In GNU Emacs 24.2.92.1 (x86_64-apple-darwin10.8.0, X toolkit, Xaw3d scroll bars)
	 of 2013-01-12 on Sumac.local
	Windowing system distributor `The X.Org Foundation', version 11.0.11300000
	Configured using:
	 `configure '--without-pop' '--without-sound' '--without-gpm'
	 '--without-dbus' '--without-selinux' '--with-x-toolkit=athena'
	 '--disable-ns-self-contained' '--without-imagemagick'
	 '--x-libraries=/opt/local/lib' '--x-includes=/opt/local/include'
	 '--enable-locallisppath=/Library/Application
	 Support/Emacs/calendar24:/Library/Application Support/Emacs'
	 'CFLAGS=-g3 -H -pipe -fPIC -fno-common -Os -m64 -march=core2
	 -mtune=core2 -fomit-frame-pointer -msse4.2'
	 'LDFLAGS=-Wl,-dead_strip_dylibs -Wl,-bind_at_load -Wl,-t -m64'
	 'CC=clang' 'CXX=clang++'
	 'PKG_CONFIG_PATH=/usr/lib/pkgconfig:/opt/local/lib/pkgconfig:/opt/local/share/pkgconfig''

but using an invocation à la

	env LANG=C PATH=/sw/bin:$PATH ./configure --build=x86_64-apple-darwin10.8.0 --host=i386-apple-darwin10.8.0 --target=i386-apple-darwin10.8.0 --without-pop --without-sound --without-gpm --without-dbus --without-selinux --with-wide-int --with-x-toolkit=athena --disable-ns-self-contained --without-imagemagick --x-libraries=/usr/X11/lib --x-includes=/usr/X11/include --enable-locallisppath=/Library/Application\ Support/Emacs/calendar24:/Library/Application\ Support/Emacs CFLAGS="-g3 -H -pipe -fPIC -fno-common -Os -march=core2 -mtune=core2 -m32 -fomit-frame-pointer -msse4.2" LDFLAGS="-m32 -Wl,-dead_strip_dylibs -Wl,-bind_at_load -Wl,-t -L/sw/lib" CPPFLAGS=-I/sw/include PKG_CONFIG_PATH=/sw/lib/xft2/lib/pkgconfig:/sw/share/pkgconfig:/sw/lib/pkgconfig:/usr/X11/lib/pkgconfig:/usr/X11/share/pkgconfig:/usr/lib/pkgconfig

leads during compilation to such an error:

	if test "no" = "yes"; then \
		  rm -f bootstrap-emacs; \
		  ln temacs bootstrap-emacs; \
		else \
		  `/bin/pwd`/temacs --batch --load loadup bootstrap || exit 1; \
		  test "X" = X ||  -zex emacs; \
		  mv -f emacs bootstrap-emacs; \
		fi
	/bin/sh: line 1: 75966 Bus error               (core dumped) `/bin/pwd`/temacs --batch --load loadup bootstrap
	make[1]: *** [bootstrap-emacs] Error 1
	make: *** [src] Error 2

Even if I reduce FLAGS and optimisation to a minimum. In /opt/local I have 64-bit packages from MacPorts installed, in /sw 32-bits packages from Fink, in the usual Mac OS X places they're "universal". During configuration reasonable differences were found:

	checking build system type... x86_64-apple-darwin10.8.0
	checking host system type... x86_64-apple-darwin10.8.0
	
	checking for bit size of ptrdiff_t... 64
	checking for bit size of size_t... 64
	checking for bit size of sig_atomic_t... 32
	checking for bit size of wchar_t... 32
	checking for bit size of wint_t... 32
	
	checking for ptrdiff_t integer literal suffix... l
	
	checking for ptrdiff_t integer literal suffix... 
	
	checking whether gettimeofday clobbers localtime buffer... no
	checking for gettimeofday with POSIX signature... yes
	checking for working mktime... no
	checking whether signature of pselect conforms to POSIX... yes
	checking whether pselect detects invalid fds... yes

vs.

	checking build system type... x86_64-apple-darwin10.8.0
	checking host system type... i386-apple-darwin10.8.0
	
	checking for bit size of ptrdiff_t... 32
	checking for bit size of size_t... 32
	checking for bit size of sig_atomic_t... 32
	checking for bit size of wchar_t... 32
	checking for bit size of wint_t... 32
	
	checking for ptrdiff_t integer literal suffix… 
	
	checking whether the utimes function works... no
	
	checking whether gettimeofday clobbers localtime buffer... guessing yes
	checking for gettimeofday with POSIX signature... yes
	checking sys/timeb.h usability... yes
	checking sys/timeb.h presence... yes
	checking for sys/timeb.h... yes
	checking for _ftime... no
	checking for working mktime... no
	checking whether signature of pselect conforms to POSIX... yes
	checking whether pselect detects invalid fds... guessing no

--
Greetings

  Pete       (:
        _    / __    -    -
      _/ \__/_/        -     -
     (´`)      (´`)   -    -
      `´        `´