Shicheng-Guo / bsmap

Automatically exported from code.google.com/p/bsmap
0 stars 0 forks source link

Error during "make" #13

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Extract archive content in a directory
2. CD into the directory
3. make

What is the expected output? What do you see instead?

$ make
g++ -DMAXHITS=1000 -DTHREAD -funroll-loops -Lsamtools -Isamtools -Lgzstream 
-Igzstream -O3 -m64 -c align.cpp -o align.o
g++ -DMAXHITS=1000 -DTHREAD -funroll-loops -Lsamtools -Isamtools -Lgzstream 
-Igzstream -O3 -m64 -c dbseq.cpp -o dbseq.o
g++ -DMAXHITS=1000 -DTHREAD -funroll-loops -Lsamtools -Isamtools -Lgzstream 
-Igzstream -O3 -m64 -c main.cpp -o main.o
g++ -DMAXHITS=1000 -DTHREAD -funroll-loops -Lsamtools -Isamtools -Lgzstream 
-Igzstream -O3 -m64 -c pairs.cpp -o pairs.o
g++ -DMAXHITS=1000 -DTHREAD -funroll-loops -Lsamtools -Isamtools -Lgzstream 
-Igzstream -O3 -m64 -c param.cpp -o param.o
param.cpp: In constructor ‘Param::Param()’:
param.cpp:8:20: error: ‘_SC_NPROCESSORS_ONLN’ was not declared in this scope
  num_procs=sysconf(_SC_NPROCESSORS_ONLN);
                    ^
param.cpp:8:40: error: ‘sysconf’ was not declared in this scope
  num_procs=sysconf(_SC_NPROCESSORS_ONLN);
                                        ^
make: *** [param.o] Error 1

What version of the product are you using? On what operating system?
Using 2.74 on OSX 10.8.2

Please provide any additional information below.
$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin12.0.0/4.8.0/lto-w
rapper
Target: x86_64-apple-darwin12.0.0
Configured with: ../gcc-4.8-20120722/configure --enable-languages=fortran
Thread model: posix
gcc version 4.8.0 20120722 (experimental) (GCC) 

Original issue reported on code.google.com by madbessoul on 1 Feb 2013 at 4:46

GoogleCodeExporter commented 9 years ago
adding "#include<unistd.h>" in the beginning of param.cpp would solve this 
problem.

Original comment by Joker...@gmail.com on 29 Apr 2013 at 2:18

GoogleCodeExporter commented 9 years ago
This issue still exists in the newest version, running on Ubuntu LTS 14.04

$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.8/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.8.2-19ubuntu1' 
--with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs 
--enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr 
--program-suffix=-4.8 --enable-shared --enable-linker-build-id 
--libexecdir=/usr/lib --without-included-gettext --enable-threads=posix 
--with-gxx-include-dir=/usr/include/c++/4.8 --libdir=/usr/lib --enable-nls 
--with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug 
--enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libmudflap 
--enable-plugin --with-system-zlib --disable-browser-plugin 
--enable-java-awt=gtk --enable-gtk-cairo 
--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64/jre --enable-java-home 
--with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64 
--with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.8-amd64 
--with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar 
--enable-objc-gc --enable-multiarch --disable-werror --with-arch-32=i686 
--with-abi=m64 --with-multilib-list=m32,m64,mx32 --with-tune=generic 
--enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu 
--target=x86_64-linux-gnu
Thread model: posix
gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1) 

Original comment by ville.Q....@gmail.com on 20 May 2015 at 7:12