Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/common/librnbg.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ int MMG5_kPartBoxCompute(SCOTCH_Graph *graf, int vertNbr, int boxVertNbr,

/* Initializing SCOTCH functions */
CHECK_SCOTCH(SCOTCH_stratInit(&strat), "scotch_stratInit", 0) ;
if ( SCOTCH_6 ) {
if ( SCOTCH_6 || SCOTCH_7 ) {
CHECK_SCOTCH(SCOTCH_archCmplt(&arch, boxNbr), "scotch_archCmplt", 0) ;
}
else {
Expand All @@ -87,7 +87,7 @@ int MMG5_kPartBoxCompute(SCOTCH_Graph *graf, int vertNbr, int boxVertNbr,
}


if ( SCOTCH_6 ) {
if ( SCOTCH_6 || SCOTCH_7 ) {
// Looking for the max value in sortPartTb and computing sortPartTb as
// followed :
// - sortPartTb[2i] is the box value
Expand Down Expand Up @@ -237,7 +237,7 @@ int MMG5_scotchCall(MMG5_pMesh mesh, MMG5_pSol met,
/*check enough vertex to renum*/
if ( mesh->info.renum && (mesh->np/2. > MMG5_BOXSIZE) ) {

if ( (SCOTCH_5 && SCOTCH_6 ) || ( (!SCOTCH_5) && (!SCOTCH_6) ) ) {
if ( (SCOTCH_5 && SCOTCH_6 && SCOTCH_7 ) || ( (!SCOTCH_5) && (!SCOTCH_6) && (!SCOTCH_7) ) ) {
if ( !mmgWarn ) {
fprintf(stderr,"\n ## Warning: %s: fail to determine scotch version."
" No renumbering.\n",__func__);
Expand Down
2 changes: 2 additions & 0 deletions src/common/librnbg.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@

#define SCOTCH_6 !strcmp(TOSTRING(SCOTCH_VERSION),"6")

#define SCOTCH_7 !strcmp(TOSTRING(SCOTCH_VERSION),"7")

#define CHECK_SCOTCH(t,m,e) if(0!=t){perror(m);return e;}

typedef struct MeshGraphHash_ {
Expand Down