diff --git a/Core/Samples/inc/Layer.h b/Core/Samples/inc/Layer.h index dbf75cf0208cd4d727a740acb50bbfa17672077f..fd2f73c9bb9cea260a0e74aefea07ad8f8fb01e2 100644 --- a/Core/Samples/inc/Layer.h +++ b/Core/Samples/inc/Layer.h @@ -44,7 +44,8 @@ class Layer : public ICompositeSample virtual ~Layer() {} - virtual Layer *clone() const { return new Layer(*this); } + //virtual Layer *clone() const { return new Layer(*this); } + virtual Layer *clone() const { return new Layer(mp_material, m_thickness); } //! Sets layer thickness in Angstrom. virtual void setThickness(double thickness); @@ -76,7 +77,7 @@ class Layer : public ICompositeSample virtual LayerDWBASimulation *createDWBASimulation() const { return 0; } protected: - Layer(const Layer& other) + Layer(const Layer& other) : ICompositeSample() { mp_material = other.mp_material; m_thickness = other.m_thickness; diff --git a/Tests/FunctionalTests/TestCore/IsGISAXS03/IsGISAXS03.cpp b/Tests/FunctionalTests/TestCore/IsGISAXS03/IsGISAXS03.cpp index 176899bb58530766801370ab2a5edd635bc6616e..a92e0fd2303c990169f92cafc5607bd492b3dd13 100644 --- a/Tests/FunctionalTests/TestCore/IsGISAXS03/IsGISAXS03.cpp +++ b/Tests/FunctionalTests/TestCore/IsGISAXS03/IsGISAXS03.cpp @@ -111,7 +111,8 @@ void FunctionalTests::IsGISAXS03::runBA_Size() Particle nano_particle(n_particle, p_ff_cylinder); // radius of nanoparticles will be sampled with gaussian probability int nbins(100), nfwhm(2); - StochasticSampledParameter par(StochasticDoubleGaussian(radius, sigma), nbins, nfwhm); + StochasticDoubleGaussian double_gaussian(radius, sigma); + StochasticSampledParameter par(double_gaussian, nbins, nfwhm); ParticleBuilder builder; builder.setPrototype(nano_particle,"/Particle/FormFactorCylinder/radius", par); builder.plantParticles(particle_decoration); diff --git a/shared.pri b/shared.pri index ed3e5620c7a63b756548af78f17dcf0778afba57..1c206d34abb74130f4de1b119ce5f8d80e5f88e6 100644 --- a/shared.pri +++ b/shared.pri @@ -177,7 +177,6 @@ CONFIG(BORNAGAIN_ROOT) { # ----------------------------------------------------------------------------- CONFIG += BORNAGAIN_PYTHON CONFIG(BORNAGAIN_PYTHON) { - # TODO - implement check for existance of numpy/arrayobject.h # user wants to compile python module WhichPython=$$system(which python) isEmpty(WhichPython) { @@ -200,6 +199,7 @@ CONFIG(BORNAGAIN_PYTHON) { # we need to know the location of numpy pythonnumpy=$$system("python -c 'import sys; import numpy; sys.stdout.write(numpy.get_include())'") + !exists($$pythonnumpy/numpy/arrayobject.h): error("Can't find numpy/arrayobject.h in $$pythonnumpy, you have to install python-numpy-devel") INCLUDEPATH += $$pythonnumpy } }