changes while trying to build on a Mac
parent
894caf8f12
commit
b7fcafc9ec
|
@ -21,3 +21,14 @@ src/Makefile.in
|
||||||
src/config.h
|
src/config.h
|
||||||
src/config.h.in
|
src/config.h.in
|
||||||
src/stamp-h1
|
src/stamp-h1
|
||||||
|
*~
|
||||||
|
NOTES.txt
|
||||||
|
autom4te.cache
|
||||||
|
contrib/cbif.o
|
||||||
|
src/aiori-MPIIO.o
|
||||||
|
src/aiori-PLFS.c
|
||||||
|
src/aiori-POSIX.o
|
||||||
|
src/ior
|
||||||
|
src/ior.o
|
||||||
|
src/parse_options.o
|
||||||
|
src/utilities.o
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
\******************************************************************************/
|
\******************************************************************************/
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "config.h"
|
# include "config.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -22,10 +22,12 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <sys/stat.h> /* struct stat */
|
#include <sys/stat.h> /* struct stat */
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
|
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
#include <sys/time.h> /* gettimeofday() */
|
# include <sys/time.h> /* gettimeofday() */
|
||||||
#include <sys/utsname.h> /* uname() */
|
# include <sys/utsname.h> /* uname() */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
|
|
||||||
#include "ior.h"
|
#include "ior.h"
|
||||||
|
|
|
@ -73,9 +73,13 @@ static size_t NodeMemoryStringToBytes(char *size_str)
|
||||||
ERR("percentage must be between 0 and 100");
|
ERR("percentage must be between 0 and 100");
|
||||||
|
|
||||||
page_size = sysconf(_SC_PAGESIZE);
|
page_size = sysconf(_SC_PAGESIZE);
|
||||||
|
#ifdef _SC_PHYS_PAGES
|
||||||
num_pages = sysconf(_SC_PHYS_PAGES);
|
num_pages = sysconf(_SC_PHYS_PAGES);
|
||||||
if (num_pages == -1)
|
if (num_pages == -1)
|
||||||
ERR("sysconf(_SC_PHYS_PAGES) is not supported");
|
ERR("sysconf(_SC_PHYS_PAGES) is not supported");
|
||||||
|
#else
|
||||||
|
ERR("sysconf(_SC_PHYS_PAGES) is not supported");
|
||||||
|
#endif
|
||||||
mem = page_size * num_pages;
|
mem = page_size * num_pages;
|
||||||
|
|
||||||
return mem / 100 * percent;
|
return mem / 100 * percent;
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
\******************************************************************************/
|
\******************************************************************************/
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "config.h"
|
# include "config.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -25,14 +25,18 @@
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
|
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
#include <regex.h>
|
# include <regex.h>
|
||||||
#ifdef __sun /* SunOS does not support statfs(), instead uses statvfs() */
|
# ifdef __sun /* SunOS does not support statfs(), instead uses statvfs() */
|
||||||
#include <sys/statvfs.h>
|
# include <sys/statvfs.h>
|
||||||
#else /* !__sun */
|
# elif (defined __APPLE__)
|
||||||
#include <sys/statfs.h>
|
# include <sys/param.h>
|
||||||
#endif /* __sun */
|
# include <sys/mount.h>
|
||||||
#include <sys/time.h> /* gettimeofday() */
|
# else /* ! __sun or __APPLE__ */
|
||||||
|
# include <sys/statfs.h>
|
||||||
|
# endif /* __sun */
|
||||||
|
# include <sys/time.h> /* gettimeofday() */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "utilities.h"
|
#include "utilities.h"
|
||||||
|
|
Loading…
Reference in New Issue