Commit 32282d7b authored by incardon's avatar incardon

Latest modules

parent c7fc4b77
# - Try to find LibHilbert
# Once done this will define
#
# LIBHILBERT_FOUND - system has LibHilbert
# LIBHILBERT_INCLUDE_DIRS - include directories for PETSc
# LIBHILBERT_LIBRARY_DIRS - library directories for PETSc
# LIBHILBERT_LIBRARIES - libraries for PETSc
#
#=============================================================================
# Copyright (C) 2010-2016 Pietro Incardona
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
# COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#=============================================================================
if (LIBHILBERT_FOUND)
return()
endif()
add_library(libhilbert INTERFACE IMPORTED)
# Add libraries (static)
set(_libs "-L${LIBHILBERT_ROOT}/lib -llibhilbert")
set_property(TARGET libhilbert PROPERTY INTERFACE_LINK_LIBRARIES "${_libs}")
# Create LibHilbert test program
set(LIBHILBERT_TEST_LIB_CPP
"${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/libhilbert_test_lib.cpp")
file(WRITE ${LIBHILBERT_TEST_LIB_CPP} "
extern \"C\"
{
#include \"hilbertKey.h\"
}
int main()
{
//An integer to handle errors
int err;
//Array to handle output
uint64_t nextCoord[2];
//Get the coordinates of the next cell
getIntCoordFromHKey(nextCoord, 4, 2, 0, &err);
return 0;
}
")
# Try to run test program (static linking)
try_run(
LIBHILBERT_TEST_LIB_EXITCODE
LIBHILBERT_TEST_LIB_COMPILED
${CMAKE_CURRENT_BINARY_DIR}
${LIBHILBERT_TEST_LIB_CPP}
CMAKE_FLAGS
"-DINCLUDE_DIRECTORIES:STRING=${LIBHILBERT_ROOT}/include"
"-DLINK_LIBRARIES:STRING=${LIBHILBERT_ROOT}/lib"
LINK_LIBRARIES libhilbert
COMPILE_OUTPUT_VARIABLE LIBHILBERT_TEST_LIB_COMPILE_OUTPUT
RUN_OUTPUT_VARIABLE LIBHILBERT_TEST_LIB_OUTPUT)
if (LIBHILBERT_TEST_LIB_COMPILED AND LIBHILBERT_TEST_LIB_EXITCODE EQUAL 0)
message(STATUS "Test LibHilbert_TEST_RUNS static linking - Success")
set(LIBHILBERT_TEST_RUNS TRUE)
set(LIBHILBERT_FOUND TRUE)
set(LIBHILBERT_INCLUDE_DIRS ${LIBHILBERT_ROOT}/include)
set(LIBHILBERT_LIBRARY_DIRS ${LIBHILBERT_ROOT}/lib)
set(LIBHILBERT_LIBRARIES -llibhilbert)
else()
message(STATUS "Test LibHilbert_TEST_RUNS static linking - Failed")
set(LIBHILBERT_TEST_RUNS FALSE)
endif()
......@@ -407,8 +407,6 @@ template<typename CellList> inline void calc_forces(particles & vd, CellList & N
calc_forces_gpu<<<part.wthr,part.thr>>>(vd.toKernel_sorted(),NN.toKernel(),W_dap,cbar);
vd.merge_sort<force,drho,red>(NN);
// vd.merge_sort<rho>(NN);
// vd.merge_sort<red>(NN);
max_visc = reduce<red,_max_>(vd);
}
......
......@@ -275,7 +275,7 @@ if [ -d "$i_dir/PARMETIS" ]; then
configure_options=" $configure_options --with-parmetis=$i_dir/PARMETIS "
fi
if [ -d "$i_dir/HDF5" ]; then
configure_options=" $configure_options --with-hdf5=$i_dir/HDF5/bin/h5pcc "
configure_options=" $configure_options --with-hdf5=$i_dir/HDF5/ "
fi
if [ -d "$i_dir/LIBHILBERT" ]; then
configure_options=" $configure_options --with-libhilbert=$i_dir/LIBHILBERT "
......@@ -378,7 +378,7 @@ else
exit 1
fi
./script/install_HDF5.sh $i_dir $ncore
configure_options=" $configure_options --with-hdf5=$i_dir/HDF5/bin/h5pcc "
configure_options=" $configure_options --with-hdf5=$i_dir/HDF5/ "
HDF5_installed=1
elif [ $conf_err -eq 210 ]; then
echo "LIBHILBERT not found try to install"
......
openfpm_data @ 92d2fa5c
Subproject commit d8f45e69a4c75e526d0a5c8e73b2cc426f898676
Subproject commit 92d2fa5c78269d4f5fb9937155ded8de13ba12af
......@@ -20,7 +20,7 @@ function conf_PETSC()
lin_alg_dir="$lin_alg_dir -L$i_dir/OPENBLAS/lib"
lin_alg_lib="$lin_alg_lib -lopenblas"
lin_alg_inc="$lin_alg_inc -I$i_dir/OPENBLAS/include"
configure_blas_option="--with-blas=-L$i_dir/OPENBLAS/lib -lopenblas"
configure_blas_option="--with-blas=-L$i_dir/OPENBLAS/"
fi
if [ -d "$i_dir/SCALAPACK" ]; then
lin_alg_dir="$lin_alg_dir -L$i_dir/SCALAPACK/lib"
......
......@@ -246,13 +246,12 @@ private:
//! the second element contain unassigned particles
openfpm::vector<prop,Memory,typename layout_base<prop>::type,layout_base> v_prp;
#ifdef CUDA_GPU
//! reordered v_pos buffer
openfpm::vector<prop,Memory,typename layout_base<prop>::type,layout_base> v_prp_out;
//! reordered v_prp buffer
openfpm::vector<Point<dim, St>,Memory,typename layout_base<Point<dim,St>>::type,layout_base> v_pos_out;
#endif
//! Virtual cluster
Vcluster<Memory> & v_cl;
......
......@@ -104,6 +104,9 @@ ${DEFINE_HAVE_SYS_TYPES_H}
/* Define to 1 if you have the <unistd.h> header file. */
${DEFINE_HAVE_UNISTD_H}
/* Test TinyObjLoader */
${DEFINE_HAVE_TINYOBJLOADER}
/* Define to the sub-directory where libtool stores uninstalled libraries. */
#define LT_OBJDIR ".libs/"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment