<p>When I built MLPACK by using GCC <code>4.9.2</code> on Mac OS X <code>10.10.3</code>, I encountered the following error:</p>
<pre><code>Undefined symbols for architecture x86_64:
"___emutls_v._ZN4arma23arma_rng_cxx11_instanceE", referenced from:
mlpack::distribution::GaussianDistribution::Random() const in gaussian_distribution.cpp.o
mlpack::tree::CosineTree::ColumnSampleLS() in cosine_tree.cpp.o
mlpack::tree::CosineTree::ColumnSamplesLS(std::vector<unsigned long, std::allocator<unsigned long> >&, arma::Col<double>&, unsigned long) in cosine_tree.cpp.o
arma::arma_rng::randn<double>::operator double() const [clone .isra.300] in radical.cpp.o
void arma::eglue_core<arma::eglue_plus>::apply<arma::Mat<double>, arma::Op<arma::Mat<double>, arma::op_repmat>, arma::eOp<arma::Gen<arma::Mat<double>, arma::gen_randn>, arma::eop_scalar_times> >(arma::Mat<double>&, arma::eGlue<arma::Op<arma::Mat<double>, arma::op_repmat>, arma::eOp<arma::Gen<arma::Mat<double>, arma::gen_randn>, arma::eop_scalar_times>, arma::eglue_plus> const&) in radical.cpp.o
mlpack::svd::RegularizedSVDFunction::RegularizedSVDFunction(arma::Mat<double> const&, unsigned long, double) in regularized_svd_function.cpp.o
mlpack::svd::RegularizedSVDFunction::RegularizedSVDFunction(arma::Mat<double> const&, unsigned long, double) in regularized_svd_function.cpp.o
...
ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
make[2]: *** [lib/libmlpack.1.0.dylib] Error 1
make[1]: *** [src/mlpack/CMakeFiles/mlpack.dir/all] Error 2
make: *** [all] Error 2
</code></pre>
<p>Clang did build MLPACK correctly.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br>Reply to this email directly or <a href="https://github.com/mlpack/mlpack/issues/432">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFMCrpa2faqjUIZOGv7SMNwN2UA8tks5oBjHEgaJpZM4EFGSE.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
<link itemprop="url" href="https://github.com/mlpack/mlpack/issues/432"></link>
<meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>