From: William A. Rowe Jr Date: Thu, 4 Oct 2001 05:46:35 +0000 (+0000) Subject: mod_mime_magic aught to work, expose it. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=90c10768a16c2046300ea2873d315b4478fa9404;p=thirdparty%2Fapache%2Fhttpd.git mod_mime_magic aught to work, expose it. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@91274 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/Apache.dsw b/src/Apache.dsw index 436a53f5477..e57f45a0dd6 100644 --- a/src/Apache.dsw +++ b/src/Apache.dsw @@ -171,6 +171,21 @@ Package=<4> ############################################################################### +Project: "mod_mime_magic"=".\os\win32\mod_mime_magic.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name ApacheCore + End Project Dependency +}}} + +############################################################################### + Project: "mod_proxy"=".\os\win32\mod_proxy.dsp" - Package Owner=<4> Package=<5> @@ -327,6 +342,9 @@ Package=<4> Project_Dep_Name mod_info End Project Dependency Begin Project Dependency + Project_Dep_Name mod_mime_magic + End Project Dependency + Begin Project Dependency Project_Dep_Name mod_proxy End Project Dependency Begin Project Dependency diff --git a/src/CHANGES b/src/CHANGES index f64b3b06a71..87c783e25eb 100644 --- a/src/CHANGES +++ b/src/CHANGES @@ -1,5 +1,7 @@ Changes with Apache 1.3.21 + *) Enable mod_mime_magic (experimental) for Win32. [William Rowe] + *) Use an installed Expat library rather than the bundled Expat. This fixes a problem where multiple copies of Expat could be loaded into the process space, thus conflicting and causing strange diff --git a/src/makefile.win b/src/makefile.win index 97c85fb4c3d..a332ab35760 100644 --- a/src/makefile.win +++ b/src/makefile.win @@ -106,6 +106,7 @@ _build: $(MAKE) $(MAKEOPT) -f mod_proxy.mak CFG="mod_proxy - Win32 $(LONG)" RECURSE=0 $(CTARGET) $(MAKE) $(MAKEOPT) -f mod_unique_id.mak CFG="mod_unique_id - Win32 $(LONG)" RECURSE=0 $(CTARGET) $(MAKE) $(MAKEOPT) -f mod_vhost_alias.mak CFG="mod_vhost_alias - Win32 $(LONG)" RECURSE=0 $(CTARGET) + $(MAKE) $(MAKEOPT) -f mod_mime_magic.mak CFG="mod_mime_magic - Win32 $(LONG)" RECURSE=0 $(CTARGET) cd ..\.. _install: @@ -144,6 +145,7 @@ _install: copy os\win32\$(LONG)\mod_proxy.so "$(INSTDIR)\modules" copy os\win32\$(LONG)\mod_unique_id.so "$(INSTDIR)\modules" copy os\win32\$(LONG)\mod_vhost_alias.so "$(INSTDIR)\modules" + copy os\win32\$(LONG)\mod_mime_magic.so "$(INSTDIR)\modules" copy support\$(LONG)\htpasswd.exe "$(INSTDIR)\bin" copy support\$(LONG)\htdigest.exe "$(INSTDIR)\bin" copy support\$(LONG)\logresolve.exe "$(INSTDIR)\bin" diff --git a/src/os/win32/BaseAddr.ref b/src/os/win32/BaseAddr.ref index 158068fd676..7b136f25090 100644 --- a/src/os/win32/BaseAddr.ref +++ b/src/os/win32/BaseAddr.ref @@ -28,3 +28,4 @@ mod_proxy 0x6FE10000 0x00020000 mod_auth_dbm 0x6FE00000 0x00010000 mod_unique_id 0x6FDF0000 0x00010000 mod_vhost_alias 0x6FDE0000 0x00010000 +mod_mime_magic 0x6FDD0000 0x00010000 diff --git a/src/os/win32/mod_mime_magic.dsp b/src/os/win32/mod_mime_magic.dsp new file mode 100644 index 00000000000..d652bad9f8e --- /dev/null +++ b/src/os/win32/mod_mime_magic.dsp @@ -0,0 +1,95 @@ +# Microsoft Developer Studio Project File - Name="mod_mime_magic" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 + +CFG=mod_mime_magic - Win32 Release +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "mod_mime_magic.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "mod_mime_magic.mak" CFG="mod_mime_magic - Win32 Release" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "mod_mime_magic - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE "mod_mime_magic - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "mod_mime_magic - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MD /W3 /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /FD /c +# ADD CPP /nologo /MD /W3 /O2 /I "..\..\include" /I "..\..\os\win32" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "SHARED_MODULE" /Fd"Release\mod_mime_magic" /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x809 /d "NDEBUG" +# ADD RSC /l 0x809 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib /nologo /subsystem:windows /dll /incremental:no /map /machine:I386 /out:"Release/mod_mime_magic.so" /base:@"BaseAddr.ref",mod_mime_magic +# ADD LINK32 kernel32.lib /nologo /subsystem:windows /dll /incremental:no /map /machine:I386 /out:"Release/mod_mime_magic.so" /base:@"BaseAddr.ref",mod_mime_magic + +!ELSEIF "$(CFG)" == "mod_mime_magic - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MDd /W3 /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FD /c +# ADD CPP /nologo /MDd /W3 /GX /Zi /Od /I "..\..\include" /I "..\..\os\win32" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "SHARED_MODULE" /Fd"Debug\mod_mime_magic" /FD /c +# ADD BASE MTL /nologo /D "_DEBUG" /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x809 /d "_DEBUG" +# ADD RSC /l 0x809 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib /nologo /subsystem:windows /dll /incremental:no /map /debug /machine:I386 /out:"Debug/mod_mime_magic.so" /base:@"BaseAddr.ref",mod_mime_magic +# ADD LINK32 kernel32.lib /nologo /subsystem:windows /dll /incremental:no /map /debug /machine:I386 /out:"Debug/mod_mime_magic.so" /base:@"BaseAddr.ref",mod_mime_magic + +!ENDIF + +# Begin Target + +# Name "mod_mime_magic - Win32 Release" +# Name "mod_mime_magic - Win32 Debug" +# Begin Source File + +SOURCE=..\..\modules\standard\mod_mime_magic.c +# End Source File +# End Target +# End Project diff --git a/src/os/win32/mod_mime_magic.mak b/src/os/win32/mod_mime_magic.mak new file mode 100644 index 00000000000..6344ac723ae --- /dev/null +++ b/src/os/win32/mod_mime_magic.mak @@ -0,0 +1,281 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on mod_mime_magic.dsp +!IF "$(CFG)" == "" +CFG=mod_mime_magic - Win32 Release +!MESSAGE No configuration specified. Defaulting to mod_mime_magic - Win32\ + Release. +!ENDIF + +!IF "$(CFG)" != "mod_mime_magic - Win32 Release" && "$(CFG)" !=\ + "mod_mime_magic - Win32 Debug" +!MESSAGE Invalid configuration "$(CFG)" specified. +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "mod_mime_magic.mak" CFG="mod_mime_magic - Win32 Release" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "mod_mime_magic - Win32 Release" (based on\ + "Win32 (x86) Dynamic-Link Library") +!MESSAGE "mod_mime_magic - Win32 Debug" (based on\ + "Win32 (x86) Dynamic-Link Library") +!MESSAGE +!ERROR An invalid configuration is specified. +!ENDIF + +!IF "$(OS)" == "Windows_NT" +NULL= +!ELSE +NULL=nul +!ENDIF + +!IF "$(CFG)" == "mod_mime_magic - Win32 Release" + +OUTDIR=.\Release +INTDIR=.\Release +# Begin Custom Macros +OutDir=.\Release +# End Custom Macros + +!IF "$(RECURSE)" == "0" + +ALL : "$(OUTDIR)\mod_mime_magic.so" + +!ELSE + +ALL : "ApacheCore - Win32 Release" "$(OUTDIR)\mod_mime_magic.so" + +!ENDIF + +!IF "$(RECURSE)" == "1" +CLEAN :"ApacheCore - Win32 ReleaseCLEAN" +!ELSE +CLEAN : +!ENDIF + -@erase "$(INTDIR)\mod_mime_magic.idb" + -@erase "$(INTDIR)\mod_mime_magic.obj" + -@erase "$(OUTDIR)\mod_mime_magic.exp" + -@erase "$(OUTDIR)\mod_mime_magic.lib" + -@erase "$(OUTDIR)\mod_mime_magic.map" + -@erase "$(OUTDIR)\mod_mime_magic.so" + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +CPP=cl.exe +CPP_PROJ=/nologo /MD /W3 /O2 /I "..\..\include" /I "..\..\os\win32" /D "NDEBUG"\ + /D "WIN32" /D "_WINDOWS" /D "SHARED_MODULE" /Fo"$(INTDIR)\\"\ + /Fd"$(INTDIR)\mod_mime_magic" /FD /c +CPP_OBJS=.\Release/ +CPP_SBRS=. + +.c{$(CPP_OBJS)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(CPP_OBJS)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(CPP_OBJS)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.c{$(CPP_SBRS)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(CPP_SBRS)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(CPP_SBRS)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +MTL=midl.exe +MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32 +RSC=rc.exe +BSC32=bscmake.exe +BSC32_FLAGS=/nologo /o"$(OUTDIR)\mod_mime_magic.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +LINK32_FLAGS=kernel32.lib /nologo /subsystem:windows /dll /incremental:no\ + /pdb:"$(OUTDIR)\mod_mime_magic.pdb" /map:"$(INTDIR)\mod_mime_magic.map"\ + /machine:I386 /out:"$(OUTDIR)\mod_mime_magic.so"\ + /implib:"$(OUTDIR)\mod_mime_magic.lib" /base:@"BaseAddr.ref",mod_mime_magic +LINK32_OBJS= \ + "$(INTDIR)\mod_mime_magic.obj" \ + "..\..\Release\ApacheCore.lib" + +"$(OUTDIR)\mod_mime_magic.so" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + +!ELSEIF "$(CFG)" == "mod_mime_magic - Win32 Debug" + +OUTDIR=.\Debug +INTDIR=.\Debug +# Begin Custom Macros +OutDir=.\Debug +# End Custom Macros + +!IF "$(RECURSE)" == "0" + +ALL : "$(OUTDIR)\mod_mime_magic.so" + +!ELSE + +ALL : "ApacheCore - Win32 Debug" "$(OUTDIR)\mod_mime_magic.so" + +!ENDIF + +!IF "$(RECURSE)" == "1" +CLEAN :"ApacheCore - Win32 DebugCLEAN" +!ELSE +CLEAN : +!ENDIF + -@erase "$(INTDIR)\mod_mime_magic.idb" + -@erase "$(INTDIR)\mod_mime_magic.obj" + -@erase "$(OUTDIR)\mod_mime_magic.exp" + -@erase "$(OUTDIR)\mod_mime_magic.lib" + -@erase "$(OUTDIR)\mod_mime_magic.map" + -@erase "$(OUTDIR)\mod_mime_magic.pdb" + -@erase "$(OUTDIR)\mod_mime_magic.so" + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +CPP=cl.exe +CPP_PROJ=/nologo /MDd /W3 /GX /Zi /Od /I "..\..\include" /I "..\..\os\win32" /D\ + "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "SHARED_MODULE" /Fo"$(INTDIR)\\"\ + /Fd"$(INTDIR)\mod_mime_magic" /FD /c +CPP_OBJS=.\Debug/ +CPP_SBRS=. + +.c{$(CPP_OBJS)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(CPP_OBJS)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(CPP_OBJS)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.c{$(CPP_SBRS)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(CPP_SBRS)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(CPP_SBRS)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +MTL=midl.exe +MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32 +RSC=rc.exe +BSC32=bscmake.exe +BSC32_FLAGS=/nologo /o"$(OUTDIR)\mod_mime_magic.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +LINK32_FLAGS=kernel32.lib /nologo /subsystem:windows /dll /incremental:no\ + /pdb:"$(OUTDIR)\mod_mime_magic.pdb" /map:"$(INTDIR)\mod_mime_magic.map" /debug\ + /machine:I386 /out:"$(OUTDIR)\mod_mime_magic.so"\ + /implib:"$(OUTDIR)\mod_mime_magic.lib" /base:@"BaseAddr.ref",mod_mime_magic +LINK32_OBJS= \ + "$(INTDIR)\mod_mime_magic.obj" \ + "..\..\Debug\ApacheCore.lib" + +"$(OUTDIR)\mod_mime_magic.so" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + +!ENDIF + + +!IF "$(CFG)" == "mod_mime_magic - Win32 Release" || "$(CFG)" ==\ + "mod_mime_magic - Win32 Debug" + +!IF "$(CFG)" == "mod_mime_magic - Win32 Release" + +"ApacheCore - Win32 Release" : + cd "\clean\apache-1.3\src" + $(MAKE) /$(MAKEFLAGS) /F ".\ApacheCore.mak" CFG="ApacheCore - Win32 Release"\ + + cd ".\os\win32" + +"ApacheCore - Win32 ReleaseCLEAN" : + cd "\clean\apache-1.3\src" + $(MAKE) /$(MAKEFLAGS) CLEAN /F ".\ApacheCore.mak"\ + CFG="ApacheCore - Win32 Release" RECURSE=1 + cd ".\os\win32" + +!ELSEIF "$(CFG)" == "mod_mime_magic - Win32 Debug" + +"ApacheCore - Win32 Debug" : + cd "\clean\apache-1.3\src" + $(MAKE) /$(MAKEFLAGS) /F ".\ApacheCore.mak" CFG="ApacheCore - Win32 Debug" + cd ".\os\win32" + +"ApacheCore - Win32 DebugCLEAN" : + cd "\clean\apache-1.3\src" + $(MAKE) /$(MAKEFLAGS) CLEAN /F ".\ApacheCore.mak"\ + CFG="ApacheCore - Win32 Debug" RECURSE=1 + cd ".\os\win32" + +!ENDIF + +SOURCE=..\..\modules\standard\mod_mime_magic.c +DEP_CPP_MOD_M=\ + "..\..\include\ap.h"\ + "..\..\include\ap_alloc.h"\ + "..\..\include\ap_config.h"\ + "..\..\include\ap_ctype.h"\ + "..\..\include\ap_ebcdic.h"\ + "..\..\include\ap_mmn.h"\ + "..\..\include\buff.h"\ + "..\..\include\hsregex.h"\ + "..\..\include\http_config.h"\ + "..\..\include\http_core.h"\ + "..\..\include\http_log.h"\ + "..\..\include\http_protocol.h"\ + "..\..\include\http_request.h"\ + "..\..\include\httpd.h"\ + "..\..\include\util_uri.h"\ + ".\os.h"\ + ".\readdir.h"\ + +NODEP_CPP_MOD_M=\ + "..\..\include\ap_config_auto.h"\ + "..\..\include\sfio.h"\ + + +"$(INTDIR)\mod_mime_magic.obj" : $(SOURCE) $(DEP_CPP_MOD_M) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + + +!ENDIF +