Thank you for the quick resonpse @jdtournier. I really appreciate the help. Unseting the LD enviroment variable helped me get pass the C++11 compliance issue.
Unfortuantelly, I am now stuck trying to find the zlib library. I did make sure to double check that the zlib1g-dev library was isntalled but I am still getting the following error:
MRtrix build type requested: release version
WARNING: Anaconda removed from PATH to avoid conflicts
Detecting OS: linux
Machine architecture set by ARCH environment variable to: native
Looking for compiler [/home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++]: x86_64-conda_cos6-linux-gnu-c++ (crosstool-NG 1.23.0.449-a04d0) 7.3.0
Checking for C++11 compliance: ok
Checking shared library generation: ok
Detecting pointer size: 64 bit
Detecting byte order: little-endian
Checking for variable-length array support: ok
Checking for non-POD variable-length array support: ok
Checking for ::max_align_t: 16 bytes
Checking for std::max_align_t: 16 bytes
Checking for Eigen3 library: 3.3.4
Checking for zlib compression library:
ERROR: error compiling zlib application!
MRtrix3 was unable to compile a test program involving zlib.
Set the ZLIB_CFLAGS environment variable to inform 'configure' of
the flags it must provide to the compiler in order to compile
programs that use zlib functionality; this may include the path to
the zlib include files, as well as any required flags.
For example:
$ export ZLIB_CFLAGS="-isystem /usr/local/include"
$./configure
(amend with the actual path to the zlib include files on your system)
with this configure.log:
REPORT:
MRtrix build type requested: release version
REPORT: WARNING: Anaconda removed from PATH to avoid conflicts
REPORT: Detecting OS: linux
REPORT: Machine architecture set by ARCH environment variable to: native
REPORT: Looking for compiler [/home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++]:
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ --version
EXIT: 0
STDOUT:
x86_64-conda_cos6-linux-gnu-c++ (crosstool-NG 1.23.0.449-a04d0) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
>>
REPORT: x86_64-conda_cos6-linux-gnu-c++ (crosstool-NG 1.23.0.449-a04d0) 7.3.0
REPORT: Checking for C++11 compliance:
COMPILE /tmp/tmp19z3189i.cpp:
---
#include <cstddef>
struct Base {
Base (int);
};
struct Derived : Base {
using Base::Base;
};
int main() {
Derived D (int); // check for contructor inheritance
return 0;
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe /tmp/tmp19z3189i.cpp -o /tmp/tmp19z3189i.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmp19z3189i.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
>>
REPORT: ok
REPORT: Checking shared library generation:
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe /tmp/tmpi6h83ncu.cpp -o /tmp/tmpi6h83ncu.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmpi6h83ncu.o -shared -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o libtest.so
EXIT: 0
>>
REPORT: ok
REPORT: Detecting pointer size:
COMPILE /tmp/tmpoyjrj8ax.cpp:
---
#include <iostream>
int main() {
std::cout << sizeof(void*);
return (0);
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe /tmp/tmpoyjrj8ax.cpp -o /tmp/tmpoyjrj8ax.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmpoyjrj8ax.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
STDOUT:
8
>>
REPORT: 64 bit
REPORT: Detecting byte order:
REPORT: little-endian
REPORT: Checking for variable-length array support:
COMPILE /tmp/tmp561xla2r.cpp:
---
int main(int argc, char* argv[]) {
int x[argc];
return 0;
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe -DMRTRIX_WORD64 /tmp/tmp561xla2r.cpp -o /tmp/tmp561xla2r.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmp561xla2r.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
>>
REPORT: ok
REPORT: Checking for non-POD variable-length array support:
COMPILE /tmp/tmpo_im6a_3.cpp:
---
#include <string>
class X {
int x;
double y;
std::string s;
};
int main(int argc, char* argv[]) {
X x[argc];
return 0;
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe -DMRTRIX_WORD64 /tmp/tmpo_im6a_3.cpp -o /tmp/tmpo_im6a_3.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmpo_im6a_3.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
>>
REPORT: ok
REPORT: Checking for ::max_align_t:
COMPILE /tmp/tmps2dq795y.cpp:
---
#include <iostream>
#include <cstddef>
using ::max_align_t;
int main() {
std::cout << alignof (max_align_t) << " bytes\n";
return 0;
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe -DMRTRIX_WORD64 /tmp/tmps2dq795y.cpp -o /tmp/tmps2dq795y.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmps2dq795y.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
STDOUT:
16 bytes
>>
REPORT: 16 bytes
REPORT: Checking for std::max_align_t:
COMPILE /tmp/tmp9yfypw6s.cpp:
---
#include <iostream>
#include <cstddef>
using std::max_align_t;
int main() {
std::cout << alignof (max_align_t) << " bytes\n";
return 0;
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe -DMRTRIX_WORD64 /tmp/tmp9yfypw6s.cpp -o /tmp/tmp9yfypw6s.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmp9yfypw6s.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
STDOUT:
16 bytes
>>
REPORT: 16 bytes
EXEC <<
CMD: pkg-config --cflags eigen3
EXIT: 0
STDOUT:
-I/usr/include/eigen3
>>
REPORT: Checking for Eigen3 library:
COMPILE /tmp/tmp3u5d9wa5.cpp:
---
#include <cstddef>
#include <Eigen/Core>
#include <iostream>
int main (int argc, char* argv[]) {
std::cout << EIGEN_WORLD_VERSION << "." << EIGEN_MAJOR_VERSION << "." << EIGEN_MINOR_VERSION << "\n";
return 0;
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe -DMRTRIX_WORD64 -isystem /usr/include/eigen3 /tmp/tmp3u5d9wa5.cpp -o /tmp/tmp3u5d9wa5.o
EXIT: 0
>>
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ /tmp/tmp3u5d9wa5.o -Wl,--sort-common,--as-needed -pthread -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -o a.out
EXIT: 0
>>
EXEC <<
CMD: ./a.out
EXIT: 0
STDOUT:
3.3.4
>>
REPORT: 3.3.4
EXEC <<
CMD: pkg-config --cflags zlib
EXIT: 0
>>
EXEC <<
CMD: pkg-config --libs zlib
EXIT: 0
STDOUT:
-lz
>>
REPORT: Checking for zlib compression library:
COMPILE /tmp/tmpfoco_h35.cpp:
---
#include <iostream>
#include <zlib.h>
int main() {
std::cout << zlibVersion();
return (0);
}
---
EXEC <<
CMD: /home/lralvarado/anaconda3/bin/x86_64-conda_cos6-linux-gnu-c++ -c -std=c++11 -DMRTRIX_BUILD_TYPE="release version" -pthread -fPIC -march=native -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe -DMRTRIX_WORD64 /tmp/tmpfoco_h35.cpp -o /tmp/tmpfoco_h35.o
EXIT: 1
STDERR:
/tmp/tmpfoco_h35.cpp:3:10: fatal error: zlib.h: No such file or directory
#include <zlib.h>
^~~~~~~~
compilation terminated.
>>
error deleting temporary file "/tmp/tmpfoco_h35.o": No such file or directory
ERROR: error compiling zlib application!
MRtrix3 was unable to compile a test program involving zlib.
Set the ZLIB_CFLAGS environment variable to inform 'configure' of
the flags it must provide to the compiler in order to compile
programs that use zlib functionality; this may include the path to
the zlib include files, as well as any required flags.
For example:
$ export ZLIB_CFLAGS="-isystem /usr/local/include"
$./configure
(amend with the actual path to the zlib include files on your system)
After searching for possible solutions on the forum I have tried to set a ZLIB_CFLAGS environment variable, upgrade and dwngrade my nvidia drivers without much luck.
Again, I would greatly apreciate any help you can provide.
Best,
Luis
Note for other novice linux users: I just had to type the following comand on the terminal to temporarly unset the LD enviroment variable:
unset LD