superlu/superlu-include.patch

183 lines
6.3 KiB
Diff

Index: SuperLU_3.0/SRC/xerbla.c
===================================================================
--- SuperLU_3.0.orig/SRC/xerbla.c
+++ SuperLU_3.0/SRC/xerbla.c
@@ -1,5 +1,5 @@
-#include "stdio.h"
+#include <stdio.h>
/* Subroutine */ int xerbla_(char *srname, int *info)
{
/* -- LAPACK auxiliary routine (version 2.0) --
Index: SuperLU_3.0/TESTING/MATGEN/lsamen.c
===================================================================
--- SuperLU_3.0.orig/TESTING/MATGEN/lsamen.c
+++ SuperLU_3.0/TESTING/MATGEN/lsamen.c
@@ -1,5 +1,6 @@
#include "f2c.h"
+#include <string.h>
logical lsamen_(integer *n, char *ca, char *cb)
{
/* -- LAPACK auxiliary routine (version 2.0) --
Index: SuperLU_3.0/INSTALL/timertst.c
===================================================================
--- SuperLU_3.0.orig/INSTALL/timertst.c
+++ SuperLU_3.0/INSTALL/timertst.c
@@ -1,5 +1,6 @@
#include <stdio.h>
+#include <stdlib.h>
void mysub(int n, double *x, double *y)
{
return;
Index: SuperLU_3.0/TESTING/sdrive.c
===================================================================
--- SuperLU_3.0.orig/TESTING/sdrive.c
+++ SuperLU_3.0/TESTING/sdrive.c
@@ -10,8 +10,9 @@
* File name: sdrive.c
* Purpose: MAIN test program
*/
#include <string.h>
+#include <unistd.h>
#include "slu_sdefs.h"
#define NTESTS 5 /* Number of test types */
#define NTYPES 11 /* Number of matrix types */
@@ -21,8 +22,13 @@
#define FMT2 "%10s:fact=%4d, trans=%4d, equed=%c, n=%d, imat=%d, test(%d)=%12.5g\n"
#define FMT3 "%10s:info=%d, izero=%d, n=%d, nrhs=%d, imat=%d, nfail=%d\n"
+static void
+parse_command_line(int argc, char *argv[], char *matrix_type,
+ int *n, int *w, int *relax, int *nrhs, int *maxsuper,
+ int *rowblk, int *colblk, int *lwork, double *u);
+
main(int argc, char *argv[])
{
/*
* Purpose
@@ -82,9 +88,8 @@ main(int argc, char *argv[])
SamePattern_SameRowPerm};
static trans_t transs[] = {NOTRANS, TRANS, CONJ};
/* Some function prototypes */
- static void parse_command_line();
extern int sp_sget01(int, int, SuperMatrix *, SuperMatrix *,
SuperMatrix *, int *, float *);
extern int sp_sget02(trans_t, int, int, int, SuperMatrix *, float *,
int, float *, int, float *resid);
Index: SuperLU_3.0/TESTING/ddrive.c
===================================================================
--- SuperLU_3.0.orig/TESTING/ddrive.c
+++ SuperLU_3.0/TESTING/ddrive.c
@@ -10,8 +10,9 @@
* File name: ddrive.c
* Purpose: MAIN test program
*/
#include <string.h>
+#include <unistd.h>
#include "slu_ddefs.h"
#define NTESTS 5 /* Number of test types */
#define NTYPES 11 /* Number of matrix types */
@@ -20,8 +21,12 @@
#define FMT1 "%10s:n=%d, test(%d)=%12.5g\n"
#define FMT2 "%10s:fact=%4d, trans=%4d, equed=%c, n=%d, imat=%d, test(%d)=%12.5g\n"
#define FMT3 "%10s:info=%d, izero=%d, n=%d, nrhs=%d, imat=%d, nfail=%d\n"
+static void
+parse_command_line(int argc, char *argv[], char *matrix_type,
+ int *n, int *w, int *relax, int *nrhs, int *maxsuper,
+ int *rowblk, int *colblk, int *lwork, double *u);
main(int argc, char *argv[])
{
/*
@@ -82,9 +87,8 @@ main(int argc, char *argv[])
SamePattern_SameRowPerm};
static trans_t transs[] = {NOTRANS, TRANS, CONJ};
/* Some function prototypes */
- static void parse_command_line();
extern int sp_dget01(int, int, SuperMatrix *, SuperMatrix *,
SuperMatrix *, int *, double *);
extern int sp_dget02(trans_t, int, int, int, SuperMatrix *, double *,
int, double *, int, double *resid);
Index: SuperLU_3.0/TESTING/cdrive.c
===================================================================
--- SuperLU_3.0.orig/TESTING/cdrive.c
+++ SuperLU_3.0/TESTING/cdrive.c
@@ -10,8 +10,9 @@
* File name: cdrive.c
* Purpose: MAIN test program
*/
#include <string.h>
+#include <unistd.h>
#include "slu_cdefs.h"
#define NTESTS 5 /* Number of test types */
#define NTYPES 11 /* Number of matrix types */
@@ -20,8 +21,12 @@
#define FMT1 "%10s:n=%d, test(%d)=%12.5g\n"
#define FMT2 "%10s:fact=%4d, trans=%4d, equed=%c, n=%d, imat=%d, test(%d)=%12.5g\n"
#define FMT3 "%10s:info=%d, izero=%d, n=%d, nrhs=%d, imat=%d, nfail=%d\n"
+static void
+parse_command_line(int argc, char *argv[], char *matrix_type,
+ int *n, int *w, int *relax, int *nrhs, int *maxsuper,
+ int *rowblk, int *colblk, int *lwork, double *u);
main(int argc, char *argv[])
{
/*
@@ -82,9 +87,8 @@ main(int argc, char *argv[])
SamePattern_SameRowPerm};
static trans_t transs[] = {NOTRANS, TRANS, CONJ};
/* Some function prototypes */
- static void parse_command_line();
extern int sp_cget01(int, int, SuperMatrix *, SuperMatrix *,
SuperMatrix *, int *, float *);
extern int sp_cget02(trans_t, int, int, int, SuperMatrix *, complex *,
int, complex *, int, float *resid);
Index: SuperLU_3.0/TESTING/zdrive.c
===================================================================
--- SuperLU_3.0.orig/TESTING/zdrive.c
+++ SuperLU_3.0/TESTING/zdrive.c
@@ -10,8 +10,9 @@
* File name: zdrive.c
* Purpose: MAIN test program
*/
#include <string.h>
+#include <unistd.h>
#include "slu_zdefs.h"
#define NTESTS 5 /* Number of test types */
#define NTYPES 11 /* Number of matrix types */
@@ -20,8 +21,12 @@
#define FMT1 "%10s:n=%d, test(%d)=%12.5g\n"
#define FMT2 "%10s:fact=%4d, trans=%4d, equed=%c, n=%d, imat=%d, test(%d)=%12.5g\n"
#define FMT3 "%10s:info=%d, izero=%d, n=%d, nrhs=%d, imat=%d, nfail=%d\n"
+static void
+parse_command_line(int argc, char *argv[], char *matrix_type,
+ int *n, int *w, int *relax, int *nrhs, int *maxsuper,
+ int *rowblk, int *colblk, int *lwork, double *u);
main(int argc, char *argv[])
{
/*
@@ -82,9 +87,8 @@ main(int argc, char *argv[])
SamePattern_SameRowPerm};
static trans_t transs[] = {NOTRANS, TRANS, CONJ};
/* Some function prototypes */
- static void parse_command_line();
extern int sp_zget01(int, int, SuperMatrix *, SuperMatrix *,
SuperMatrix *, int *, double *);
extern int sp_zget02(trans_t, int, int, int, SuperMatrix *, doublecomplex *,
int, doublecomplex *, int, double *resid);