mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 23:05:04 +01:00
reverse the visibility.h files assumptions that we don't build shared libs by default
This avoids having to define define LIBFOO_DLL=1 all over the place. If we ever go with static libs we will need to define LIBFOO_STATIC=1 but hopefully in some central location like the top level wscript. Oh, and I also dropped support for gcc older than version 4.x because ardour will already not build on such an old version.
This commit is contained in:
parent
683496c501
commit
f85c67501c
26 changed files with 89 additions and 183 deletions
|
|
@ -407,19 +407,6 @@ def build(bld):
|
|||
obj.includes = ['.']
|
||||
obj.defines = []
|
||||
|
||||
# if our internal libraries are built as DLL's, define
|
||||
# the macros that activate the right stuff in headers
|
||||
# for export/visibility to work on all platforms.
|
||||
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBPBD_DLL=1',
|
||||
'LIBARDOUR_DLL=1',
|
||||
'LIBMIDIPP_DLL=1',
|
||||
'LIBARDOUR_DLL=1',
|
||||
'LIBARDOUR_CP_DLL=1',
|
||||
'LIBGTKMM2EXT_DLL=1',
|
||||
'LIBEVORAL_DLL=1',
|
||||
]
|
||||
# continue with setup of obj, which could be a shared library
|
||||
# or an executable.
|
||||
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBARDOUR_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBARDOUR_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBARDOUR_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBARDOUR_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBARDOUR_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBARDOUR_DLL_IMPORT
|
||||
#define LIBARDOUR_DLL_EXPORT
|
||||
#define LIBARDOUR_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBARDOUR_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBARDOUR_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBARDOUR_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBARDOUR_DLL // libardour is a DLL
|
||||
#ifdef LIBARDOUR_DLL_EXPORTS // defined if we are building the libardour DLL (instead of using it)
|
||||
#define LIBARDOUR_API LIBARDOUR_DLL_EXPORT
|
||||
#else
|
||||
#define LIBARDOUR_API LIBARDOUR_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBARDOUR_LOCAL LIBARDOUR_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#ifdef LIBARDOUR_STATIC // libardour is not a DLL
|
||||
#define LIBARDOUR_API
|
||||
#define LIBARDOUR_LOCAL
|
||||
#else
|
||||
#ifdef LIBARDOUR_DLL_EXPORTS // defined if we are building the libardour DLL (instead of using it)
|
||||
#define LIBARDOUR_API LIBARDOUR_DLL_EXPORT
|
||||
#else
|
||||
#define LIBARDOUR_API LIBARDOUR_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBARDOUR_LOCAL LIBARDOUR_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libardour_libardour_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -26,19 +26,13 @@
|
|||
*/
|
||||
|
||||
#if defined _WIN32 || defined __CYGWIN__ || defined(COMPILER_MSVC) || defined(COMPILER_MINGW)
|
||||
#define LIBARDOUR_HELPER_DLL_IMPORT __declspec(dllimport)
|
||||
#define LIBARDOUR_HELPER_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBARDOUR_HELPER_DLL_LOCAL
|
||||
#define LIBARDOUR_HELPER_DLL_IMPORT __declspec(dllimport)
|
||||
#define LIBARDOUR_HELPER_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBARDOUR_HELPER_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBARDOUR_HELPER_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBARDOUR_HELPER_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBARDOUR_HELPER_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBARDOUR_HELPER_DLL_IMPORT
|
||||
#define LIBARDOUR_HELPER_DLL_EXPORT
|
||||
#define LIBARDOUR_HELPER_DLL_LOCAL
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif /* __libardour_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -323,9 +323,7 @@ def build(bld):
|
|||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj = bld.shlib(features = 'c cxx cshlib cxxshlib', source=libardour_sources)
|
||||
# macros for this shared library
|
||||
obj.defines = [ 'LIBARDOUR_DLL=1', 'LIBARDOUR_DLL_EXPORTS=1' ]
|
||||
# macros for this other internal shared libraries that we use
|
||||
obj.defines += [ 'LIBEVORAL_DLL=1', 'LIBMIDIPP_DLL=1', 'LIBPBD_DLL=1' ]
|
||||
obj.defines = [ 'LIBARDOUR_DLL_EXPORTS=1' ]
|
||||
obj.cflags = [ '-fvisibility=hidden' ]
|
||||
obj.cxxflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBAUDIOGRAPHER_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBAUDIOGRAPHER_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBAUDIOGRAPHER_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBAUDIOGRAPHER_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBAUDIOGRAPHER_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBAUDIOGRAPHER_DLL_IMPORT
|
||||
#define LIBAUDIOGRAPHER_DLL_EXPORT
|
||||
#define LIBAUDIOGRAPHER_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBAUDIOGRAPHER_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBAUDIOGRAPHER_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBAUDIOGRAPHER_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBAUDIOGRAPHER_DLL // libaudiographer is a DLL
|
||||
#ifdef LIBAUDIOGRAPHER_DLL_EXPORTS // defined if we are building the libaudiographer DLL (instead of using it)
|
||||
#define LIBAUDIOGRAPHER_API LIBAUDIOGRAPHER_DLL_EXPORT
|
||||
#ifdef LIBAUDIOGRAPHER_STATIC // libaudiographer is not a DLL
|
||||
#define LIBAUDIOGRAPHER_API
|
||||
#define LIBAUDIOGRAPHER_LOCAL
|
||||
#else
|
||||
#ifdef LIBAUDIOGRAPHER_DLL_EXPORTS // defined if we are building the libaudiographer DLL (instead of using it)
|
||||
#define LIBAUDIOGRAPHER_API LIBAUDIOGRAPHER_DLL_EXPORT
|
||||
#else
|
||||
#define LIBAUDIOGRAPHER_API LIBAUDIOGRAPHER_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBAUDIOGRAPHER_LOCAL LIBAUDIOGRAPHER_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#define LIBAUDIOGRAPHER_API
|
||||
#define LIBAUDIOGRAPHER_LOCAL
|
||||
#endif
|
||||
#define LIBAUDIOGRAPHER_LOCAL LIBAUDIOGRAPHER_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libaudiographer_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -67,9 +67,7 @@ def build(bld):
|
|||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
audiographer = bld.shlib(features = 'c cxx cshlib cxxshlib', source=audiographer_sources)
|
||||
# macros for this shared library
|
||||
audiographer.defines = [ 'LIBAUDIOGRAPHER_DLL=1', 'LIBAUDIOGRAPHER_DLL_EXPORTS=1' ]
|
||||
# macros for this other internal shared libraries that we use
|
||||
audiographer.defines += [ 'LIBPBD_DLL=1' ]
|
||||
audiographer.defines = [ 'LIBAUDIOGRAPHER_DLL_EXPORTS=1' ]
|
||||
audiographer.cflags = [ '-fvisibility=hidden' ]
|
||||
audiographer.cxxflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -42,8 +42,6 @@ def build(bld):
|
|||
obj.defines = ['PACKAGE="' + I18N_PACKAGE + '"',
|
||||
'ARDOURBACKEND_DLL_EXPORTS'
|
||||
]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBPBD_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
|
||||
#
|
||||
# device discovery code in the jack backend needs ALSA
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBEVORAL_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBEVORAL_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBEVORAL_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBEVORAL_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBEVORAL_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBEVORAL_DLL_IMPORT
|
||||
#define LIBEVORAL_DLL_EXPORT
|
||||
#define LIBEVORAL_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBEVORAL_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBEVORAL_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBEVORAL_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBEVORAL_DLL // libevoral is a DLL
|
||||
#ifdef LIBEVORAL_DLL_EXPORTS // defined if we are building the libevoral DLL (instead of using it)
|
||||
#define LIBEVORAL_API LIBEVORAL_DLL_EXPORT
|
||||
#ifdef LIBEVORAL_STATIC // libevoral is not a DLL
|
||||
#define LIBEVORAL_API
|
||||
#define LIBEVORAL_LOCAL
|
||||
#else
|
||||
#ifdef LIBEVORAL_DLL_EXPORTS // defined if we are building the libevoral DLL (instead of using it)
|
||||
#define LIBEVORAL_API LIBEVORAL_DLL_EXPORT
|
||||
#else
|
||||
#define LIBEVORAL_API LIBEVORAL_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBEVORAL_LOCAL LIBEVORAL_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#define LIBEVORAL_API
|
||||
#define LIBEVORAL_LOCAL
|
||||
#endif
|
||||
#define LIBEVORAL_LOCAL LIBEVORAL_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libevoral_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -91,9 +91,7 @@ def build(bld):
|
|||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj = bld.shlib(features = 'c cxx cshlib cxxshlib', source=lib_source)
|
||||
# DLL exports for this library
|
||||
obj.defines = [ 'LIBEVORAL_DLL=1', 'LIBEVORAL_DLL_EXPORTS=1' ]
|
||||
# DLL imports for other libraries
|
||||
obj.defines += [ 'LIBPBD_DLL=1' ]
|
||||
obj.defines = [ 'LIBEVORAL_DLL_EXPORTS=1' ]
|
||||
obj.cxxflags = [ '-fvisibility=hidden' ]
|
||||
obj.cflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBGTKMM2EXT_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBGTKMM2EXT_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBGTKMM2EXT_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBGTKMM2EXT_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBGTKMM2EXT_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBGTKMM2EXT_DLL_IMPORT
|
||||
#define LIBGTKMM2EXT_DLL_EXPORT
|
||||
#define LIBGTKMM2EXT_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBGTKMM2EXT_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBGTKMM2EXT_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBGTKMM2EXT_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBGTKMM2EXT_DLL // libgtkmm2ext is a DLL
|
||||
#ifdef LIBGTKMM2EXT_DLL_EXPORTS // defined if we are building the libgtkmm2ext DLL (instead of using it)
|
||||
#define LIBGTKMM2EXT_API LIBGTKMM2EXT_DLL_EXPORT
|
||||
#ifdef LIBGTKMM2EXT_STATIC // libgtkmm2ext is a DLL
|
||||
#define LIBGTKMM2EXT_API
|
||||
#define LIBGTKMM2EXT_LOCAL
|
||||
#else
|
||||
#define LIBGTKMM2EXT_API LIBGTKMM2EXT_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBGTKMM2EXT_LOCAL LIBGTKMM2EXT_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#define LIBGTKMM2EXT_API
|
||||
#define LIBGTKMM2EXT_LOCAL
|
||||
#ifdef LIBGTKMM2EXT_DLL_EXPORTS // defined if we are building the libgtkmm2ext DLL (instead of using it)
|
||||
#define LIBGTKMM2EXT_API LIBGTKMM2EXT_DLL_EXPORT
|
||||
#else
|
||||
#define LIBGTKMM2EXT_API LIBGTKMM2EXT_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBGTKMM2EXT_LOCAL LIBGTKMM2EXT_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libgtkmm2ext_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -87,9 +87,7 @@ def build(bld):
|
|||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj = bld.shlib(features = 'c cxx cshlib cxxshlib', source=gtkmm2ext_sources)
|
||||
# defines for this library
|
||||
obj.defines = [ 'LIBGTKMM2EXT_DLL=1', 'LIBGTKMM2EXT_DLL_EXPORTS=1' ]
|
||||
# internal shared libs that we use
|
||||
obj.defines += [ 'LIBPBD_DLL=1' ]
|
||||
obj.defines = [ 'LIBGTKMM2EXT_DLL_EXPORTS=1' ]
|
||||
obj.cxxflags = [ '-fvisibility=hidden' ]
|
||||
obj.cflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBMIDIPP_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBMIDIPP_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBMIDIPP_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBMIDIPP_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBMIDIPP_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBMIDIPP_DLL_IMPORT
|
||||
#define LIBMIDIPP_DLL_EXPORT
|
||||
#define LIBMIDIPP_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBMIDIPP_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBMIDIPP_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBMIDIPP_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBMIDIPP_DLL // libmidi is a DLL
|
||||
#ifdef LIBMIDIPP_DLL_EXPORTS // defined if we are building the libmidi DLL (instead of using it)
|
||||
#define LIBMIDIPP_API LIBMIDIPP_DLL_EXPORT
|
||||
#ifdef LIBMIDIPP_STATIC // libmidi is not a DLL
|
||||
#define LIBMIDIPP_API
|
||||
#define LIBMIDIPP_LOCAL
|
||||
#else
|
||||
#define LIBMIDIPP_API LIBMIDIPP_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBMIDIPP_LOCAL LIBMIDIPP_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#define LIBMIDIPP_API
|
||||
#define LIBMIDIPP_LOCAL
|
||||
#ifdef LIBMIDIPP_DLL_EXPORTS // defined if we are building the libmidi DLL (instead of using it)
|
||||
#define LIBMIDIPP_API LIBMIDIPP_DLL_EXPORT
|
||||
#else
|
||||
#define LIBMIDIPP_API LIBMIDIPP_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBMIDIPP_LOCAL LIBMIDIPP_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libmidi_libmidi_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -62,8 +62,7 @@ def build(bld):
|
|||
# Library
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj = bld.shlib(features = 'cxx cxxshlib', source=libmidi_sources)
|
||||
obj.defines = [ 'LIBMIDIPP_DLL=1', 'LIBMIDIPP_DLL_EXPORTS=1' ]
|
||||
obj.defines += [ 'LIBPBD_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.defines = [ 'LIBMIDIPP_DLL_EXPORTS=1' ]
|
||||
obj.cxxflags = [ '-fvisibility=hidden' ]
|
||||
obj.cflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -23,8 +23,6 @@ def build(bld):
|
|||
obj.source = [ 'panner_1in2out.cc' ]
|
||||
obj.export_includes = ['.']
|
||||
obj.defines = [ 'PACKAGE="libardour_pan1in2out"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBPBD_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.includes = ['.']
|
||||
obj.name = 'libardour_pan1in2out'
|
||||
obj.target = 'pan1in2out'
|
||||
|
|
|
|||
|
|
@ -23,8 +23,6 @@ def build(bld):
|
|||
obj.source = [ 'panner_2in2out.cc' ]
|
||||
obj.export_includes = ['.']
|
||||
obj.defines = [ 'PACKAGE="libardour_pan2in2out"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBPBD_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.includes = ['.']
|
||||
obj.name = 'libardour_pan2in2out'
|
||||
obj.target = 'pan2in2out'
|
||||
|
|
|
|||
|
|
@ -23,8 +23,6 @@ def build(bld):
|
|||
obj.source = [ 'vbap_speakers.cc', 'vbap.cc' ]
|
||||
obj.export_includes = ['.']
|
||||
obj.defines = [ 'PACKAGE="libardour_panvbap"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL_=1', 'LIBPBD_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.includes = ['.']
|
||||
obj.name = 'libardour_panvbap'
|
||||
obj.target = 'panvbap'
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBPBD_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBPBD_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBPBD_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBPBD_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBPBD_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBPBD_DLL_IMPORT
|
||||
#define LIBPBD_DLL_EXPORT
|
||||
#define LIBPBD_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBPBD_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBPBD_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBPBD_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBPBD_DLL // libpbd is a DLL
|
||||
#ifdef LIBPBD_DLL_EXPORTS // defined if we are building the libpbd DLL (instead of using it)
|
||||
#define LIBPBD_API LIBPBD_DLL_EXPORT
|
||||
#ifdef LIBPBD_STATIC // libpbd is a DLL
|
||||
#define LIBPBD_API
|
||||
#define LIBPBD_LOCAL
|
||||
#else
|
||||
#ifdef LIBPBD_DLL_EXPORTS // defined if we are building the libpbd DLL (instead of using it)
|
||||
#define LIBPBD_API LIBPBD_DLL_EXPORT
|
||||
#else
|
||||
#define LIBPBD_API LIBPBD_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBPBD_LOCAL LIBPBD_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#define LIBPBD_API
|
||||
#define LIBPBD_LOCAL
|
||||
#endif
|
||||
#define LIBPBD_LOCAL LIBPBD_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libpbd_libpbd_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -114,9 +114,7 @@ def build(bld):
|
|||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
print('BUILD SHARED LIB')
|
||||
obj = bld.shlib(features = 'cxx cxxshlib', source=libpbd_sources)
|
||||
obj.defines = [ 'LIBPBD_DLL=1',
|
||||
'LIBPBD_DLL_EXPORTS=1'
|
||||
]
|
||||
obj.defines = [ 'LIBPBD_DLL_EXPORTS=1' ]
|
||||
obj.cxxflags = [ '-fvisibility=hidden' ]
|
||||
obj.cflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -30,27 +30,21 @@
|
|||
#define LIBCONTROLCP_DLL_EXPORT __declspec(dllexport)
|
||||
#define LIBCONTROLCP_DLL_LOCAL
|
||||
#else
|
||||
#if __GNUC__ >= 4
|
||||
#define LIBCONTROLCP_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBCONTROLCP_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBCONTROLCP_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#else
|
||||
#define LIBCONTROLCP_DLL_IMPORT
|
||||
#define LIBCONTROLCP_DLL_EXPORT
|
||||
#define LIBCONTROLCP_DLL_LOCAL
|
||||
#endif
|
||||
#define LIBCONTROLCP_DLL_IMPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBCONTROLCP_DLL_EXPORT __attribute__ ((visibility ("default")))
|
||||
#define LIBCONTROLCP_DLL_LOCAL __attribute__ ((visibility ("hidden")))
|
||||
#endif
|
||||
|
||||
#ifdef LIBCONTROLCP_DLL // libcontrolcp is a DLL
|
||||
#ifdef LIBCONTROLCP_DLL_EXPORTS // defined if we are building the libcontrolcp DLL (instead of using it)
|
||||
#define LIBCONTROLCP_API LIBCONTROLCP_DLL_EXPORT
|
||||
#ifdef LIBCONTROLCP_STATIC // libcontrolcp is not a DLL
|
||||
#define LIBCONTROLCP_API
|
||||
#define LIBCONTROLCP_LOCAL
|
||||
#else
|
||||
#ifdef LIBCONTROLCP_DLL_EXPORTS // defined if we are building the libcontrolcp DLL (instead of using it)
|
||||
#define LIBCONTROLCP_API LIBCONTROLCP_DLL_EXPORT
|
||||
#else
|
||||
#define LIBCONTROLCP_API LIBCONTROLCP_DLL_IMPORT
|
||||
#endif
|
||||
#define LIBCONTROLCP_LOCAL LIBCONTROLCP_DLL_LOCAL
|
||||
#else /* static lib, not DLL */
|
||||
#define LIBCONTROLCP_API
|
||||
#define LIBCONTROLCP_LOCAL
|
||||
#endif
|
||||
#define LIBCONTROLCP_LOCAL LIBCONTROLCP_DLL_LOCAL
|
||||
#endif
|
||||
|
||||
#endif /* __libcontrolcp_visibility_h__ */
|
||||
|
|
|
|||
|
|
@ -28,9 +28,7 @@ def build(bld):
|
|||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj = bld.shlib(features = 'c cxx cshlib cxxshlib', source=controlcp_sources)
|
||||
# defines for this library
|
||||
obj.defines = [ 'LIBCONTROLCP_DLL=1', 'LIBCONTROLCP_DLL_EXPORTS=1' ]
|
||||
# internal shared libs that we use
|
||||
obj.defines += [ 'LIBPBD_DLL=1', 'LIBARDOUR_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.defines = [ 'LIBCONTROLCP_DLL_EXPORTS=1' ]
|
||||
obj.cxxflags = [ '-fvisibility=hidden' ]
|
||||
obj.cflags = [ '-fvisibility=hidden' ]
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -35,8 +35,6 @@ def build(bld):
|
|||
'''
|
||||
obj.export_includes = ['./generic_midi']
|
||||
obj.defines = [ 'PACKAGE="ardour_frontier"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL=1', 'LIBPBD_DLL=1' ]
|
||||
obj.includes = ['.', './generic_midi']
|
||||
obj.name = 'libgeneric_midi'
|
||||
obj.target = 'generic_midi'
|
||||
|
|
|
|||
|
|
@ -31,8 +31,6 @@ def build(bld):
|
|||
'''
|
||||
obj.export_includes = ['.']
|
||||
obj.defines = [ 'PACKAGE="ardour_genericmidi"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL=1', 'LIBPBD_DLL=1', 'LIBGTKMM2EXT_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.includes = ['.', './generic_midi']
|
||||
obj.name = 'libardour_generic_midi'
|
||||
obj.target = 'ardour_generic_midi'
|
||||
|
|
|
|||
|
|
@ -43,8 +43,6 @@ def build(bld):
|
|||
'''
|
||||
obj.export_includes = ['./mackie']
|
||||
obj.defines = [ 'PACKAGE="ardour_mackie"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL=1', 'LIBPBD_DLL=1', 'LIBGTKMM2EXT_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
# need ../libs because some GTK2 header files require stuff there
|
||||
obj.includes = ['.', '../libs']
|
||||
obj.name = 'libardour_mcp'
|
||||
|
|
|
|||
|
|
@ -28,8 +28,6 @@ def build(bld):
|
|||
'''
|
||||
obj.export_includes = ['.']
|
||||
obj.defines = [ 'PACKAGE="ardour_osc"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL=1', 'LIBPBD_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.includes = ['.', './osc']
|
||||
obj.name = 'libardour_osc'
|
||||
obj.target = 'ardour_osc'
|
||||
|
|
|
|||
|
|
@ -40,8 +40,6 @@ def build(bld):
|
|||
'''
|
||||
obj.export_includes = ['./tranzport']
|
||||
obj.defines = [ 'PACKAGE="ardour_tranzport"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL=1', 'LIBPBD_DLL=1', 'LIBGTKMM2EXT_DLL=1' ]
|
||||
obj.includes = ['.', './tranzport']
|
||||
obj.name = 'libardour_tranzport'
|
||||
obj.target = 'ardour_tranzport'
|
||||
|
|
|
|||
|
|
@ -26,8 +26,6 @@ def build(bld):
|
|||
'''
|
||||
obj.export_includes = ['./wiimote']
|
||||
obj.defines = [ 'PACKAGE="ardour_wiimote"' ]
|
||||
if bld.is_defined ('INTERNAL_SHARED_LIBS'):
|
||||
obj.defines += [ 'LIBARDOUR_DLL=1', 'LIBCONTROLCP_DLL=1', 'LIBPBD_DLL=1', 'LIBGTKMM2EXT_DLL=1', 'LIBEVORAL_DLL=1' ]
|
||||
obj.includes = ['.', '../libs']
|
||||
obj.name = 'libardour_wiimote'
|
||||
obj.target = 'ardour_wiimote'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue