Page 1 of 1

Problem with load for 1.62.3 on El Capitan

Posted: Fri Nov 13, 2015 2:55 am
by jimmyxia
Using the precompiled version for Yosemite on El Capitan, I got the following error when trying to use the functions 'species' and 'load':

Code: Select all

[qbox] species silicon silicon.xml
  SpeciesCmd: defining species silicon as silicon.xml
[Liyus-MacBook-Air:07106] *** Process received signal ***
[Liyus-MacBook-Air:07106] Signal: Abort trap: 6 (6)
[Liyus-MacBook-Air:07106] Signal code:  (0)
[Liyus-MacBook-Air:07106] *** End of error message ***
Abort trap: 6
silicon.xml is just http://fpmd.ucdavis.edu/potentials/Si/S ... DA-1.0.xml downloaded to my local directory. But ‘species silicon http://fpmd.ucdavis.edu/potentials/Si/S ... DA-1.0.xml’ works fine.

Code: Select all

[qbox] load test.xml
 LoadCmd: loading from test.xml
 XMLGFPreprocessor: reading from test.xml size: 2955619
 XMLGFPreprocessor: read time: 0.009517
 XMLGFPreprocessor: local read rate: 296.2 MB/s  aggregate read rate: 296.2 MB/s
 XMLGFPreprocessor: tag fixing time: 1.907e-06
 XMLGFPreprocessor: segment definition time: 0.007207
 XMLGFPreprocessor: boundary adjustment time: 1.001e-05
 XMLGFPreprocessor: transcoding time: 0.009664
 XMLGFPreprocessor: data redistribution time: 0.003804
 XMLGFPreprocessor: XML compacting time: 0.0001309
 XMLGFPreprocessor: total time: 0.03066
 xmlcontent.size(): 120539
 Starting XML parsing
[Liyus-MacBook-Air:07104] *** Process received signal ***
[Liyus-MacBook-Air:07104] Signal: Abort trap: 6 (6)
[Liyus-MacBook-Air:07104] Signal code:  (0)
[Liyus-MacBook-Air:07104] *** End of error message ***
Abort trap: 6 
Here test.xml is generated by the following script:

Code: Select all

set cell 24 0 0 0 24 0 0 0 24
species silicon http://fpmd.ucdavis.edu/potentials/Si/Si_VBC_LDA-1.0.xml
atom Si1 silicon  3.700  0.000  0.000
atom Si2 silicon  0.000  2.200  0.000
atom Si3 silicon -3.700  0.000  0.000
atom Si4 silicon  0.000 -2.200  0.000
set ecut 15
set wf_dyn PSDA
set ecutprec 2
randomize_wf
run 0 200
save test.xml
The list of dynamic libraries used on El Capitan is the following:

Code: Select all

qbox-1.62.3-OSX-Yosemite:
	/usr/lib/libcurl.4.dylib (compatibility version 7.0.0, current version 8.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1213.0.0)
It seems like xerces is not there, so I compile my own qb using the following makefile header:

Code: Select all

#
# Copyright (c) 2014 The Regents of the University of California
#
# This file is part of Qbox
#
# Qbox is distributed under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 2 of
# the License, or (at your option) any later version.
# See the file COPYING in the root directory of this distribution
# or <http://www.gnu.org/licenses/>.
#
#-------------------------------------------------------------------------------
#
#  macosx_openmpi.mk
#
#-------------------------------------------------------------------------------
#
 PLT=MacOSX_x86_64
#-------------------------------------------------------------------------------
 SCALAPACKDIR=/Users/jimmyxia/Desktop/MENG/scalapack-2.0.2
 LAPACKDIR=/Users/jimmyxia/Desktop/MENG/lapack-3.5.0
 BLASDIR=/Users/jimmyxia/Desktop/MENG/BLAS
 GFORTRAN=/usr/local/gfortran
 PLTFLAGS += -DUSE_FFTW3
 PLTFLAGS += -DFFTWMEASURE
 PLTFLAGS += -DFFTW3_2D
 FFTWDIR=/Users/jimmyxia/Desktop/MENG/fftw-3.3.4
 FFTWINCLUDEDIR=$(FFTWDIR)/api
 FFTWLIBDIR=$(FFTWDIR)/.libs
 INCLUDE += -I$(FFTWINCLUDEDIR)
 LIBPATH += -L$(FFTWLIBDIR)
 LIBS += -lfftw3


 PLTOBJECTS = readTSC.o

 CXX=mpiCC
 LD=$(CXX)

 PLTFLAGS += -DIA32 -DUSE_MPI -D_LARGEFILE_SOURCE \
             -D_FILE_OFFSET_BITS=64 -DADD_ \
             -DAPP_NO_THREADS -DXML_USE_NO_THREADS -DUSE_XERCES -DXERCESC_3 \
             -DSCALAPACK

 INCLUDE += -I$(LAPACKDIR) -I$(SCALAPACKDIR) -I$(GFORTRAN)/include

 CXXFLAGS= -g -O3 -D$(PLT) $(INCLUDE) $(PLTFLAGS) $(DFLAGS)

 LIBPATH += -L$(SCALAPACKDIR) -L$(LAPACKDIR) -L$(BLASDIR) -L$(GFORTRAN)/lib

 LIBS +=  -lscalapack -llapack -lblas -lm -lgfortran \
         -lxerces-c -lpthread -lmpi_cxx -lstdc++ -lcurl -liconv

 LDFLAGS = $(LIBPATH) $(LIBS)
#-------------------------------------------------------------------------------
Now xerces is in the dynamic libraries used:

Code: Select all

qb:
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1225.1.1)
	/usr/local/lib/libxerces-c-3.1.dylib (compatibility version 0.0.0, current version 0.0.0)
	/usr/local/lib/libuuid.16.dylib (compatibility version 17.0.0, current version 17.22.0)
	/usr/local/gfortran/lib/libgfortran.3.dylib (compatibility version 4.0.0, current version 4.0.0)
	/usr/local/lib/libmpi_cxx.1.dylib (compatibility version 3.0.0, current version 3.3.0)
	/usr/local/lib/libmpi.1.dylib (compatibility version 8.0.0, current version 8.0.0)
	/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.1.0)
Also ‘species silicon silicon.xml’ works now. However, the first time I do ‘load test.xml’, it works; but if I load it again, I get the following error:

Code: Select all

[qbox] load test.xml
 LoadCmd: loading from test.xml
[wireless-s1-no-150-27-8:13429] *** Process received signal ***
[wireless-s1-no-150-27-8:13429] Signal: Segmentation fault: 11 (11)
[wireless-s1-no-150-27-8:13429] Signal code: Address not mapped (1)
[wireless-s1-no-150-27-8:13429] Failing at address: 0x1
[wireless-s1-no-150-27-8:13429] [ 0] 0   libsystem_platform.dylib            0x00007fff9699852a _sigtramp + 26
[wireless-s1-no-150-27-8:13429] [ 1] 0   ???                                 0x0000000000000000 0x0 + 0
[wireless-s1-no-150-27-8:13429] [ 2] 0   qb                                  0x000000010d9d6c1a _ZN7LoadCmd6actionEiPPc + 378
[wireless-s1-no-150-27-8:13429] [ 3] 0   qb                                  0x000000010d9d4301 _ZN13UserInterface11processCmdsERNSt3__113basic_istreamIcNS0_11char_traitsIcEEEEPKcb + 1137
[wireless-s1-no-150-27-8:13429] [ 4] 0   qb                                  0x000000010d96dc20 main + 12304
[wireless-s1-no-150-27-8:13429] [ 5] 0   libdyld.dylib                       0x00007fff974a15ad start + 1
[wireless-s1-no-150-27-8:13429] [ 6] 0   ???                                 0x0000000000000001 0x0 + 1
[wireless-s1-no-150-27-8:13429] *** End of error message ***
Segmentation fault: 11
This happens in both interactive and batch mode, both single node and 2-nodes. I have not encountered any instance that I need to load twice in one script. But does anyone know how to fix this?