diff --git a/Data/MySQL/include/Poco/Data/MySQL/Connector.h b/Data/MySQL/include/Poco/Data/MySQL/Connector.h index 6ac80106a..be7a50cd6 100644 --- a/Data/MySQL/include/Poco/Data/MySQL/Connector.h +++ b/Data/MySQL/include/Poco/Data/MySQL/Connector.h @@ -91,7 +91,7 @@ struct MySQL_API MySQLConnectorRegistrator #if !defined(POCO_NO_AUTOMATIC_LIB_INIT) - #if defined(POCO_OS_FAMILY_WINDOWS) + #if defined(POCO_OS_FAMILY_WINDOWS) && !defined(__GNUC__) extern "C" const struct MySQL_API MySQLConnectorRegistrator pocoMySQLConnectorRegistrator; #if defined(MySQL_EXPORTS) #if defined(_WIN64) diff --git a/Data/ODBC/include/Poco/Data/ODBC/Connector.h b/Data/ODBC/include/Poco/Data/ODBC/Connector.h index 71b336af5..a8bc736b6 100644 --- a/Data/ODBC/include/Poco/Data/ODBC/Connector.h +++ b/Data/ODBC/include/Poco/Data/ODBC/Connector.h @@ -102,7 +102,7 @@ struct ODBC_API ODBCConnectorRegistrator #if !defined(POCO_NO_AUTOMATIC_LIB_INIT) - #if defined(POCO_OS_FAMILY_WINDOWS) + #if defined(POCO_OS_FAMILY_WINDOWS) && !defined(__GNUC__) extern "C" const struct ODBC_API ODBCConnectorRegistrator pocoODBCConnectorRegistrator; #if defined(ODBC_EXPORTS) #if defined(_WIN64) diff --git a/Data/SQLite/include/Poco/Data/SQLite/Connector.h b/Data/SQLite/include/Poco/Data/SQLite/Connector.h index ce1fbc3bb..45c7cb03d 100644 --- a/Data/SQLite/include/Poco/Data/SQLite/Connector.h +++ b/Data/SQLite/include/Poco/Data/SQLite/Connector.h @@ -110,7 +110,7 @@ struct SQLite_API SQLiteConnectorRegistrator #if !defined(POCO_NO_AUTOMATIC_LIB_INIT) - #if defined(POCO_OS_FAMILY_WINDOWS) + #if defined(POCO_OS_FAMILY_WINDOWS) && !defined(__GNUC__) extern "C" const struct SQLite_API SQLiteConnectorRegistrator pocoSQLiteConnectorRegistrator; #if defined(SQLite_EXPORTS) #if defined(_WIN64) || defined(_WIN32_WCE) diff --git a/Foundation/Makefile b/Foundation/Makefile index e492adaed..800b22a50 100644 --- a/Foundation/Makefile +++ b/Foundation/Makefile @@ -59,4 +59,8 @@ target = PocoFoundation target_version = $(LIBVERSION) target_libs = +ifeq ($(findstring MinGW, $(POCO_CONFIG)), MinGW) + $(shell cd src; windmc pocomsg.mc) +endif + include $(POCO_BASE)/build/rules/lib diff --git a/Net/Makefile b/Net/Makefile index fa0ab16e9..3068e8ec6 100644 --- a/Net/Makefile +++ b/Net/Makefile @@ -11,7 +11,7 @@ include $(POCO_BASE)/build/rules/global SHAREDOPT_CXX += -DNet_EXPORTS objects = \ - DNS HTTPResponse HostEntry Socket \ + Net DNS HTTPResponse HostEntry Socket \ DatagramSocket HTTPServer IPAddress IPAddressImpl SocketAddress SocketAddressImpl \ HTTPBasicCredentials HTTPCookie HTMLForm MediaType DialogSocket \ DatagramSocketImpl FilePartSource HTTPServerConnection MessageHeader \ diff --git a/Net/include/Poco/Net/Net.h b/Net/include/Poco/Net/Net.h index a7e90564b..c9934c4a9 100644 --- a/Net/include/Poco/Net/Net.h +++ b/Net/include/Poco/Net/Net.h @@ -73,12 +73,12 @@ namespace Poco { namespace Net { -inline void Net_API initializeNetwork(); +void Net_API initializeNetwork(); /// Initialize the network subsystem. /// (Windows only, no-op elsewhere) -inline void Net_API uninitializeNetwork(); +void Net_API uninitializeNetwork(); /// Uninitialize the network subsystem. /// (Windows only, no-op elsewhere) @@ -90,7 +90,7 @@ inline void Net_API uninitializeNetwork(); // Automate network initialization (only relevant on Windows). // -#if defined(POCO_OS_FAMILY_WINDOWS) && !defined(POCO_NO_AUTOMATIC_LIB_INIT) +#if defined(POCO_OS_FAMILY_WINDOWS) && !defined(POCO_NO_AUTOMATIC_LIB_INIT) && !defined(__GNUC__) extern "C" const struct Net_API NetworkInitializer pocoNetworkInitializer; diff --git a/build/config/MinGW b/build/config/MinGW index 91aeecad9..e9e579268 100644 --- a/build/config/MinGW +++ b/build/config/MinGW @@ -3,7 +3,7 @@ # # MinGW32 # -# Make settings for MinGW on WinXP +# Make settings for MinGW32 # # @@ -11,7 +11,7 @@ # LINKMODE = STATIC POCO_TARGET_OSNAME = MinGW -POCO_TARGET_OSARCH = ia32 +POCO_TARGET_OSARCH = i686 # # Define Tools @@ -66,9 +66,9 @@ RELEASEOPT_LINK = -O2 # # System Specific Flags # -SYSFLAGS = -D_WIN32 -DMINGW32 -DWINVER=0x500 -DPOCO_NO_FPENVIRONMENT -DPCRE_STATIC -DPOCO_THREAD_STACK_SIZE -DFoundation_Config_INCLUDED -I/usr/local/include -I/usr/include +SYSFLAGS = -D_WIN32 -DMINGW32 -DWINVER=0x501 -DPOCO_NO_FPENVIRONMENT -DPCRE_STATIC -DPOCO_THREAD_STACK_SIZE -I/usr/local/include -I/usr/include # # System Specific Libraries # -SYSLIBS = -L/usr/local/lib -L/usr/lib -liphlpapi -lws2_32 -lssl -lcrypto -lws2_32 -lgdi32 +SYSLIBS = -L/usr/local/lib -L/usr/lib -liphlpapi -lssl -lcrypto -lws2_32