#33 Bus Error on Mac OSX

Dave C

I have tried to compile nget on OSX using apple's
recommended -fast -mcpu=7450 CFLAGS. But nget will
crash with a "bus error" when ever it is run with a
command line arguement.
here is a gdb backtrace.

(gdb) bt
#0 0x000829bc in std::locale::operator=(std::locale
const&) () at par1repairer.h:68
#1 0x00083b44 in std::ios_base::_M_init() () at
#2 0x000845b0 in std::basic_ios<char,
std::char_traits<char> >*) () at par1repairer.h:68
#3 0x000bea1c in void parsestr<unsigned
long>(std::string const&, unsigned long&)
(val=@0x19013cc, dest=@0xbffff690) at
#4 0x000bd44c in void parsestr<unsigned
long>(std::string const&, unsigned long&, unsigned
long, unsigned long) (val=@0xbffff584,
dest=@0xbffff440, min=1, max=4294967295) at
#5 0x000bc60c in bool CfgItem::get<unsigned
long>(unsigned long&, unsigned long, unsigned long)
const (this=0x19013c0, dest=@0xbffff390, min=216,
max=1119764) at
#6 0x00037380 in c_nget_config::setlist(CfgSection
const*, CfgSection const*, CfgSection const*,
CfgSection const*) (this=0x19013c0, cfg=0x19012f0,
hinfo=0x100000, pinfo=0x100000, ginfo=0x19013cc) at
#7 0x00005518 in main (argc=26219468, argv=0xbffff690)
at /usr/include/gcc/darwin/3.3-fast/c++/bits/stl_map.h:1050


  • Matthew Mueller

    Matthew Mueller - 2005-01-23

    Logged In: YES

    Hello. I did a bit of googling to learn about these mac
    options, and found this:


    "The -malign-natural option incorporated in -fast results
    in non-ABI-conforming code, which can cause problems when
    mixing code compiled with and without -fast. In particular,
    some of the functions in the C++ I/O libraries do not
    currently work properly on MacOSX 10.3 when linked with code
    compiled -fast. Use -fastf (below) for C++ on MacOSX 10.3."

    So you may want to try with -fastf instead of -fast.

  • Dave C

    Dave C - 2005-01-24

    Logged In: YES

    guess what -fastf did the trick..Thank you.
    I had looked at that page several time when trying to get
    stuff to work on OSX but never that far down the page. Well
    thanks again; nget is now working in fully optimized form.

  • Matthew Mueller

    Matthew Mueller - 2005-01-24

    Logged In: YES

    You're welcome.

  • Matthew Mueller

    Matthew Mueller - 2005-01-24
    • status: open --> closed-invalid

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks