slang-users mailing list

[2005 Date Index] [2005 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

[slang-users] mingwdll.diff


A patch for makefile.all to make wslang32.dll under Mingw32.

Marko
--- /cygdrive/s/jed/slang-2.0.0/src/mkfiles/makefile.all	2005-04-24 18:43:10.000000000 +0200
+++ makefile.all	2005-05-04 15:06:20.406250000 +0200
@@ -259,12 +259,21 @@
 !  elifdef MINGW32 #{{{
 # This Makefile is for the MINGW32 environment
 CC = $(TOOL_PREFIX)gcc
+!   ifdef DLL
+CFLAGS += -DWIN32 -W -Wall -O2 -fno-strength-reduce -DSLANG_DLL=1
+!   else
 CFLAGS += -DWIN32 -W -Wall -O2 -fno-strength-reduce
+!   endif
 P = /#
 O = o # Object extension
 SRCDIR = .# Location of sources
 OBJDIR = gw32objs# Location of objects
-TARGET = $(OBJDIR)/libslang.a
+!   ifdef DLL
+TGTBASE=$(OBJDIR)\\wslang32
+!   else
+TGTBASE=$(OBJDIR)\\libslang
+!   endif
+TARGET = $(TGTBASE).a
 COMPILE_CMD = $(CC) -c $(CFLAGS) -o #
 LIBDEPS =
 RM = rm
@@ -398,9 +407,16 @@
 	$(RANLIB) $(TARGET)
 ! elifdef BCC
 	tlib $(TARGET) /P32 /C @$(RSPFILE)
-! elifdef EMX CYGWIN32 MINGW32
+! elifdef EMX CYGWIN32
 	$(AR_CR) $(TARGET) $(OBJS)
 	$(RANLIB) $(TARGET)
+! elifdef MINGW32
+!  ifdef DLL
+	$(CC) -shared -o $(TGTBASE).dll $(OBJS) -Wl,--out-implib,$(TARGET)
+!  else	
+	$(AR_CR) $(TARGET) $(OBJS)
+	$(RANLIB) $(TARGET)
+!  endif
 ! elifdef VC
 # dll support
 !ifdef DLL
_______________________________________________
To unsubscribe, visit http://jedsoft.org/slang/mailinglists.html

[2005 date index] [2005 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]