diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Exceptions.cc | 8 | ||||
-rw-r--r-- | lib/Handle.cc | 5 | ||||
-rw-r--r-- | lib/Main.cc | 4 | ||||
-rw-r--r-- | lib/Makefile.sol.mingw | 17 | ||||
-rw-r--r-- | lib/Output.cc | 5 | ||||
-rw-r--r-- | lib/fileutils.cc | 5 | ||||
-rw-r--r-- | lib/generic.cc | 4 |
7 files changed, 31 insertions, 17 deletions
diff --git a/lib/Exceptions.cc b/lib/Exceptions.cc index 110ffaa..448d161 100644 --- a/lib/Exceptions.cc +++ b/lib/Exceptions.cc @@ -1,16 +1,18 @@ #include <malloc.h> -#include <unistd.h> #include <string.h> #include <errno.h> #include <stddef.h> +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif #ifdef HAVE_GLIB #include <glib.h> #endif #ifdef DEBUG #include <iostream> #endif -#ifdef HAVE_CONFIG_H -#include "config.h" +#ifdef HAVE_PIPE +#include <unistd.h> #endif #include "String.h" #include "Exceptions.h" diff --git a/lib/Handle.cc b/lib/Handle.cc index 013b749..07a2752 100644 --- a/lib/Handle.cc +++ b/lib/Handle.cc @@ -1,11 +1,12 @@ #include <stdio.h> -#include <unistd.h> #include <string.h> #include <errno.h> -#include <fcntl.h> #ifdef HAVE_CONFIG_H #include "config.h" #endif +#ifdef HAVE_FCNTL_H +#include <fcntl.h> +#endif #include "Handle.h" #include "gettext.h" diff --git a/lib/Main.cc b/lib/Main.cc index 64cdc7d..653adea 100644 --- a/lib/Main.cc +++ b/lib/Main.cc @@ -1,8 +1,8 @@ -#include "Main.h" -#include "generic.h" #ifdef HAVE_CONFIG_H #include "config.h" #endif +#include "Main.h" +#include "generic.h" Main::Main() : setted(false) {} diff --git a/lib/Makefile.sol.mingw b/lib/Makefile.sol.mingw index 8f15e9e..0550fa8 100644 --- a/lib/Makefile.sol.mingw +++ b/lib/Makefile.sol.mingw @@ -1,14 +1,17 @@ CC = i586-mingw32msvc-gcc CXX = i586-mingw32msvc-g++ -LD = i586-mingw32msvc-ld +AR = i586-mingw32msvc-ar +RANLIB = i586-mingw32msvc-ranlib CPPFLAGS = -I../include -DFORCE64 -OBJECTS = Exceptions.o Handle.o Image.o Input.o Main.o Output.o String.o \ - checkargs.o datecalc.o fileutils.o generic.o +OBJECTS = Buffer.o Exceptions.o Handle.o Image.o Input.o Main.o Output.o \ + String.o checkargs.o datecalc.o fileutils.o generic.o +TARGET = Baltisot-sol.a -all: Baltisot-sol.dll +all: $(TARGET) -Baltisot-sol.dll: $(OBJECTS) - $(CXX) -o Baltisot-sol.dll -shared $(OBJECTS) -lz +$(TARGET): $(OBJECTS) + $(AR) r Baltisot-sol.a $(OBJECTS) + $(RANLIB) Baltisot-sol.a clean: - rm -f *.o + rm -f *.o $(TARGET) diff --git a/lib/Output.cc b/lib/Output.cc index 1ebf6db..99fff7a 100644 --- a/lib/Output.cc +++ b/lib/Output.cc @@ -1,13 +1,14 @@ #include <stdio.h> -#include <unistd.h> #include <string.h> #include <errno.h> #include <sys/types.h> #include <sys/stat.h> -#include <fcntl.h> #ifdef HAVE_CONFIG_H #include "config.h" #endif +#ifdef HAVE_FCNTL_H +#include <fcntl.h> +#endif #include "Output.h" #include "Exceptions.h" #include "gettext.h" diff --git a/lib/fileutils.cc b/lib/fileutils.cc index b04a414..6e3ef17 100644 --- a/lib/fileutils.cc +++ b/lib/fileutils.cc @@ -21,7 +21,12 @@ #include <stdio.h> #include <string.h> #include <stdlib.h> +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif #include "generic.h" unsigned long filesize(int f_iso) diff --git a/lib/generic.cc b/lib/generic.cc index 357779f..0eb5bb2 100644 --- a/lib/generic.cc +++ b/lib/generic.cc @@ -19,7 +19,9 @@ #include <stdio.h> #include <stdarg.h> - +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif #include "String.h" char verbosity = 0; |