mirror of
				https://github.com/Icinga/icinga2.git
				synced 2025-11-04 05:34:12 +01:00 
			
		
		
		
	Added support for --disable-shared.
This commit is contained in:
		
							parent
							
								
									68039de848
								
							
						
					
					
						commit
						7b03f52e99
					
				@ -7,8 +7,8 @@ SUBDIRS = ltdl \
 | 
			
		||||
	base \
 | 
			
		||||
	jsonrpc \
 | 
			
		||||
	icinga \
 | 
			
		||||
	icinga-app \
 | 
			
		||||
	components
 | 
			
		||||
	components \
 | 
			
		||||
	icinga-app
 | 
			
		||||
 | 
			
		||||
icinga2docdir = ${prefix}/share/doc/icinga2
 | 
			
		||||
icinga2doc_DATA = \
 | 
			
		||||
 | 
			
		||||
@ -38,6 +38,8 @@ Application::Application(void)
 | 
			
		||||
	WSADATA wsaData;
 | 
			
		||||
	WSAStartup(MAKEWORD(1, 1), &wsaData);
 | 
			
		||||
#else /* _WIN32 */
 | 
			
		||||
	LTDL_SET_PRELOADED_SYMBOLS();
 | 
			
		||||
 | 
			
		||||
	lt_dlinit();
 | 
			
		||||
#endif /* _WIN32 */
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -46,8 +46,14 @@ public:
 | 
			
		||||
 | 
			
		||||
typedef Component *(*CreateComponentFunction)(void);
 | 
			
		||||
 | 
			
		||||
#define EXPORT_COMPONENT(klass) \
 | 
			
		||||
	extern "C" I2_EXPORT icinga::Component *CreateComponent(void)	\
 | 
			
		||||
#ifdef _WIN32
 | 
			
		||||
#	define SYM_CREATECOMPONENT(component) CreateComponent
 | 
			
		||||
#else /* _WIN32 */
 | 
			
		||||
#	define SYM_CREATECOMPONENT(component) component ## _LTX_CreateComponent
 | 
			
		||||
#endif /* _WIN32 */
 | 
			
		||||
 | 
			
		||||
#define EXPORT_COMPONENT(component, klass) \
 | 
			
		||||
	extern "C" I2_EXPORT icinga::Component *SYM_CREATECOMPONENT(component)(void) \
 | 
			
		||||
	{								\
 | 
			
		||||
		return new klass();					\
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
@ -104,4 +104,4 @@ void ConfigFileComponent::Stop(void)
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
EXPORT_COMPONENT(ConfigFileComponent);
 | 
			
		||||
EXPORT_COMPONENT(configfile, ConfigFileComponent);
 | 
			
		||||
 | 
			
		||||
@ -225,4 +225,4 @@ int ConfigRpcComponent::RemoteObjectRemovedHandler(const NewRequestEventArgs& ea
 | 
			
		||||
	return 0;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
EXPORT_COMPONENT(ConfigRpcComponent);
 | 
			
		||||
EXPORT_COMPONENT(configrpc, ConfigRpcComponent);
 | 
			
		||||
 | 
			
		||||
@ -102,4 +102,4 @@ int DemoComponent::HelloWorldRequestHandler(const NewRequestEventArgs& nrea)
 | 
			
		||||
	return 0;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
EXPORT_COMPONENT(DemoComponent);
 | 
			
		||||
EXPORT_COMPONENT(demo, DemoComponent);
 | 
			
		||||
 | 
			
		||||
@ -604,4 +604,4 @@ int DiscoveryComponent::DiscoveryTimerHandler(const TimerEventArgs& tea)
 | 
			
		||||
	return 0;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
EXPORT_COMPONENT(DiscoveryComponent);
 | 
			
		||||
EXPORT_COMPONENT(discovery, DiscoveryComponent);
 | 
			
		||||
 | 
			
		||||
@ -36,7 +36,7 @@ fi
 | 
			
		||||
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[#include <openssl/ssl.h>]], []), [], [AC_MSG_ERROR([You need the OpenSSL headers and libraries in order to build this application]) ])
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
LT_INIT([disable-static])
 | 
			
		||||
LT_INIT([dlopen, disable-static])
 | 
			
		||||
LT_CONFIG_LTDL_DIR([ltdl])
 | 
			
		||||
LTDL_INIT
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -17,4 +17,11 @@ icinga_CXXFLAGS = \
 | 
			
		||||
 | 
			
		||||
icinga_LDADD = \
 | 
			
		||||
	${top_builddir}/base/libbase.la \
 | 
			
		||||
	${top_builddir}/icinga/libicinga.la
 | 
			
		||||
	${top_builddir}/icinga/libicinga.la \
 | 
			
		||||
	-dlopen ${top_builddir}/components/configfile/configfile.la \
 | 
			
		||||
	-dlopen ${top_builddir}/components/configrpc/configrpc.la \
 | 
			
		||||
	-dlopen ${top_builddir}/components/demo/demo.la \
 | 
			
		||||
	-dlopen ${top_builddir}/components/discovery/discovery.la
 | 
			
		||||
 | 
			
		||||
icinga_DEPENDENCIES = \
 | 
			
		||||
	${top_builddir}/components/configfile/configfile.la
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user