X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ea258ad3489638fbcf504a674f8793b1362bd2b5..3f2bcf34371665165e8232c7fdf3776cfff11892:/src/xpm/MAKEFILE.VA diff --git a/src/xpm/MAKEFILE.VA b/src/xpm/MAKEFILE.VA index 9f7c573468..00a3b0e514 100644 --- a/src/xpm/MAKEFILE.VA +++ b/src/xpm/MAKEFILE.VA @@ -13,18 +13,27 @@ OBJSUFF=obj SRCSUFF=cpp -OS2FLAGS=/c /W2 /DOS232 /D__VISAGECPP__ /Dwx_msw /Ss /Q /N100 +OS2FLAGS=/c /W2 /DOS232 /D__VISAGECPP30__ /Dwx_msw /Q /N100 OS2LINKFLAGS=/BASE:0x00010000 /PMTYPE:PM /NOE /NOD /ALIGN:16 OS2LIBFLAGS=/NOL /NOE OS2LIBS=CPPOM30.lib CPPOOC3.LIB OS2386.LIB +!if "$(WXMAKINGDLL)" != "0" +EXTRADLLFLAGS=/DWXMAKINGDLL=1 /Ge- /D__OS2DLL__ +EXTRALNKFLAGS=/DLL +!endif + # Change WXDIR or WXWIN to wherever wxWindows is found WXDIR = $(WXWIN) OS2XPMDIR=$(WXDIR)\src\xpm OS2XPMINC=$(WINXPMDIR) -OS2XPMLIB=$(WXDIR)\lib\os2xpm.lib +!if "$(WXMAKINGDLL)" != "1" +OS2XPMLIB=$(WXDIR)\lib\os2xpm.lib +!else +OS2XPMLIB=$(WXDIR)\lib\os2xpm.dll +!endif INC=-I$(WXDIR)\src\xpm -I$(OS2XPMINC) !ifndef FINAL @@ -42,7 +51,11 @@ MAKEPRECOMP=/Fi$(PCH) !endif !if "$(FINAL)" == "0" +!if "$(WXMAKINGDLL)" == "1" +D=DebugOS2DLL +!else D=DebugOS2 +!endif OPT = DEBUG_FLAGS= /Ti /D__WXDEBUG__ #/Fb LINK_DEBUG_FLAGS=/DEBUG @@ -50,7 +63,11 @@ CRTFLAG=/Gm /Gd !else # /O1 - smallest code # /O2 - fastest code +!if "$(WXMAKINGDLL)" == "1" +D=RelseOS2DLL +!else D=RelseOS2 +!endif OPT = /O+ /Oc /G5 DEBUG_FLAGS= LINK_DEBUG_FLAGS=/RELEASE @@ -61,7 +78,8 @@ CRTFLAG=/Gm /Gd !endif -CPPFLAGS=$(OS2FLAGS) $(DEBUG_FLAGS) $(PRECOMP) $(INC) $(OPT) $(CRTFLAG) +CPPFLAGS=$(OS2FLAGS) $(EXTRADLLFLAGS) $(DEBUG_FLAGS) $(PRECOMP) $(INC) $(OPT) $(CRTFLAG) +LINKFKAGS=$(OS2LINKFLAGS) $(EXTRALNKFLAGS) {..\xpm}.c{..\xpm\$D}.obj: @echo $< @@ -111,6 +129,39 @@ LIBOBJECTS = \ wrffrdat.obj \ wrffri.obj +all: $(OBJECTS) $(OS2XPMLIB) + +!if "$(WXMAKINGDLL)" != "1" + +$(WXDIR)\lib\os2xpm.lib: $(LIBOBJECTS) + touch $(WXDIR)\lib\os2xpm.lib + del $(WXDIR)\lib\os2xpm.lib + ilib $(OS2LIBFLAGS) $@ @<< + $**; +<< + del *.obj + +!else + +# Update the dynamic link library +$(WXDIR)\lib\os2xpm.dll: $(OBJECTS) + icc @<< + /B" $(LINKFLAGS)" /Fe$@ + $(LIBS) + $(OBJECTS) + $(WXDIR)\src\os2\os2xpm.def +<< + implib $(WXDIR)\lib\os2xpmd.lib $(WXDIR)\src\os2\os2xpm.def + +!endif + +clean: + del $(OS2XPMLIB) + erase /N $(OS2XPMDIR)\$D + rd $(OS2XPMDIR)\$D + +cleanall: clean + $(LIBOBJECTS): copy ..\xpm\$D\attrib.obj copy ..\xpm\$D\crbuffri.obj @@ -132,20 +183,3 @@ $(LIBOBJECTS): copy ..\xpm\$D\wrffrdat.obj copy ..\xpm\$D\wrffri.obj -all: $(OS2XPMLIB) - -$(WXDIR)\lib\os2xpm.lib: $(LIBOBJECTS) - touch $(WXDIR)\lib\os2xpm.lib - del $(WXDIR)\lib\os2xpm.lib - ilib $(OS2LIBFLAGS) $@ @<< - $**; -<< - del *.obj - -clean: - del $(OS2XPMLIB) - erase /N $(OS2XPMDIR)\$D - rd $(OS2XPMDIR)\$D - -cleanall: clean -