Opened 10 years ago

Closed 10 years ago

#44545 closed enhancement (fixed)

arb: allow building on Snow Leopard

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: mattcottrell
Priority: Normal Milestone:
Component: ports Version: 2.3.1
Keywords: haspatch Cc: cooljeanius (Eric Gallager)
Port: arb

Description

Using my revised patch from #44367, the new failure on Snow Leopard is:

Compiler version check:
  - Your compiler is 'gcc' version '4.2.1'
    This version is not in the list of supported gcc-versions:
    * 4.3.1
    * 4.3.2
    * 4.3.3
    * 4.3.4
    * 4.4.1
    * 4.4.3
    * 4.4.5
    * 4.4.6
    * 4.4.7
    * 4.5.2
    * 4.6.1
    * 4.6.2
    * 4.6.3
    * 4.7.1
    * 4.7.2
    * 4.7.3
    * 4.8.0
    * 4.8.1
    * 4.8.2
    * 4.8.3
    * 4.9.0
  - You may either ..
    - add your version to ALLOWED_gcc_VERSIONS in the Makefile and try it out or
    - switch to one of the allowed versions (see arb_README_gcc.txt for installing
      a different version of gcc)

All tools needed for ARB compilation have been located.
SOURCE_TOOLS/generate_all_links.sh
make[2]: *** [check_GCC_VERSION] Error 1

After adding 4.2.1 to the Makefile's list of acceptable gcc versions, the next error I got was:

/Volumes/Data/macports/snowleopard/var/macports/build/_Volumes_Data_macports_dports_science_arb/arb/work/arbsrc_12565/INCLUDE/gccver.h:34:3: error: #error Wrong compiler version (need at least gcc 4.3 or clang 4.2)

Editing gccver.h to allow gcc 4.2, the next error was:

/Volumes/Data/macports/snowleopard/var/macports/build/_Volumes_Data_macports_dports_science_arb/arb/work/arbsrc_12565/INCLUDE/arbtools.h: In copy constructor 'BackTraceInfo::BackTraceInfo(const BackTraceInfo&)':
/Volumes/Data/macports/snowleopard/var/macports/build/_Volumes_Data_macports_dports_science_arb/arb/work/arbsrc_12565/INCLUDE/arbtools.h:36: error: 'Noncopyable::Noncopyable(const Noncopyable&)' is private
/Volumes/Data/macports/snowleopard/var/macports/build/_Volumes_Data_macports_dports_science_arb/arb/work/arbsrc_12565/INCLUDE/arb_backtrace.h:35: error: within this context
arb_msg.cxx: In function 'void GBK_dump_backtrace(FILE*, const char*)':
arb_msg.cxx:382: note: synthesized method 'BackTraceInfo::BackTraceInfo(const BackTraceInfo&)' first required here 
make[3]: *** [arb_msg.o] Error 1

This indeed sounds like it could be a deficiency in gcc 4.2, so we should instead blacklist old gcc versions, including llvm-gcc, which gave the same error. llvm-gcc is already blacklisted, so changing the blacklist to *gcc-4.0 *gcc-4.2 should cause it to fall back to clang instead.

The old clang 1.7 on Snow Leopard doesn't have a C++ compiler and falls back on llvm-g++-4.2 for that, which triggers arb's compiler version check again, so adding the compiler_blacklist_versions 1.0 portgroup and additionally blacklisting {clang < 138} takes care of that. And with that, it now builds on Snow Leopard. I haven't yet tested if it can also now build on Tiger and Leopard.

Attachments (1)

Portfile-arb-blacklist.diff (953 bytes) - added by ryandesign (Ryan Carsten Schmidt) 10 years ago.

Download all attachments as: .zip

Change History (3)

Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Attachment: Portfile-arb-blacklist.diff added

comment:1 Changed 10 years ago by cooljeanius (Eric Gallager)

Cc: egall@… added

Cc Me!

comment:2 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.