bangerth / spec-cpuv8-sampleflow

A benchmark for the SPEC CPUv8 test suite based on the deal.II and SampleFlow libraries
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Don't require GETHOSTNAME etc #20

Closed bangerth closed 1 year ago

bangerth commented 1 year ago
g++      -std=c++17   -m64 -c -odealii/source/base/job_identifier.obj -DSPEC -DNDEBUG -DSPEC_WINDOWS -Idealii/include -Idealii/bundled/boost-1.70.0/include -ISampleFlow/include  -g -O3 -march=native    -DSPEC_LP64 -DWIN32       dealii/source/base/job_identifier.cc

dealii/source/base/job_identifier.cc: In constructor 'dealii::JobIdentifier::JobIdentifier()':

dealii/source/base/job_identifier.cc:43:3: error: 'gethostname' was not declared in this scope

   43 |   gethostname(name, 99);

Fixed by undefining a flag in src\dealii\include\deal.II\base\config.h:

#if !defined(SPEC_WINDOWS)

#define DEAL_II_HAVE_GETHOSTNAME

#endif

The next CE after that fix was:

g++      -std=c++17   -m64 -c -odealii/source/base/timer.obj -DSPEC -DNDEBUG -DSPEC_WINDOWS -Idealii/include -Idealii/bundled/boost-1.70.0/include -ISampleFlow/include  -g -O3 -march=native    -DSPEC_LP64 -DWIN32       dealii/source/base/timer.cc

dealii/source/base/timer.cc:34:12: fatal error: sys/resource.h: No such file or directory

   34 | #  include <sys/resource.h>

Fixed by this in src\dealii\include\deal.II\base\config.h:

#if !defined(SPEC_WINDOWS)

#define DEAL_II_HAVE_SYS_RESOURCE_H

#endif

The next CE was:

g++      -std=c++17   -m64 -c -odealii/source/base/timer.obj -DSPEC -DNDEBUG -DSPEC_WINDOWS -Idealii/include -Idealii/bundled/boost-1.70.0/include -ISampleFlow/include  -g -O3 -march=native    -DSPEC_LP64 -DWIN32       dealii/source/base/timer.cc

In file included from dealii/include/deal.II/base/exceptions.h:19,

                 from dealii/source/base/timer.cc:16:

dealii/source/base/timer.cc: In static member function 'static dealii::CPUClock::time_point dealii::CPUClock::now()':

dealii/include/deal.II/base/config.h:551:32: note: '#pragma message: "Unsupported platform. Porting not finished."'

…at which point I’ve decided this workload would take more than a few minutes to port successfully on MinGW.

bangerth commented 1 year ago

This is fixed by 63238a844cee634b671710d5160c1d7d14644443