summaryrefslogtreecommitdiff
path: root/win32/iconv/Makefile.os2
diff options
context:
space:
mode:
authorPixel <pixel@nobis-crew.org>2011-10-11 16:45:31 -0700
committerPixel <pixel@nobis-crew.org>2011-10-11 16:45:31 -0700
commitead67afc96cdff3e74bb616e8e3a8b0a7695a28a (patch)
tree4d074d11a7983bdbde3f6da7d311cddd9696ef0d /win32/iconv/Makefile.os2
parentd2252afcd74af0248c6141c8086d03e12a0a316f (diff)
Making the project compile with mingw32, on the same Makefile. No more separate Makefiles insanity.
Diffstat (limited to 'win32/iconv/Makefile.os2')
-rw-r--r--win32/iconv/Makefile.os277
1 files changed, 77 insertions, 0 deletions
diff --git a/win32/iconv/Makefile.os2 b/win32/iconv/Makefile.os2
new file mode 100644
index 0000000..12a55ad
--- /dev/null
+++ b/win32/iconv/Makefile.os2
@@ -0,0 +1,77 @@
+# Makefile for libiconv/lib, OS2/EMX specific
+#
+# requires EMX/GCC development environment and
+# GNU fileutils and GNU textutils installed
+#
+# define EMXPATH=<your EMX path> on install/uninstall
+#
+
+#### Start of system configuration section. ####
+
+# Directories used by "make install":
+prefix = @prefix@
+exec_prefix = $(prefix)
+libdir = $(exec_prefix)/lib
+shlibdir = $(exec_prefix)/dll
+
+# Programs used by "make":
+CC = gcc
+CFLAGS = -O2 -Zomf -Zcrtdll -Zmt
+INCLUDES = -I. -I../include
+
+#### End of system configuration section. ####
+
+.SUFFIXES: .obj .o
+
+SOURCES = iconv.c
+
+OBJECTS = iconv.obj
+
+all : iconv.dll iconv.a iconv.lib
+
+config.h : force
+ sed -e 's/#undef WORDS_LITTLEENDIAN$$/#define WORDS_LITTLEENDIAN 1/' < config.h.in > config.h
+
+iconv.obj : iconv.c encodings.def encodings_local.def aliases.h config.h
+ $(CC) $(INCLUDES) $(CFLAGS) -c iconv.c
+
+iconv.dll : $(OBJECTS) ../os2/iconv.def # DLL itself
+ $(CC) -Zdll $(CFLAGS) -o $@ $(OBJECTS) ../os2/iconv.def
+
+iconv.lib : ../os2/iconv.def # Import Lib. for -Zomf
+ rm -f iconv.lib
+ emximp -o iconv.lib ../os2/iconv.def
+
+iconv.a : ../os2/iconv.def # Import Lib. for EMX .o format
+ rm -f iconv.a
+ emximp -o iconv.a ../os2/iconv.def
+
+# Installs the library and include files only. Typically called with only
+# $(libdir), $(shlibdir) and $(includedir) - don't use $(prefix) and
+# $(exec_prefix) here.
+install-lib : all force
+ cp -i iconv.dll $(shlibdir)/iconv.dll
+ cp -i iconv.lib $(libdir)/iconv.lib
+ cp -i iconv.a $(libdir)/iconv.a
+
+install : all force
+ cp -i iconv.dll $(shlibdir)/iconv.dll
+ cp -i iconv.lib $(libdir)/iconv.lib
+ cp -i iconv.a $(libdir)/iconv.a
+
+uninstall : force
+ rm -f $(shlibdir)/iconv.dll
+ rm -f $(libdir)/iconv.lib
+ rm -f $(libdir)/iconv.a
+
+check : all
+
+clean : force
+ rm -f *.obj *.lib *.a *.dll core
+
+distclean : clean
+ rm -f config.h
+
+maintainer-clean : distclean
+
+force :