summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPixel <pixel@nobis-crew.org>2009-11-05 11:46:01 -0800
committerPixel <pixel@nobis-crew.org>2009-11-05 11:46:01 -0800
commiteed3ccd0e2bffb427c4e9e7fae9d92bd153ca0da (patch)
treefee670bd0def2114749c810f79e104b0413080c0
parent20722ea0f5a136a3339156650f210fe30019fcfd (diff)
Adding CentOS mingw support, stripping and dist target support.
-rw-r--r--Makefile3
-rw-r--r--Makefile.mingw3217
2 files changed, 17 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index e7504fc..5f93b74 100644
--- a/Makefile
+++ b/Makefile
@@ -17,7 +17,7 @@ LD = g++ -m32
endif
CC = gcc
CXX = g++
-STRIP = strip
+STRIP = strip --strip-unneeded
HAS_ORACLE=$(shell [ -d /usr/local/instantclient ] && echo true || echo false ])
@@ -174,6 +174,7 @@ all: dep modules
dist: modules
mkdir -p ../lua-interface-dist
+ $(STRIP) $(MODULES_LIST)
cp $(MODULES_LIST) ../lua-interface-dist
modules: $(MODULES_LIST)
diff --git a/Makefile.mingw32 b/Makefile.mingw32
index 2cc1ee6..d068423 100644
--- a/Makefile.mingw32
+++ b/Makefile.mingw32
@@ -3,7 +3,7 @@ ifeq ($(SYSTEM),Darwin)
CC = i386-mingw32-gcc
CXX = i386-mingw32-g++
LD = i386-mingw32-g++
-STRIP = i386-mingw32-strip
+STRIP = i386-mingw32-strip --strip-unneeded
else
ifeq ($(SYSTEM),MINGW32_NT-5.1)
CC = gcc
@@ -11,10 +11,18 @@ CXX = g++
LD = g++
strip = strip
else
+DISTRIB=$(shell cat /etc/issue | cut -f 1 -d\ | head -1)
+ifeq ($(DISTRIB), CentOS)
+CC = i686-pc-mingw32-gcc
+CXX = i686-pc-mingw32-g++
+LD = i686-pc-mingw32-g++
+STRIP = i686-pc-mingw32-strip --strip-unneeded
+else
CC = i586-mingw32msvc-gcc
CXX = i586-mingw32msvc-g++
LD = i586-mingw32msvc-g++
-STRIP = i586-mingw32msvc-strip
+STRIP = i586-mingw32msvc-strip --strip-unneeded
+endif
endif
endif
@@ -163,6 +171,11 @@ ALL_DEPS = $(addsuffix .dep, $(notdir $(basename $(WHOLE_SOURCES))))
all: dep modules
+dist: modules
+ mkdir -p ../lua-interface-dist-win32
+ $(STRIP) $(MODULES_LIST)
+ cp $(MODULES_LIST) ../lua-interface-dist-win32
+
modules: $(MODULES_LIST)
dep: $(ALL_DEPS)