Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
6c782be9
Commit
6c782be9
authored
9 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
trying to get taucs to build on non-unix platforms (do not accept convenience static libs)
parent
e361f41c
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
CMakeLists.txt
+39
-9
39 additions, 9 deletions
CMakeLists.txt
contrib/taucs/CMakeLists.txt
+39
-63
39 additions, 63 deletions
contrib/taucs/CMakeLists.txt
contrib/taucs/src/taucs_ccs_io.c
+86
-83
86 additions, 83 deletions
contrib/taucs/src/taucs_ccs_io.c
with
164 additions
and
155 deletions
CMakeLists.txt
+
39
−
9
View file @
6c782be9
...
...
@@ -87,7 +87,7 @@ opt(SALOME "Enable Salome routines for CAD healing" ${DEFAULT})
opt
(
SGEOM
"Enable SGEOM interface to OCC (experimental)"
OFF
)
opt
(
SLEPC
"Enable SLEPc eigensolvers (required for conformal compounds)"
${
DEFAULT
}
)
opt
(
SOLVER
"Enable built-in finite element solvers (required for compounds)"
${
DEFAULT
}
)
opt
(
TAUCS
"Enable Taucs linear solver
(alternative to PETSc)"
OFF
)
opt
(
TAUCS
"Enable Taucs linear solver
"
${
DEFAULT
}
)
opt
(
TCMALLOC
"Enable libtcmalloc, a fast malloc implementation but that does not release memory"
OFF
)
opt
(
TETGEN
"Enable Tetgen 3D initial mesh generator"
${
DEFAULT
}
)
opt
(
TETGEN_OLD
"Enable older version of Tetgen"
OFF
)
...
...
@@ -901,7 +901,24 @@ if(HAVE_SOLVER)
if
(
HAVE_METIS
)
add_subdirectory
(
contrib/taucs
)
include_directories
(
contrib/taucs/src contrib/taucs/config
)
list
(
APPEND EXTERNAL_LIBRARIES taucs
)
if
(
WIN32
)
add_definitions
(
-DOSTYPE_win32
)
elseif
(
APPLE
)
add_definitions
(
-DOSTYPE_darwin
)
else
(
WIN32
)
add_definitions
(
-DOSTYPE_linux
)
endif
(
WIN32
)
file
(
GLOB_RECURSE TAUCS_D
${
CMAKE_CURRENT_BINARY_DIR
}
/contrib/taucs/D/*.c
)
file
(
GLOB_RECURSE TAUCS_S
${
CMAKE_CURRENT_BINARY_DIR
}
/contrib/taucs/S/*.c
)
file
(
GLOB_RECURSE TAUCS_Z
${
CMAKE_CURRENT_BINARY_DIR
}
/contrib/taucs/Z/*.c
)
file
(
GLOB_RECURSE TAUCS_C
${
CMAKE_CURRENT_BINARY_DIR
}
/contrib/taucs/C/*.c
)
file
(
GLOB_RECURSE TAUCS_G
${
CMAKE_CURRENT_BINARY_DIR
}
/contrib/taucs/G/*.c
)
list
(
APPEND GMSH_SRC
${
TAUCS_D
}
;
${
TAUCS_S
}
;
${
TAUCS_Z
}
;
${
TAUCS_C
}
;
${
TAUCS_G
}
)
set_source_files_properties
(
${
TAUCS_D
}
PROPERTIES COMPILE_FLAGS -DTAUCS_CORE_DOUBLE
)
set_source_files_properties
(
${
TAUCS_S
}
PROPERTIES COMPILE_FLAGS -DTAUCS_CORE_SINGLE
)
set_source_files_properties
(
${
TAUCS_Z
}
PROPERTIES COMPILE_FLAGS -DTAUCS_CORE_DCOMPLEX
)
set_source_files_properties
(
${
TAUCS_C
}
PROPERTIES COMPILE_FLAGS -DTAUCS_CORE_SCOMPLEX
)
set_source_files_properties
(
${
TAUCS_G
}
PROPERTIES COMPILE_FLAGS -DTAUCS_CORE_GENERAL
)
set_config_option
(
HAVE_TAUCS
"Taucs"
)
else
(
HAVE_METIS
)
message
(
STATUS
"Warning: Disabling Taucs (requires METIS)"
)
...
...
@@ -1298,22 +1315,35 @@ if(WALL AND NOT MSVC)
# FIXME: remove this when we have fixed the deprecated GLU code for OpenGL3
set
(
WF
"
${
WF
}
-Wno-deprecated-declarations"
)
endif
(
WDEPREC
)
set_source_files_properties
(
${
WALL_SRC
}
PROPERTIES COMPILE_FLAGS
${
WF
}
)
foreach
(
FILE
${
WALL_SRC
}
)
get_source_file_property
(
PROP
${
FILE
}
COMPILE_FLAGS
)
if
(
PROP
)
set_source_files_properties
(
${
FILE
}
PROPERTIES COMPILE_FLAGS
"
${
PROP
}
${
WF
}
"
)
else
(
PROP
)
set_source_files_properties
(
${
FILE
}
PROPERTIES COMPILE_FLAGS
"
${
WF
}
"
)
endif
(
PROP
)
endforeach
(
FILE
)
endif
(
WALL AND NOT MSVC
)
# don't issue warnings for contributed libraries
check_cxx_compiler_flag
(
"-w"
NOWARN
)
if
(
NOWARN
)
file
(
GLOB_RECURSE NOWARN_SRC contrib/*.cpp contrib/*.cc contrib/*.cxx
contrib/*.c
)
set_source_files_properties
(
${
NOWARN_SRC
}
PROPERTIES COMPILE_FLAGS
"-w"
)
file
(
GLOB_RECURSE NOWARN_SRC contrib/*.cpp contrib/*.cc contrib/*.cxx contrib/*.c
)
foreach
(
FILE
${
NOWARN_SRC
}
)
get_source_file_property
(
PROP
${
FILE
}
COMPILE_FLAGS
)
if
(
PROP
)
set_source_files_properties
(
${
FILE
}
PROPERTIES COMPILE_FLAGS
"
${
PROP
}
-w"
)
else
(
PROP
)
set_source_files_properties
(
${
FILE
}
PROPERTIES COMPILE_FLAGS
"-w"
)
endif
(
PROP
)
endforeach
(
FILE
)
endif
(
NOWARN
)
# disable compile optimization on some known problematic files
check_cxx_compiler_flag
(
"-O0"
NOOPT
)
if
(
NOOPT
)
file
(
GLOB_RECURSE NOOPT_SRC Mesh/BDS.cpp
Parser/Gmsh.tab.cpp
contrib/Tetgen*/predicates.cxx
)
file
(
GLOB_RECURSE NOOPT_SRC Mesh/BDS.cpp
Parser/Gmsh.tab.cpp
contrib/Tetgen*/predicates.cxx
)
foreach
(
FILE
${
NOOPT_SRC
}
)
get_source_file_property
(
PROP
${
FILE
}
COMPILE_FLAGS
)
if
(
PROP
)
...
...
@@ -1849,7 +1879,7 @@ message(STATUS "")
mark_as_advanced
(
GMSH_EXTRA_VERSION
ACIS_LIB ANN_INC ANN_LIB CAIRO_LIB CAIRO_INC CGNS_INC GMM_INC
GMP_INC GMP_LIB MMG3D_INC MMG3D_LIB
TAUCS_INC TAUCS_LIB
HDF5_LIB
GMP_INC GMP_LIB MMG3D_INC MMG3D_LIB HDF5_LIB
MED_LIB OCC_INC OCC_CONFIG_H SZ_LIB
PETSC_LIBS SLEPC_INC SLEPC_INC2 SLEPC_LIB
BISON FLEX MAKEINFO TEXI2PDF FLTK_CONFIG_SCRIPT
...
...
This diff is collapsed.
Click to expand it.
contrib/taucs/CMakeLists.txt
+
39
−
63
View file @
6c782be9
...
...
@@ -6,39 +6,39 @@
# contributor : Jonathan Lambrechts
set
(
SRC_MULTI
taucs_sn_llt
taucs_ccs_base
taucs_vec_base
taucs_ccs_ops
taucs_ccs_io
taucs_ccs_factor_llt
taucs_ccs_solve_llt
taucs_complex
taucs_ccs_ooc_llt
taucs_ccs_ooc_lu
src/
taucs_sn_llt
.c
src/
taucs_ccs_base
.c
src/
taucs_vec_base
.c
src/
taucs_ccs_ops
.c
src/
taucs_ccs_io
.c
src/
taucs_ccs_factor_llt
.c
src/
taucs_ccs_solve_llt
.c
src/
taucs_complex
.c
src/
taucs_ccs_ooc_llt
.c
src/
taucs_ccs_ooc_lu
.c
)
set
(
SRC_DOUBLE
taucs_iter
taucs_vaidya
taucs_recvaidya
taucs_gremban
taucs_ccs_xxt
taucs_ccs_generators
src/
taucs_iter
.c
src/
taucs_vaidya
.c
src/
taucs_recvaidya
.c
src/
taucs_gremban
.c
src/
taucs_ccs_xxt
.c
src/
taucs_ccs_generators
.c
)
set
(
SRC_GENERAL
taucs_linsolve
taucs_ccs_order
taucs_memory
taucs_logging
taucs_timer
taucs_ooc_io
taucs_malloc
src/
taucs_linsolve
.c
src/
taucs_ccs_order
.c
src/
taucs_memory
.c
src/
taucs_logging
.c
src/
taucs_timer
.c
src/
taucs_ooc_io
.c
src/
taucs_malloc
.c
)
set
(
SRC
external/src/readhb.c
#
external/src/readhb.c
external/src/amdatr.c
external/src/amdbar.c
external/src/amdexa.c
...
...
@@ -50,45 +50,21 @@ set(SRC
external/src/colamd.c
)
function
(
build_variant SFILE FLAG DNAME
)
file
(
COPY
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/src/
${
SFILE
}
.c"
DESTINATION
"
${
CMAKE_CURRENT_BINARY_DIR
}
/
${
DNAME
}
"
)
set
(
DEST
"
${
CMAKE_CURRENT_BINARY_DIR
}
/
${
DNAME
}
/
${
SFILE
}
.c"
)
set_property
(
SOURCE
${
DEST
}
PROPERTY COMPILE_FLAGS
"
${
FLAG
}
"
)
list
(
APPEND SRC
${
DEST
}
)
set
(
SRC
${
SRC
}
PARENT_SCOPE
)
endfunction
(
build_variant
)
file
(
GLOB_RECURSE HDR RELATIVE
${
CMAKE_CURRENT_SOURCE_DIR
}
*.h
)
append_gmsh_src
(
contrib/taucs
"
${
SRC
}
;
${
HDR
}
"
)
foreach
(
S
FILE
${
SRC_MULTI
}
)
build_variant
(
${
S
FILE
}
"-DTAUCS_CORE_DOUBLE"
"D"
)
build_variant
(
${
S
FILE
}
"-DTAUCS_CORE_SINGLE"
"S"
)
build_variant
(
${
S
FILE
}
"-DTAUCS_CORE_DCOMPLEX"
"Z"
)
build_variant
(
${
S
FILE
}
"-DTAUCS_CORE_SCOMPLEX"
"C"
)
build_variant
(
${
S
FILE
}
"-DTAUCS_CORE_GENERAL"
"G"
)
endforeach
(
S
FILE
)
foreach
(
FILE
${
SRC_MULTI
}
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/D
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/S
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/Z
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/C
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/G
)
endforeach
(
FILE
)
foreach
(
S
FILE
${
SRC_DOUBLE
}
)
build_variant
(
${
S
FILE
}
"-DTAUCS_CORE_DOUBLE"
"D"
)
endforeach
(
S
FILE
)
foreach
(
FILE
${
SRC_DOUBLE
}
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/D
)
endforeach
(
FILE
)
foreach
(
SFILE
${
SRC_GENERAL
}
)
build_variant
(
${
SFILE
}
"-DTAUCS_CORE_GENERAL"
"G"
)
endforeach
(
SFILE
)
include_directories
(
src config
)
set
(
FLAGS
"-std=c99 -fPIC"
)
if
(
UNIX
)
if
(
APPLE
)
set
(
FLAGS
"
${
FLAGS
}
-DOSTYPE_darwin"
)
else
(
APPLE
)
set
(
FLAGS
"
${
FLAGS
}
-DOSTYPE_linux"
)
endif
(
APPLE
)
endif
(
UNIX
)
if
(
WIN32
)
set
(
FLAGS
"
${
FLAGS
}
-DOSTYPE_win32"
)
endif
(
WIN32
)
add_library
(
taucs STATIC
${
SRC
}
)
set_property
(
TARGET taucs PROPERTY COMPILE_FLAGS
${
FLAGS
}
)
foreach
(
FILE
${
SRC_GENERAL
}
)
file
(
COPY
${
FILE
}
DESTINATION
${
CMAKE_CURRENT_BINARY_DIR
}
/G
)
endforeach
(
FILE
)
This diff is collapsed.
Click to expand it.
contrib/taucs/src/taucs_ccs_io.c
+
86
−
83
View file @
6c782be9
...
...
@@ -127,6 +127,7 @@ taucs_ccs_read_binary(char* filename)
taucs_ccs_matrix
*
taucs_ccs_read_hb
(
char
*
filename
,
int
flags
)
{
#if 0 // Gmsh - to remove dependencies
taucs_ccs_matrix* A = NULL;
int nrows,ncols,nnz,j;
char fname[256];
...
...
@@ -273,6 +274,9 @@ taucs_ccs_read_hb(char* filename,int flags)
taucs_printf("taucs_ccs_read_hb: done reading\n");
return A;
#else
return
0
;
#endif
}
...
...
@@ -1049,4 +1053,3 @@ taucs_vec_write_binary(int n, int flags, void* v, char* filename)
/*********************************************************/
/* */
/*********************************************************/
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment