kingsfordgroup/sailfish

Sailfish 0.7.0 build errors under OSX

Closed this issue · 7 comments

roryk commented

Hi everyone,

I get some errors trying to compile from source under OSX:

/Users/rory/tmp/sailfish-0.7.0/external/install/include/rapmap/SASearcher.hpp:604:26: error: non-constant-expression cannot be narrowed from type 'int' to 'uint32_t'
      (aka 'unsigned int') in initializer list [-Wc++11-narrowing]
            uint32_t len{startAt};
In file included from /Users/rory/tmp/sailfish-0.7.0/src/SailfishQuantify.cpp:30:
In file included from /Users/rory/tmp/sailfish-0.7.0/include/CollapsedEMOptimizer.hpp:9:
In file included from /Users/rory/tmp/sailfish-0.7.0/include/ReadExperiment.hpp:11:
/Users/rory/tmp/sailfish-0.7.0/include/EquivalenceClassBuilder.hpp:100:23: error: no matching member function for call to 'upsert'
            countMap_.upsert(g, upfn, v);
            ~~~~~~~~~~^~~~~~

Best,

Rory

rob-p commented

I haven't tested the new build on OSX yet, but I'll take a look into this ASAP. Can you tell me what OSX version and compiler you're using? I personally only have access to OSX 10.10.x machines with a recent version of Apple's Clang.

--Rob

roryk commented

Thanks Rob:

Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
Target: x86_64-apple-darwin14.5.0
Thread model: posix

On OSX 10.10.5.

FWIW if I use g/g++ 5:

/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp: At global scope:
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:81:19: error: 'SpinLock' does not name a type
 using SpinLockT = SpinLock;
                   ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp: In function 'int rapMapSAMap(int, char**)':
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:413:2: error: 'SpinLockT' was not declared in this scope
  SpinLockT iomutex;
  ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:443:70: error: the value of 'SpinLockT' is not usable in a constant expression
                 threads.emplace_back(processReadsPairSA<SACollector, SpinLockT>,
                                                                      ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:413:2: note: 'SpinLockT' was not declared 'constexpr'
  SpinLockT iomutex;
  ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:447:26: error: 'iomutex' was not declared in this scope
                         &iomutex,
                          ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:471:72: error: the value of 'SpinLockT' is not usable in a constant expression
                 threads.emplace_back(processReadsSingleSA<SACollector, SpinLockT>,
                                                                        ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:413:2: note: 'SpinLockT' was not declared 'constexpr'
  SpinLockT iomutex;
  ^
/Users/rory/tmp/sailfish-0.7.0/external/install/src/rapmap/RapMapSAMapper.cpp:475:26: error: 'iomutex' was not declared in this scope
                         &iomutex,
rob-p commented

Hi Rory,

Could you pull the latest version and see if that fixes the build issues for you. There were some issues with Clang's increased strictness that have been resolved. It builds and runs properly now on my mac.

--Rob

roryk commented

Hi Rob,

Thanks, that did the trick.

rob-p commented

Great! Let me know how the new version works for you. We're seeing substantial improvements.

roryk commented

Thanks Rob, will do. Does rolling in the RapMap pseudoalignment mean RapMap isn't going to exist as its own thing?

rob-p commented

Nope --- RapMap will continue to exist as its own tool. The results being used here aren't pseudo-alignments, but rather are quasi-mappings (I apologize for the crazy terminology overload --- the name was picked to distinguish the method from both the "lightweight alignment" method currently used in Salmon and the pseudo-alignment method used in Kallisto). The ability to do quasi-mapping is of independent interest outside of quantification and we have a few other places in mind. The goal will be for RapMap to continue to exist as a stand-alone tool, as well as to grow a formal API so that quasi-mappings can easily be computed and used in other contexts by e.g. using RapMap as a library. However, the goal will be to do this by developing RapMap as its own module and simply using it as a library in the projects where it's relevant.