Git Product home page Git Product logo

Comments (9)

ivmai avatar ivmai commented on July 17, 2024

Hi,

How is it supposed to be fixed? We should include sys/ucontext.h on Darwin starting from some version and for the rest targets include ucontext.h, right? Which version? (And what macro should be tested?)

Regards

13 09 2011, 11:14 Jurriën Stutterheim [email protected]:

See http://stackoverflow.com/questions/6929826/building-libgc-fails-on-mac-os-x-10-6-snow-leopard-and-require-xopen-source for details. Fails on OS X 10.7 as well.

Reply to this email directly or view it on GitHub:
#4

from bdwgc.

norm2782 avatar norm2782 commented on July 17, 2024

I'm not really a C programmer, but I've seen a similar solution like this various times (borrowed from MacVim here):

#ifndef MAC_OS_X_VERSION_10_4
# define MAC_OS_X_VERSION_10_4 1040
#endif
#ifndef MAC_OS_X_VERSION_10_5
# define MAC_OS_X_VERSION_10_5 1050
#endif
#ifndef MAC_OS_X_VERSION_10_6
# define MAC_OS_X_VERSION_10_6 1060
#endif
#ifndef MAC_OS_X_VERSION_10_7
# define MAC_OS_X_VERSION_10_7 1070
#endif

#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6)
# include <sys/ucontext.h>
#else
# include <ucontext.h>
#endif

from bdwgc.

hboehm avatar hboehm commented on July 17, 2024

I think there's already an ongoing discussion of this on the gc mailing list. See http://news.gmane.org/gmane.comp.programming.garbage-collection.boehmgc. Let's discuss it there.

Hans

-----Original Message-----
From: Jurriën Stutterheim [mailto:reply+i-1630875-
[email protected]]
Sent: Tuesday, September 13, 2011 12:14 AM
To: Boehm, Hans
Subject: [bdwgc] Compilation fails on Mac OS X (#4)

�See http://stackoverflow.com/questions/6929826/building-libgc-fails-
on-mac-os-x-10-6-snow-leopard-and-require-xopen-source for details.
Fails on OS X 10.7 as well.

Reply to this email directly or view it on GitHub:
#4

from bdwgc.

ivmai avatar ivmai commented on July 17, 2024

Hi Jurriën,

Is MAC_OS_X_VERSION_MAX_ALLOWED defined in any of header files we include?
I see it is defined in Avaliability.h but this one is not included indirectly by gc_priv.h.

Regards.

13 09 2011, 18:28 Jurriën Stutterheim [email protected]:

I'm not really a C programmer, but I've seen a similar solution like this various times (borrowed from MacVim here):

#ifndef MAC_OS_X_VERSION_10_4

define MAC_OS_X_VERSION_10_4 1040

#endif
#ifndef MAC_OS_X_VERSION_10_5

define MAC_OS_X_VERSION_10_5 1050

#endif
#ifndef MAC_OS_X_VERSION_10_6

define MAC_OS_X_VERSION_10_6 1060

#endif
#ifndef MAC_OS_X_VERSION_10_7

define MAC_OS_X_VERSION_10_7 1070

#endif

#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6)

include <sys/ucontext.h>

#else

include <ucontext.h>

#endif

Reply to this email directly or view it on GitHub:
#4 (comment)

from bdwgc.

norm2782 avatar norm2782 commented on July 17, 2024

I'm not quite sure to be honest. From what I gather from [1], it's set implicitly by the build system. I'm not sure whether this holds true for a commandline compilation as well as for an Xcode compilation.

[1] http://lists.apple.com/archives/Xcode-users/2005/Aug/msg00399.html

from bdwgc.

ivmai avatar ivmai commented on July 17, 2024

Hi,

I've fixed this in master branch - please test it ("autoreconf -vif; ./configure; make check").
If it's ok I'll cherry-pick the commit (333f2e) to release branch (and close the issue).

Info: this patch affects only DARWIN.

Regards.

15 09 2011, 19:16 Jurriën Stutterheim [email protected]:

I'm not quite sure to be honest. From what I gather from [1], it's set implicitly by the build system. I'm not sure whether this holds true for a commandline compilation as well as for an Xcode compilation.

[1] http://lists.apple.com/archives/Xcode-users/2005/Aug/msg00399.html

Reply to this email directly or view it on GitHub:
#4 (comment)

from bdwgc.

norm2782 avatar norm2782 commented on July 17, 2024

I've been trying to compile the latest version, but I've been getting errors in the configuring process:

configure.ac:507: the top level
configure.ac:99: error: possibly undefined macro: AC_MSG_ERROR
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure.ac:738: error: possibly undefined macro: AS_IF
autoreconf: /usr/local/bin/autoconf failed with exit status: 1

λ bdwgc → λ git master → autoreconf --version
autoreconf (GNU Autoconf) 2.68

from bdwgc.

ivmai avatar ivmai commented on July 17, 2024

Hi Jurrien,

This is a known problem (see end of TODO file). For now, you can run autoreconf successfully on Linux.

Petter -
Could you look at this problem (not really urgent as works at least on Linux)? (could this be a bug in the script?)

Regards.

19 09 2011, 11:37 Jurriën Stutterheim [email protected]:

I've been trying to compile the latest version, but I've been getting errors in the configuring process:

configure.ac:507: the top level
configure.ac:99: error: possibly undefined macro: AC_MSG_ERROR
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure.ac:738: error: possibly undefined macro: AS_IF
autoreconf: /usr/local/bin/autoconf failed with exit status: 1

λ bdwgc → λ git master → autoreconf --version
autoreconf (GNU Autoconf) 2.68

Reply to this email directly or view it on GitHub:
#4 (comment)

from bdwgc.

ivmai avatar ivmai commented on July 17, 2024

Hi Petter,

I have autoconf-2.68 (automake 1.11.1) on cygwin:
/usr/share/autoconf/m4sugar/m4sh.m4:

_AS_BOURNE_COMPATIBLE

---------------------

This is the part of AS_BOURNE_COMPATIBLE which has to be repeated inside

each instance.

m4_define([_AS_BOURNE_COMPATIBLE],
[AS_IF([test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1],
[emulate sh
NULLCMD=:
[#] Pre-4.2 versions of Zsh do word splitting on ${1+"$[@]"}, which

is contrary to our usage. Disable this feature.

alias -g '${1+"$[@]"}'='"$[@]"'
setopt NO_GLOB_SUBST],
[AS_CASE([(set -o) 2>/dev/null], [posix], [set -o posix])])
])

PS. If you think this is caused by a malfunctioning autotools then we don't need to workaround it (as we still distribute auto-generated files in the tarball).

Regards.

19 09 2011, 20:58 Petter Urkedal [email protected]:

On 2011-09-19, Ivan Maidanski wrote:

Hi Jurrien,

This is a known problem (see end of TODO file). For now, you can run autoreconf successfully on Linux.

Petter -
Could you look at this problem (not really urgent as works at least on Linux)? (could this be a bug in the script?)

The AS_IF macro should be defined in
${datadir}/autoconf/m4suger/m4sh.m4
It is part of the Autoconf package, so it should not depend on OS. It's
a portability thing, so it would be ironic except for the fact that
the portability is optimised for distributions, where autogenerated
files are included. If we can't fix it, I can replace the macros with
plain "if" statements, since we're already using plenty of them.
However, it would be good to understand why aclocal does not find the
macro.

19 09 2011, 11:37 Jurriën Stutterheim [email protected]:

I've been trying to compile the latest version, but I've been getting errors in the configuring process:

configure.ac:507: the top level
configure.ac:99: error: possibly undefined macro: AC_MSG_ERROR
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure.ac:738: error: possibly undefined macro: AS_IF
autoreconf: /usr/local/bin/autoconf failed with exit status: 1

λ bdwgc → λ git master → autoreconf --version
autoreconf (GNU Autoconf) 2.68

Is your autoconf/aclocal also 2.68? This version is the same as mine,
so I think something else must be wrong. Can you locate m4sh.m4 and
verify that it defines AS_IF? Is is located in a path seen by aclocal?
In my case it's located at /usr/share/autoconf/m4sugar/m4sh.m4. On OS
X, it's probably elsewhere, but I guess it should be under the same
prefix as the aclocal command.

from bdwgc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.