]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
* configure: added case for Cygwin to translate shared module
authorMartin Kraemer <martin@apache.org>
Thu, 27 Sep 2001 18:12:04 +0000 (18:12 +0000)
committerMartin Kraemer <martin@apache.org>
Thu, 27 Sep 2001 18:12:04 +0000 (18:12 +0000)
extensions from .so to .dll. Almost the same as for OS2.

* htdocs/manual/cywin.html: added related changes to the configure
and build process for shared module DLLs.

* src/Configure: cleaned up Cygwin case for OS specific variable
declaration. Removed no longer need $DLL_IMPORT_DEF and
$DLL_IMPORT_LIB variables.

* src/Makefile.tmpl: removed no longer needed $DLL_IMPORT_LIB
variable.

* src/main/http_main.c: added dllexport declaration for int REALMAIN
for SHARED_CORE support.

* src/modules/standard/Makefile.Cygwin: added this new file to
reflect the extra rules needed to link the shared module DLLs. Very
similar to src/modules/standard/Makefile.OS2.

* src/os/cygwin/os.h: added explicit dllimport and dllexport
declarations for API_VAR_EXPORT and API_EXPORT(type).

PR:
Obtained from:
Submitted by: Stipe Tolj <tolj@wapme-systems.de>
Reviewed by:

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@91166 13f79535-47bb-0310-9956-ffa450edef68

configure
src/CHANGES
src/Configure
src/Makefile.tmpl
src/main/http_main.c
src/os/cygwin/os.h

index 58d953faee538a51950df29df7d4d41fcc8cd33d..957860dbd2ef315bc480b7cfba5836523cab3948 100755 (executable)
--- a/configure
+++ b/configure
@@ -1537,6 +1537,10 @@ case $PLATFORM in
         echo $SEO "s%/mod_\\(.\\{1,8\\}\\).*\\.so%/\\1\\.dll%" >>$sedsubst
         echo $SEO "s%/\\(lib.*\\)\\.so$%/\\1.dll%" >>$sedsubst
         ;;
+    *cygwin* ) 
+        echo $SEO "s%/\\(mod_.*\\)\\.so$%/\\1.dll%" >>$sedsubst
+        echo $SEO "s%/\\(lib.*\\)\\.so$%/\\1.dll%" >>$sedsubst
+        ;;
 esac
 
 #   split sedsubst into chunks of 50 commands
index f35b6e29a8b2b523ab3649d841ad93915bb31c1e..7783afbbb733265f96620e42614cd623ff4b018d 100644 (file)
@@ -1,5 +1,8 @@
 Changes with Apache 1.3.21
 
+  *) PORT: Some Cygwin changes, esp. improvements for dynamic loading,
+     and cleanups. [Stipe Tolj <tolj@wapme-systems.de>]
+
   *) Win32 SECURITY: The default installation could lead to mod_negotiation
      and mod_dir/mod_autoindex displaying a directory listing instead of
      the index.html.* files, if a very long path was created artificially
@@ -24,8 +27,6 @@ Changes with Apache 1.3.21
   *) mod_proxy - close origin server connection when client aborts
      [Alexey Panchenko <panchenko@liwest.ru>] PR#8067,7383,6585
 
-  *) PORT: Some Cygwin changes. [Stipe Tolj <tolj@wapme-systems.de>]
-
   *) ErrorDocument 404 pointing to a parsed html file with a
      <!--#include virtual="file" --> with a request URI containing
      %2f would result in a segfault (NULL pointer deref, not a
index f5d2a12ac272afa527a078318da31f200c8d067f..64a9bdd8b124f1db324081cc9d887b1817b48e09 100755 (executable)
@@ -1924,12 +1924,6 @@ if [ "x$using_shlib" = "x1" ] ; then
     if [ "x$TCFLAGS_SHLIB" = "x" ]; then
        echo "CFLAGS_SHLIB=$CFLAGS_SHLIB -DSHARED_MODULE" >> Makefile.config
     fi
-    if [ "x$TDLL_IMPORT_DEF" = "x" ]; then
-       echo "DLL_IMPORT_DEF=$DLL_IMPORT_DEF" >> Makefile.config
-    fi
-    if [ "x$TDLL_IMPORT_LIB" = "x" ]; then
-       echo "DLL_IMPORT_LIB=$DLL_IMPORT_LIB" >> Makefile.config
-    fi
     if [ "x$TLD_SHLIB" = "x" ]; then
        echo "LD_SHLIB=$LD_SHLIB" >> Makefile.config
     fi
index 643e8982d84fa7815bc3f04c01bbe2cc87ec59e4..b8aeb09ec9490e6b3c5180e2d64e308ac137147b 100644 (file)
@@ -41,7 +41,7 @@ target_compile_only: subdirs modules.o
 target_shared: $(SHCORE_IMPLIB) $(SHARED_CORE_EP) lib$(TARGET).$(SHLIB_SUFFIX_NAME)
        $(CC) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SHLIB_EXPORT) \
              -o $(TARGET) -DSHARED_CORE_BOOTSTRAP main/http_main.c \
-             ap/libap.a $(LIBS) $(SHCORE_IMPLIB) $(DLL_IMPORT_LIB)
+             ap/libap.a $(LIBS) $(SHCORE_IMPLIB)
 
 lib$(TARGET).ep: lib$(TARGET).$(SHLIB_SUFFIX_NAME)
        $(CC) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SHLIB_EXPORT) \
index 1cc4b8b8662f8beacda9cca6d2bdb3d968412506..91f33e9c70dcc3ae2ddb989542bb1d18f1e45770 100644 (file)
@@ -5137,6 +5137,15 @@ void STANDALONE_MAIN(int argc, char **argv);
 extern char *optarg;
 extern int optind;
 
+/* Cygwin 1.x SHARED_CORE support needs REALMAIN to be declared as dllexport,
+ * so we can later while SHARED_CORE_BOOTSTRAP is compiled and linked see the 
+ * dllimport for it. -- Stipe Tolj <tolj@wapme-systems.de>
+ */
+
+#if defined(CYGWIN)
+__declspec(dllexport)  
+#endif
+
 int REALMAIN(int argc, char *argv[])
 {
     int c;
@@ -7468,6 +7477,7 @@ int main(int argc, char *argv[])
 __declspec(dllimport) 
 #endif
 
+
 int ap_main(int argc, char *argv[]); /* Load time linked from libhttpd.dll */
 
 int main(int argc, char *argv[])
index cce0e96a7fdc863351efde052fd5a181b9e533ab..133d9244e53cc1e15dd1ca070fec1d0545449e96 100644 (file)
 
 #ifndef API_EXPORT
 #ifdef SHARED_CORE
-# define API_EXPORT(type)    __declspec(dllexport) type
+# ifdef SHARED_MODULE
+#  define API_VAR_EXPORT      __declspec(dllimport)
+#  define API_EXPORT(type)    __declspec(dllimport) type
+#  define MODULE_VAR_EXPORT   __declspec(dllexport)
+# else
+#  define API_VAR_EXPORT      __declspec(dllexport)
+#  define API_EXPORT(type)    __declspec(dllexport) type
+# endif /* def SHARED_MODULE */
 #endif /* def SHARED_CORE */ 
 #endif /* ndef API_EXPORT */