Return-Path: Received: from mx2.fz-rossendorf.de ([149.220.142.12] verified) by hzdr.de (CommuniGate Pro SMTP 6.1.9) with ESMTP id 13985942 for picongpu-users@cg.hzdr.de; Thu, 28 Apr 2016 12:17:33 +0200 Received: from localhost (localhost [127.0.0.1]) by mx2.fz-rossendorf.de (Postfix) with ESMTP id EF526455DA for ; Thu, 28 Apr 2016 12:17:32 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at mx2.fz-rossendorf.de Received: from mx2.fz-rossendorf.de ([127.0.0.1]) by localhost (mx2.fz-rossendorf.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7QSm5Q8-WBud for ; Thu, 28 Apr 2016 12:17:28 +0200 (CEST) Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=117.240.185.84; helo=n-spamfilter3.rrcat.gov.in; envelope-from=ajitup@rrcat.gov.in; receiver=picongpu-users@hzdr.de X-Greylist: delayed 21958 seconds by postgrey-1.34 at mx2; Thu, 28 Apr 2016 12:17:27 CEST Received: from n-spamfilter3.rrcat.gov.in (unknown [117.240.185.84]) by mx2.fz-rossendorf.de (Postfix) with ESMTP id A62A54535F for ; Thu, 28 Apr 2016 12:17:27 +0200 (CEST) Received: (qmail 12579 invoked by uid 507); 28 Apr 2016 15:46:53 +0530 Received: from 10.11.105.109 by n-spamfilter3.rrcat.gov.in (envelope-from , uid 501) with qmail-scanner-2.08 (clamdscan: 0.98.4/19638. spamassassin: 3.3.1. Clear:RC:1(10.11.105.109):. Processed in 0.02245 secs); 28 Apr 2016 10:16:53 -0000 Received: from unknown (HELO n-postfix1.rrcat.gov.in) (10.11.105.109) by n-spamfilter3.rrcat.gov.in with SMTP; 28 Apr 2016 15:46:53 +0530 Received: from webmail.cat.ernet.in (n-webmai2 [10.11.105.202]) by n-postfix1.rrcat.gov.in (Postfix) with ESMTPA id 849781FC53 for ; Thu, 28 Apr 2016 15:46:53 +0530 (IST) Received: from 10.126.2.194 (SquirrelMail authenticated user ajitup) by n-webmail2.rrcat.gov.in with HTTP; Thu, 28 Apr 2016 15:46:46 +0530 Message-ID: In-Reply-To: References: Date: Thu, 28 Apr 2016 15:46:46 +0530 Subject: Re: [PIConGPU-Users] [PIConGPU-Users] [PIConGPU-Users] [PIConGPU-Users] PIConGPU compilation -lpthread error From: "Dr. Ajit Upadhyay" To: picongpu-users@hzdr.de Reply-To: ajitup@rrcat.gov.in User-Agent: SquirrelMail/1.4.22 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 X-Priority: 3 (Normal) Importance: Normal Content-Transfer-Encoding: quoted-printable Dear Rene, Yes, they seem to be independent problems. I could not understand which CMakeLists.txt is to be edited and where should I put those lines. I am not aware of cmake scripting. Is it the on= e in /src/picongpu directory. I would be grateful if you could send me the edited CMakeLists.txt Here is the output of commands: ajitup@plasma01:~> cmake --version cmake version 3.5.1 CMake suite maintained and supported by Kitware (kitware.com/cmake). ajitup@plasma01:~> cd ~/src/picongpu ajitup@plasma01:~/src/picongpu> git status On branch release-0.1.2 Your branch is up-to-date with 'origin/release-0.1.2'. nothing to commit, working directory clean ajitup@plasma01:~/src/picongpu> git checkout HEAD Your branch is up-to-date with 'origin/release-0.1.2'. ajitup@plasma01:~/src/picongpu> cd ~/build ajitup@plasma01:~/build> rm -r ../build/* ajitup@plasma01:~/build> echo $PICSRC /home/ajitup/src/picongpu ajitup@plasma01:~/build> ls ~/paramSets/case001 cmakeFlags include submit ajitup@plasma01:~/build> $PICSRC/configure ~/paramSets/case001 cmake command: cmake -DCUDA_ARCH=3Dsm_20 -DCMAKE_INSTALL_PREFIX=3D/home/ajitup/paramSets/case001 -DPIC_EXTENSION_PATH=3D/home/ajitup/paramSets/case001 =20 /home/ajitup/src/picongpu -- The C compiler identification is GNU 4.8.5 -- The CXX compiler identification is GNU 4.8.5 -- Check for working C compiler: /usr/bin/cc -- Check for working C compiler: /usr/bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Looking for pthread.h -- Looking for pthread.h - found -- Looking for pthread_create -- Looking for pthread_create - not found -- Looking for pthread_create in pthreads -- Looking for pthread_create in pthreads - found -- Found Threads: TRUE -- Found CUDA: /usr/local/cuda (found suitable version "7.0", minimum required is "5.0") -- Debug version -- Found MPI_C: /usr/lib64/mpi/gcc/openmpi/lib64/libmpi.so -- Found MPI_CXX: /usr/lib64/mpi/gcc/openmpi/lib64/libmpi_cxx.so;/usr/lib64/mpi/gcc/openmpi= /lib64/libmpi.so -- Boost version: 1.54.0 -- Found the following Boost libraries: -- program_options -- regex -- filesystem -- system CMake Error at CMakeLists.txt:38 (add_subdirectory): The binary directory /home/ajitup/build/build_picongpu is already used to build a source directory. It cannot be used to buil= d source directory /home/ajitup/src/picongpu/src/picongpu Specify a unique binary directory name. CMake Error at CMakeLists.txt:38 (add_subdirectory): The binary directory /home/ajitup/build/build_picongpu is already used to build a source directory. It cannot be used to buil= d source directory /home/ajitup/src/picongpu/src/picongpu Specify a unique binary directory name. -- Found 'adios_config': /home/ajitup/lib/adios/bin/adios_config -- ADIOS linker flags (unparsed): -L/home/ajitup/lib/adios/lib -ladios -l= m -lmxml -lpthread -libverbs -- Found adios in /home/ajitup/lib/adios/lib64/libadios.a -- Found m in /usr/lib64/libm.so -- Found mxml in /usr/lib64/libmxml.so -- Found pthread in /usr/lib64/libpthread.so -- Found ibverbs in /usr/lib64/libibverbs.so -- Found ADIOS: /home/ajitup/lib/adios/lib64/libadios.a;/usr/lib64/libm.so;/usr/lib64/lib= mxml.so;/usr/lib64/libpthread.so;/usr/lib64/libibverbs.so (found suitable version "1.9.0", minimum required is "1.6.0") -- Enable ADIOS data transforms -- Found HDF5: /usr/lib64/mpi/gcc/openmpi/lib64/libhdf5.so;/usr/lib64/libpthread.so;/usr= /lib64/libz.so;/usr/lib64/libdl.so;/usr/lib64/libm.so (found version "1.8.16") -- libSplash supports PARALLEL output -- Found Splash: /home/ajitup/lib/splash/lib/libsplash.a;/usr/lib64/mpi/gcc/openmpi/lib64/= libhdf5.so;/usr/lib64/libpthread.so;/usr/lib64/libz.so;/usr/lib64/libdl.s= o;/usr/lib64/libm.so;/usr/lib64/mpi/gcc/openmpi/lib64/libmpi.so;/usr/lib6= 4/mpi/gcc/openmpi/lib64/libmpi_cxx.so;/usr/lib64/mpi/gcc/openmpi/lib64/li= bmpi.so (found suitable version "1.3.0", minimum required is "1.2.4") -- Found ZLIB: /usr/lib64/libz.so (found version "1.2.8") -- Found PNG: /usr/lib64/libpng.so (found suitable version "1.6.8", minimum required is "1.2.9") -- Found Freetype: /usr/lib64/libfreetype.so (found version "2.5.5") -- Found PNGwriter: /home/ajitup/lib/pngwriter/lib/libpngwriter.so;/usr/lib64/libpng.so;/usr/= lib64/libz.so;/usr/lib64/libfreetype.so (found version "0.5.4") -- Configuring incomplete, errors occurred! See also "/home/ajitup/build/CMakeFiles/CMakeOutput.log". See also "/home/ajitup/build/CMakeFiles/CMakeError.log". ajitup@plasma01:~/build> make make: *** No targets specified and no makefile found. Stop. ajitup@plasma01:~/build> regards, ajit > ---------------------------- Original Message -------------------------= --- > Subject: Re: [PIConGPU-Users] [PIConGPU-Users] [PIConGPU-Users] > [PIConGPU-Users] PIConGPU compilation -lpthread error > From: Ren=C3=A9 Widera > Date: Thu, April 28, 2016 2:46 pm > To: picongpu-users@hzdr.de > -----------------------------------------------------------------------= --- > > Dear Ajit, > > it looks like that both issues are independent. > > pthread issue: > - the linker needs to know that you need libpthread.so > - please add `-lpthread` to your linker command or add in CMakeLists.tx= t > ```CMAKE > find_package(Threads REQUIRED) > set(LIBS ${LIBS} ${CMAKE_THREAD_LIBS_INIT}) > #... > target_link_libraries( > PROJECTNAME > ${LIBS}) > ``` > > picongpu issue: > > Your log shows this: > ``` > CMake Error at CMakeLists.txt:38 (add_subdirectory): > The binary directory > /home/ajitup/build/build_picongpu > is already used to build a source directory. It cannot be used to > build > source directory > /home/ajitup/code.PIConGPU/picongpu-master/src/picongpu > ``` > - it looks like cmake asume that the source code of PICoNGPU is in > `~/code.PIConGPU` and not in `$PICSRC` which points to `~/src/picongpu` > - please run the following commands and send use the output > - `cmake --version` > - `cd ~/src/picongpu` > - `git status` > - `git checkout HEAD .` > - `cd ~/build` > - `rm -r ../build/*` > - `echo $PICSRC` > - `ls ~/paramSets/case001` > - `$PICSRC/configure ~/paramSets/case001` > - `make` > > best, > > Ren=C3=A9 > > On 28.04.2016 06:10, Dr. Ajit Upadhyay wrote: >> Dear Axel, >> >> I have been following your suggestion. >> Every time, I use a script to build which has >> >> rm -fR ~/build >> mkdir ~/build >> cd ~/build >> $PICSRC/configure ~/paramSets/case001 >> >> So there is no question of any outdated build residing inside the buil= d >> directory. >> As before every build attempt, the build directory is re-created. >> It could be some other issue, which I am not able to find out. >> >> Also, could pthread_create error be due to cuda-7.5 and gcc-4.8 and >> glibc? >> Today, I will try with cuda-7.0 and same version of gcc and glibc and >> let you know. >> >> Regards, >> Ajit >> >> >> >> -----Original Message----- >> From: picongpu-users@hzdr.de [mailto:picongpu-users@hzdr.de] On Behalf >> Of Huebl, Axel >> Sent: Wednesday, April 27, 2016 8:43 PM >> To: picongpu-users@hzdr.de >> Subject: Re: [PIConGPU-Users] [PIConGPU-Users] PIConGPU compilation >> -lpthread error >> >> Dear Ajit, >> >> looks like an older, outdated build using CMake resides inside build/ >> Just remove it like this: >> >> cd $HOME/build >> rm -rf ../build/* >> >> $PICSRC/configure ~/paramSets/case001 >> make -j install >> >> >> Best, >> Axel >> >> On 27.04.2016 12:35, Dr. Ajit Upadhyay wrote: >>> Dear Ren=C3=A9, >>> >>> Thanks for such a prompt reply. The log files, I sent were from the >>> release-0.1.2 branch. However, I did try "master" as well, but the >>> error >>> remains same. >>> >>> $PICSRC/configure ~/paramSets/case001 >>> >>> in release-0.1.2 branch as well as master branch gives following >>> error:- >>> >>> >>> CMake Error at CMakeLists.txt:38 (add_subdirectory): >>> The binary directory >>> /home/ajitup/build/build_picongpu >>> is already used to build a source directory. It cannot be used to >>> build >>> source directory >>> /home/ajitup/code.PIConGPU/picongpu-master/src/picongpu >>> Specify a unique binary directory name. >>> >>> CMake Error at CMakeLists.txt:38 (add_subdirectory): >>> The binary directory >>> /home/ajitup/build/build_picongpu >>> is already used to build a source directory. It cannot be used to >>> build >>> source directory >>> /home/ajitup/code.PIConGPU/picongpu-master/src/picongpu >>> Specify a unique binary directory name. >>> >>> >>> Whereas, there is no quota set by HPC system and I am able to >>> write/create >>> a file/folder in ~/build directory. my PICSRC is ~/src/picongpu and I >>> build the code in ~/build directory. Further error is in CMakeError.l= og >>> : >>> >>> >>> Determining if the pthread_create exist failed with the following >>> output: >>> Change Dir: /home/ajitup/build/CMakeFiles/CMakeTmp >>> >>> Run Build Command:"/usr/bin/gmake" "cmTC_d035f/fast" >>> /usr/bin/gmake -f CMakeFiles/cmTC_d035f.dir/build.make >>> CMakeFiles/cmTC_d035f.dir/build >>> gmake[1]: Entering directory '/home/ajitup/build/CMakeFiles/CMakeTmp' >>> Building C object CMakeFiles/cmTC_d035f.dir/CheckSymbolExists.c.o >>> /usr/bin/cc -fPIC -o >>> CMakeFiles/cmTC_d035f.dir/CheckSymbolExists.c.o >>> -c /home/ajitup/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c >>> Linking C executable cmTC_d035f >>> /usr/local/bin/cmake -E cmake_link_script >>> CMakeFiles/cmTC_d035f.dir/link.txt --verbose=3D1 >>> /usr/bin/cc -fPIC CMakeFiles/cmTC_d035f.dir/CheckSymbolExists.c.= o >>> -o >>> cmTC_d035f -rdynamic >>> CMakeFiles/cmTC_d035f.dir/CheckSymbolExists.c.o: In function `main': >>> CheckSymbolExists.c:(.text+0x1b): undefined reference to >>> `pthread_create' >>> collect2: error: ld returned 1 exit status >>> CMakeFiles/cmTC_d035f.dir/build.make:97: recipe for target 'cmTC_d035= f' >>> failed >>> gmake[1]: *** [cmTC_d035f] Error 1 >>> gmake[1]: Leaving directory '/home/ajitup/build/CMakeFiles/CMakeTmp' >>> Makefile:126: recipe for target 'cmTC_d035f/fast' failed >>> gmake: *** [cmTC_d035f/fast] Error 2 >>> >>> File /home/ajitup/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c: >>> /* */ >>> #include >>> >>> int main(int argc, char** argv) >>> { >>> (void)argv; >>> #ifndef pthread_create >>> return ((int*)(&pthread_create))[argc]; >>> #else >>> (void)argc; >>> return 0; >>> #endif >>> } >>> >>> >>> I have attached some test files which I compiled to check for >>> pthread_create function using $cc -lpthread ***.c -o ***.out >>> and they compiled. A search for libpthread shows it in /lib as well a= s >>> /lib64 in system-root. I have gcc 4.8.5, and cuda 7.5. I did try dev >>> branch, but as you suggested it will require enabling c++11 support. >>> The >>> error in dev branch is: >>> >>> Please enable C++11 with `-std=3Dc++11` or `-DCMAKE_CXX_STANDARD=3D11= ` >>> when >>> compiling with nvcc 7.5 >>> >>> I will try adding c++11 support and let you know, but the >>> CMakeError.log >>> shows lpthread issue even in dev branch. >>> >>> regards, >>> ajit >>> >>> Attachements: Cmake log files for release-branch >>> test codes for lpthread >>> CMakeLists.txt from release-0.1.2 >>> >>> >>>> ---------------------------- Original Message >>>> ---------------------------- >>>> Subject: Re: Help on PIConGPU? >>>> From: Ren=C3=83=C2=A9 Widera >>>> Date: Wed, April 27, 2016 2:14 pm >>>> To: "Dr. Ajit Upadhyay" >>>> ------------------------------------------------------------------ >>>> Dear Dr. Ajit Upadhyay, >>>> >>>> thank you for participate our project PIConGPU. >>>> >>>> Please subscribe at our mailing list [1] for future issues with >>>> picongpu. The mailing list helps the community if other run in equal >>>> issues. >>>> >>>> Currently I have only looked very fast to your problem, I will take = a >>>> deeper analysis tomorrow. >>>> Which version of PIConGPU you used? master or dev >>>> For cuda 7.5 please switch to `dev` because as I remember we need to >>>> enable C++11 for cuda 7.5 else PIConGPU will not compile and the >>>> master >>>> is not C++11 compatible. >>>> Please keep in mind that the branch `dev` is our working branch and >>>> interfaces can be changed. >>>> There will be a new release in one or two weeks available. >>>> >>>> I looked first at your file `build_output_shell` and found the error >>>> ``` >>>> CMake Error at CMakeLists.txt:38 (add_subdirectory): >>>> The binary directory >>>> /home/ajitup/build/build_picongpu >>>> ``` >>>> This looks like you are not allowed to create directories in >>>> `~/build`. >>>> Maybe your HPC System set a quota for your home directory which >>>> results >>>> in the case that no new files can be created. Could you please check >>>> this behavior. >>>> >>>> pthread issue: >>>> >>>> Could you please provide me with the cmake script and all needed >>>> files. >>>> It looks like the linker flag `lpthread` is missing in your example. >>>> >>>> If some of the issues are solved till tomorrow please give me a >>>> feedback. >>>> >>>> btw: please skip the `Dr.` before my name but I would be glad to get= a >>>> honorary degree ;-) >>>> >>>> best regards, >>>> Ren=C3=A9 >>>> >>>> [1] >>>> https://github.com/ComputationalRadiationPhysics/picongpu/tree/dev#u= sers >>>> >>>> On 27.04.2016 09:43, Dr. Ajit Upadhyay wrote: >>>>> Dear Dr. Ren=C3=A9 Widera, >>>>> >>>>> I downloaded the release-0.1.2 branch of code and tried to compile = it >>> on a HP Z840 (Intel Xeon E5-2630v3 2.4 1866 8C x 2, 128GB memory) >>> workstation with two Nividia Quadro 4200 GPUs (compatible with CUDA). >>> The OS on my workstation is openSuSe Leap 42.1 with cuda-7.5. I have >>> tested some examples from the nvidia-cuda library and they are workin= g >>> fine. >>>>> >>>>> I have compiled all the libraries required by PIConGPU successfully >>>>> and >>> placed them as per the instructions in /picongpu/src/install.md file. >>> However, when I try to compile the code itself, it gives a strange >>> error> of pthread_create function (please look at the attached >>> CMakeError.log). >>>>> >>>>> I did check that the relevant library is in its place >>>>> (/lib/libpthread-2.19.so, glibc-2.19-19.1_x86_64). I did google for >>>>> the >>> error but could not resolve this issue as the problem seems to be wit= h >>> "configure" script of the picongpu code. >>>>> >>>>> I made a test program from CMakeError.log file and compiled it >>> separately and it compiles (please have a look at pthread_check_log, = a >>> few lines of code are listed and it compiles all these which uses thi= s >>> function). I have attached the output dumped on the linux-terminal i= n >>> file build_output_shell. Other files created by cmake are also >>> attached. >>>>> >>>>> Could you please point out where is the fault in my setup of this >>>>> code >>>>> or what should I do to run this code. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> ############################################################# >>>>> This message is sent to you because you are subscribed to >>>>> the mailing list . >>>>> To unsubscribe, E-mail to: >>>>> To switch to the DIGEST mode, E-mail to >>>>> >>>>> To switch to the INDEX mode, E-mail to >>>>> Send administrative queries to >>>>> >> > > -- > Ren=C3=A9 Widera > Abteilung Laser-Teilchenbeschleunigung (FWKT) > Helmholtz-Zentrum Dresden-Rossendorf > Tel: +49 (0351) 260 3543 > r.widera@hzdr.de > http://www.hzdr.de > > Vorstand: Prof. Dr. Dr. h. c. Roland Sauerbrey, > Prof. Dr. Dr. h. c. Peter Joehnk > Vereinsregister: VR 1693 beim Amtsgericht Dresden > > ############################################################# > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > To switch to the INDEX mode, E-mail to > Send administrative queries to > >