aboutsummaryrefslogtreecommitdiff
path: root/mpiosh
diff options
context:
space:
mode:
Diffstat (limited to 'mpiosh')
-rw-r--r--mpiosh/.gitignore2
-rw-r--r--mpiosh/CMakeLists.txt15
-rw-r--r--mpiosh/Makefile.am23
-rw-r--r--mpiosh/callback.c1
-rw-r--r--mpiosh/cfg.c (renamed from mpiosh/config.c)2
-rw-r--r--mpiosh/cfg.h (renamed from mpiosh/config.h)3
-rw-r--r--mpiosh/config.h.in9
-rw-r--r--mpiosh/global.c1
-rw-r--r--mpiosh/mpiosh.c2
9 files changed, 32 insertions, 26 deletions
diff --git a/mpiosh/.gitignore b/mpiosh/.gitignore
new file mode 100644
index 0000000..2e3941e
--- /dev/null
+++ b/mpiosh/.gitignore
@@ -0,0 +1,2 @@
+mpiosh
+config.h
diff --git a/mpiosh/CMakeLists.txt b/mpiosh/CMakeLists.txt
new file mode 100644
index 0000000..efff2c7
--- /dev/null
+++ b/mpiosh/CMakeLists.txt
@@ -0,0 +1,15 @@
+cmake_minimum_required (VERSION 2.4)
+
+set (PACKAGE mpiosh)
+project (${PACKAGE} C)
+
+set (CMAKE_C_FLAGS -Wall)
+
+configure_file (${CMAKE_CURRENT_SOURCE_DIR}/config.h.in
+ ${CMAKE_CURRENT_BINARY_DIR}/config.h)
+
+include_directories (${CMAKE_CURRENT_SOURCE_DIR}/..)
+
+add_executable (mpiosh mpiosh.c callback.c readline.c command.c global.c
+ cfgio.c cfg.c)
+target_link_libraries (mpiosh mpio -lreadline -lncurses)
diff --git a/mpiosh/Makefile.am b/mpiosh/Makefile.am
deleted file mode 100644
index ed5843e..0000000
--- a/mpiosh/Makefile.am
+++ /dev/null
@@ -1,23 +0,0 @@
-INCLUDES=-I..
-
-bin_PROGRAMS=mpiosh
-
-mpiosh_SOURCES = mpiosh.c \
- callback.c \
- readline.c \
- command.c \
- global.c \
- cfgio.c \
- config.c
-
-AM_CFLAGS=-DSYSCONFDIR=\"@sysconfdir@\"
-
-mpiosh_LDADD=../libmpio/libmpio.la -lreadline -lncurses
-
-noinst_HEADERS = mpiosh.h \
- callback.h \
- readline.h \
- command.h \
- global.h \
- cfgio.h \
- config.h \ No newline at end of file
diff --git a/mpiosh/callback.c b/mpiosh/callback.c
index ad4a133..10e5a0a 100644
--- a/mpiosh/callback.c
+++ b/mpiosh/callback.c
@@ -34,6 +34,7 @@
#include "mpiosh.h"
#include "command.h"
+#include "cfg.h"
#include "libmpio/debug.h"
diff --git a/mpiosh/config.c b/mpiosh/cfg.c
index 931f785..f8c672f 100644
--- a/mpiosh/config.c
+++ b/mpiosh/cfg.c
@@ -21,7 +21,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
-#include "config.h"
+#include "cfg.h"
#include "global.h"
#include <sys/stat.h>
diff --git a/mpiosh/config.h b/mpiosh/cfg.h
index 091e61a..4157bd6 100644
--- a/mpiosh/config.h
+++ b/mpiosh/cfg.h
@@ -4,7 +4,7 @@
*
* $Id: config.h,v 1.5 2003/06/27 13:40:23 crunchy Exp $
*
- * Copyright (C) 2001 Andreas Büsching <crunchy@tzi.de>
+ * Copyright (C) 2001 Andreas Büsching <crunchy@tzi.de>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -53,3 +53,4 @@ char * mpiosh_config_check_backup_dir( struct mpiosh_config_t *config,
#endif
/* end of config.h */
+
diff --git a/mpiosh/config.h.in b/mpiosh/config.h.in
new file mode 100644
index 0000000..bb60f14
--- /dev/null
+++ b/mpiosh/config.h.in
@@ -0,0 +1,9 @@
+#ifndef _CONFIG_H
+#define _CONFIG_H
+
+/* package name */
+#define PACKAGE "${PACKAGE}"
+#define VERSION "0.7.1-pre3"
+#define SYSCONFDIR "/etc"
+
+#endif /* _CONFIG_H */
diff --git a/mpiosh/global.c b/mpiosh/global.c
index f589114..09a63f3 100644
--- a/mpiosh/global.c
+++ b/mpiosh/global.c
@@ -24,6 +24,7 @@
#include "callback.h"
#include "global.h"
#include "readline.h"
+#include "cfg.h"
/* structure containing current state */
struct mpiosh_t mpiosh;
diff --git a/mpiosh/mpiosh.c b/mpiosh/mpiosh.c
index eb20845..7a5370a 100644
--- a/mpiosh/mpiosh.c
+++ b/mpiosh/mpiosh.c
@@ -35,7 +35,7 @@
#include "callback.h"
#include "command.h"
-#include "config.h"
+#include "cfg.h"
#include "readline.h"
#include "mpiosh.h"