Skip to content

Commit 0f1a69b

Browse files
committed
Simplify checks and inclusion dependencies
1 parent 2da754e commit 0f1a69b

File tree

8 files changed

+18
-22
lines changed

8 files changed

+18
-22
lines changed

config/sc_memalign.m4

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ dnl verify that posix_memalign can be linked against
6464
]],
6565
[[
6666
int *a;
67-
int err = posix_memalign((void **) &a, $$1_MEMALIGN_BYTES_LINK, 3 * sizeof(*a));
67+
posix_memalign((void **) &a, $$1_MEMALIGN_BYTES_LINK, 3 * sizeof(*a));
6868
free(a);
6969
]])],
7070
[], [AC_MSG_ERROR([Linking posix_memalign failed])])

config/sc_mpi.m4

+11-15
Original file line numberDiff line numberDiff line change
@@ -299,11 +299,9 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM(
299299
#undef MPI
300300
#include <mpi.h>
301301
]], [[
302-
int mpiret;
303302
int mpithr;
304-
mpiret = MPI_Init_thread ((int *) 0, (char ***) 0,
305-
MPI_THREAD_MULTIPLE, &mpithr);
306-
mpiret = MPI_Finalize ();
303+
MPI_Init_thread ((int *) 0, (char ***) 0, MPI_THREAD_MULTIPLE, &mpithr);
304+
MPI_Finalize ();
307305
]])],
308306
[AC_MSG_RESULT([successful])
309307
$1],
@@ -322,18 +320,17 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM(
322320
#undef MPI
323321
#include <mpi.h>
324322
]], [[
325-
int mpiret;
326-
int mpithr;
327323
int disp_unit=0;
328324
char *baseptr;
329325
MPI_Win win;
330326
MPI_Init ((int *) 0, (char ***) 0);
331-
mpiret = MPI_Win_allocate_shared(0,disp_unit,MPI_INFO_NULL,MPI_COMM_WORLD,(void *) &baseptr,&win);
332-
mpiret = MPI_Win_shared_query(win,0,0,&disp_unit,(void *) &baseptr);
333-
mpiret = MPI_Win_lock(MPI_LOCK_EXCLUSIVE,0,MPI_MODE_NOCHECK,win);
334-
mpiret = MPI_Win_unlock(0,win);
335-
mpiret = MPI_Win_free(&win);
336-
mpiret = MPI_Finalize ();
327+
MPI_Win_allocate_shared(0,disp_unit,MPI_INFO_NULL,MPI_COMM_WORLD,
328+
(void *) &baseptr,&win);
329+
MPI_Win_shared_query(win,0,0,&disp_unit,(void *) &baseptr);
330+
MPI_Win_lock(MPI_LOCK_EXCLUSIVE,0,MPI_MODE_NOCHECK,win);
331+
MPI_Win_unlock(0,win);
332+
MPI_Win_free(&win);
333+
MPI_Finalize ();
337334
]])],
338335
[AC_MSG_RESULT([successful])
339336
$1],
@@ -352,11 +349,10 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM(
352349
#undef MPI
353350
#include <mpi.h>
354351
]], [[
355-
int mpiret;
356352
MPI_Comm subcomm;
357353
MPI_Init ((int *) 0, (char ***) 0);
358-
mpiret = MPI_Comm_split_type(MPI_COMM_WORLD,MPI_COMM_TYPE_SHARED,0,MPI_INFO_NULL,&subcomm);
359-
mpiret = MPI_Finalize ();
354+
MPI_Comm_split_type(MPI_COMM_WORLD,MPI_COMM_TYPE_SHARED,0,MPI_INFO_NULL,&subcomm);
355+
MPI_Finalize ();
360356
]])],
361357
[AC_MSG_RESULT([successful])
362358
$1],

config/sc_openmp.m4

+2
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ if test "x$$1_ENABLE_OPENMP" != xno ; then
4040
[[
4141
#include <omp.h>
4242
]],[[
43+
omp_lock_t wlock;
44+
omp_set_lock (&wlock);
4345
omp_set_num_threads (2);
4446
#pragma omp parallel
4547
{

libb64/Makefile.am

-2
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@
55

66
bin_PROGRAMS += libb64/sc_b64enc libb64/sc_b64dec
77
libb64_sc_b64enc_SOURCES = libb64/b64enc.c
8-
libb64_sc_b64enc_CPPFLAGS = $(AM_CPPFLAGS) -I@top_srcdir@/libb64
98
libb64_sc_b64dec_SOURCES = libb64/b64dec.c
10-
libb64_sc_b64dec_CPPFLAGS = $(AM_CPPFLAGS) -I@top_srcdir@/libb64
119

1210
libb64_internal_headers = libb64/libb64.h
1311
libb64_compiled_sources = libb64/cencode.c libb64/cdecode.c

libb64/b64dec.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This is part of the libb64 project, and has been placed in the public domain.
1010
For details, see http://sourceforge.net/projects/libb64
1111
*/
1212

13-
#include <libb64.h>
13+
#include "libb64.h"
1414
#include <stdio.h>
1515
#include <stdlib.h>
1616

libb64/b64enc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This is part of the libb64 project, and has been placed in the public domain.
1010
For details, see http://sourceforge.net/projects/libb64
1111
*/
1212

13-
#include <libb64.h>
13+
#include "libb64.h"
1414
#include <stdio.h>
1515
#include <stdlib.h>
1616

libb64/cdecode.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This is part of the libb64 project, and has been placed in the public domain.
1010
For details, see http://sourceforge.net/projects/libb64
1111
*/
1212

13-
#include <libb64.h>
13+
#include "libb64.h"
1414

1515
static inline char
1616
base64_decode_value (char value_in)

libb64/cencode.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This is part of the libb64 project, and has been placed in the public domain.
1010
For details, see http://sourceforge.net/projects/libb64
1111
*/
1212

13-
#include <libb64.h>
13+
#include "libb64.h"
1414

1515
const int CHARS_PER_LINE = 72;
1616

0 commit comments

Comments
 (0)