@ -61,8 +61,6 @@ if(WITH_ANDROIDAPPLICATION)
set ( NEED_EGLCONTEXT 1 )
include_directories ( ${ ANDROID_NATIVE_APP_GLUE_INCLUDE_DIR } )
set ( MagnumAndroidApplication_SRCS
A n d r o i d A p p l i c a t i o n . c p p
I m p l e m e n t a t i o n / E g l . c p p
@ -77,6 +75,7 @@ if(WITH_ANDROIDAPPLICATION)
$ { M a g n u m A n d r o i d A p p l i c a t i o n _ H E A D E R S }
$ { M a g n u m A n d r o i d A p p l i c a t i o n _ P R I V A T E _ H E A D E R S }
$ { A N D R O I D _ N A T I V E _ A P P _ G L U E _ S R C } )
target_include_directories ( MagnumAndroidApplication PUBLIC ${ ANDROID_NATIVE_APP_GLUE_INCLUDE_DIR } )
set_target_properties ( MagnumAndroidApplication PROPERTIES DEBUG_POSTFIX "-d" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
@ -88,8 +87,8 @@ if(WITH_ANDROIDAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m A n d r o i d A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_ANDROIDAPPLICATION_LIBRARY MagnumAndroidApplication CACHE INTERNAL "" )
# M a g n u m A n d r o i d A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::AndroidApplication ALIAS MagnumAndroidApplication )
endif ( )
# G L U T a p p l i c a t i o n
@ -110,7 +109,8 @@ if(WITH_GLUTAPPLICATION)
set_target_properties ( MagnumGlutApplication PROPERTIES DEBUG_POSTFIX "-d" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumGlutApplication Magnum )
target_include_directories ( MagnumGlutApplication PUBLIC ${ GLUT_INCLUDE_DIR } )
target_link_libraries ( MagnumGlutApplication Magnum ${ GLUT_glut_LIBRARY } )
install ( FILES ${ MagnumGlutApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumGlutApplication
@ -118,8 +118,8 @@ if(WITH_GLUTAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m G l u t A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_GLUTAPPLICATION_LIBRARY MagnumGlutApplication CACHE INTERNAL "" )
# M a g n u m G l u t A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::GlutApplication ALIAS MagnumGlutApplication )
endif ( )
# S D L 2 a p p l i c a t i o n
@ -129,8 +129,6 @@ if(WITH_SDL2APPLICATION)
message ( FATAL_ERROR "SDL2 library, required by Sdl2Application, was not found. Set WITH_SDL2APPLICATION to OFF to skip building it." )
endif ( )
include_directories ( ${ SDL2_INCLUDE_DIRS } )
set ( MagnumSdl2Application_SRCS
S d l 2 A p p l i c a t i o n . c p p
$ { M a g n u m S o m e C o n t e x t _ O B J E C T S } )
@ -142,7 +140,7 @@ if(WITH_SDL2APPLICATION)
set_target_properties ( MagnumSdl2Application PROPERTIES DEBUG_POSTFIX "-d" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumSdl2Application Magnum )
target_link_libraries ( MagnumSdl2Application Magnum SDL2::SDL2 )
install ( FILES ${ MagnumSdl2Application_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumSdl2Application
@ -150,8 +148,8 @@ if(WITH_SDL2APPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m S d l 2 A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_SDL2APPLICATION_LIBRARY MagnumSdl2Application CACHE INTERNAL "" )
# M a g n u m S d l 2 A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::Sdl2Application ALIAS MagnumSdl2Application )
endif ( )
# N a C l a p p l i c a t i o n
@ -169,13 +167,16 @@ if(WITH_NACLAPPLICATION)
set_target_properties ( MagnumNaClApplication PROPERTIES DEBUG_POSTFIX "-d" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumNaClApplication Magnum )
target_link_libraries ( MagnumNaClApplication Magnum ppapi_cpp ppapi )
install ( FILES ${ MagnumNaClApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumNaClApplication
R U N T I M E D E S T I N A T I O N $ { M A G N U M _ B I N A R Y _ I N S T A L L _ D I R }
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m N a C l A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::NaClApplication ALIAS MagnumNaClApplication )
endif ( )
# W i n d o w l e s s N a C l a p p l i c a t i o n
@ -191,10 +192,9 @@ if(WITH_WINDOWLESSNACLAPPLICATION)
$ { M a g n u m W i n d o w l e s s N a C l A p p l i c a t i o n _ S R C S }
$ { M a g n u m W i n d o w l e s s N a C l A p p l i c a t i o n _ H E A D E R S } )
set_target_properties ( MagnumWindowlessNaClApplication PROPERTIES DEBUG_POSTFIX "-d" )
target_link_libraries ( MagnumWindowlessNaClApplication Magnum ppapi_cpp ppapi )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumWindowlessNaClApplication Magnum )
target_link_libraries ( MagnumWindowlessNaClApplication Magnum ppapi_cpp ppapi )
install ( FILES ${ MagnumWindowlessNaClApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumWindowlessNaClApplication
@ -202,8 +202,8 @@ if(WITH_WINDOWLESSNACLAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m W i n d o w l e s s N a C l A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_WINDOWLESSNACLAPPLICATION_LIBRARY MagnumWindowlessNaClApplication CACHE INTERNAL "" )
# M a g n u m W i n d o w l e s s N a C l A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::WindowlessNaClApplication ALIAS MagnumWindowlessNaClApplication )
endif ( )
# J a v a S c r i p t a n d C S S s t u f f f o r N a C l
@ -243,7 +243,8 @@ if(WITH_GLXAPPLICATION)
set_target_properties ( MagnumGlxApplication PROPERTIES DEBUG_POSTFIX "-d" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumGlxApplication Magnum )
target_include_directories ( MagnumGlxApplication PUBLIC ${ X11_INCLUDE_DIR } )
target_link_libraries ( MagnumGlxApplication Magnum ${ X11_LIBRARIES } )
install ( FILES ${ MagnumGlxApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumGlxApplication
@ -251,8 +252,8 @@ if(WITH_GLXAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m G l x A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_GLXAPPLICATION_LIBRARY MagnumGlxApplication CACHE INTERNAL "" )
# M a g n u m G l x A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::GlxApplication ALIAS MagnumGlxApplication )
endif ( )
# X / E G L a p p l i c a t i o n
@ -274,7 +275,8 @@ if(WITH_XEGLAPPLICATION)
set_target_properties ( MagnumXEglApplication PROPERTIES DEBUG_POSTFIX "-d" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumXEglApplication Magnum )
target_include_directories ( MagnumXEglApplication PUBLIC ${ X11_INCLUDE_DIR } )
target_link_libraries ( MagnumXEglApplication Magnum ${ X11_LIBRARIES } )
install ( FILES ${ MagnumXEglApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumXEglApplication
@ -282,8 +284,8 @@ if(WITH_XEGLAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m X E g l A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_XEGLAPPLICATION_LIBRARY MagnumXEglApplication CACHE INTERNAL "" )
# M a g n u m X E g l A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::XEglApplication ALIAS MagnumXEglApplication )
endif ( )
if ( WITH_WINDOWLESSGLXAPPLICATION OR NEED_ABSTRACTXAPPLICATION )
@ -306,13 +308,12 @@ if(WITH_WINDOWLESSGLXAPPLICATION)
$ { M a g n u m W i n d o w l e s s G l x A p p l i c a t i o n _ S R C S }
$ { M a g n u m W i n d o w l e s s G l x A p p l i c a t i o n _ H E A D E R S } )
# X 1 1 m a c r o s a r e a m e s s , d i s a b l e w a r n i n g s f o r C - s t y l e c a s t s
set_target_properties ( MagnumWindowlessGlxApplication PROPERTIES
C O M P I L E _ F L A G S " - W n o - o l d - s t y l e - c a s t "
D E B U G _ P O S T F I X " - d " )
target_link_libraries ( MagnumWindowlessGlxApplication Magnum ${ X11_LIBRARIES } )
set_target_properties ( MagnumWindowlessGlxApplication PROPERTIES DEBUG_POSTFIX "-d" )
target_compile_options ( MagnumWindowlessGlxApplication PRIVATE "-Wno-old-style-cast" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumWindowlessGlxApplication Magnum )
target_include_directories ( MagnumWindowlessGlxApplication PUBLIC ${ X11_INCLUDE_DIR } )
target_link_libraries ( MagnumWindowlessGlxApplication Magnum ${ X11_LIBRARIES } )
install ( FILES ${ MagnumWindowlessGlxApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumWindowlessGlxApplication
@ -320,8 +321,8 @@ if(WITH_WINDOWLESSGLXAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m W i n d o w l e s s G l x A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_WINDOWLESSGLXAPPLICATION_LIBRARY MagnumWindowlessGlxApplication CACHE INTERNAL "" )
# M a g n u m W i n d o w l e s s G l x A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::WindowlessGlxApplication ALIAS MagnumWindowlessGlxApplication )
endif ( )
# W i n d o w l e s s W G L a p p l i c a t i o n
@ -336,10 +337,8 @@ if(WITH_WINDOWLESSWGLAPPLICATION)
add_library ( MagnumWindowlessWglApplication STATIC
$ { M a g n u m W i n d o w l e s s W g l A p p l i c a t i o n _ S R C S }
$ { M a g n u m W i n d o w l e s s W g l A p p l i c a t i o n _ H E A D E R S } )
set_target_properties ( MagnumWindowlessWglApplication PROPERTIES
C O M P I L E _ F L A G S " - D U N I C O D E "
D E B U G _ P O S T F I X " - d " )
target_link_libraries ( MagnumWindowlessWglApplication Magnum )
set_target_properties ( MagnumWindowlessWglApplication PROPERTIES DEBUG_POSTFIX "-d" )
target_compile_definitions ( MagnumWindowlessWglApplication PRIVATE "UNICODE" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumWindowlessWglApplication Magnum )
@ -350,8 +349,8 @@ if(WITH_WINDOWLESSWGLAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m W i n d o w l e s s W g l A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_WINDOWLESSWGLAPPLICATION_LIBRARY MagnumWindowlessWglApplication CACHE INTERNAL "" )
# M a g n u m W i n d o w l e s s W g l A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::WindowlessWglApplication ALIAS MagnumWindowlessWglApplication )
endif ( )
# W i n d o w l e s s W i n d o w s / E G L a p p l i c a t i o n
@ -371,13 +370,11 @@ if(WITH_WINDOWLESSWINDOWSEGLAPPLICATION)
$ { M a g n u m W i n d o w l e s s W i n d o w s E g l A p p l i c a t i o n _ S R C S }
$ { M a g n u m W i n d o w l e s s W i n d o w s E g l A p p l i c a t i o n _ H E A D E R S }
$ { M a g n u m W i n d o w l e s s W i n d o w s E g l A p p l i c a t i o n _ P R I V A T E _ H E A D E R S } )
set_target_properties ( MagnumWindowlessWindowsEglApplication PROPERTIES
C O M P I L E _ F L A G S " - D U N I C O D E "
D E B U G _ P O S T F I X " - d " )
target_link_libraries ( MagnumWindowlessWindowsEglApplication Magnum ${ EGL_LIBRARY } )
set_target_properties ( MagnumWindowlessWindowsEglApplication PROPERTIES DEBUG_POSTFIX "-d" )
target_compile_definitions ( MagnumWindowlessWindowsEglApplication PRIVATE "UNICODE" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumWindowlessWindowsEglApplication Magnum )
target_link_libraries ( MagnumWindowlessWindowsEglApplication Magnum EGL::EGL )
install ( FILES ${ MagnumWindowlessWindowsEglApplication_HEADERS } DESTINATION ${ MAGNUM_INCLUDE_INSTALL_DIR } /Platform )
install ( TARGETS MagnumWindowlessWindowsEglApplication
@ -385,8 +382,8 @@ if(WITH_WINDOWLESSWINDOWSEGLAPPLICATION)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m W i n d o w l e s s W i n d o w s E g l A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_WINDOWLESSWINDOWSEGLAPPLICATION_LIBRARY MagnumWindowlessWindowsEglApplication CACHE INTERNAL "" )
# M a g n u m W i n d o w l e s s W i n d o w s E g l A p p l i c a t i o n t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::WindowlessWindowsEglApplication ALIAS MagnumWindowlessWindowsEglApplication )
endif ( )
# W i n d o w l e s s C G L a p p l i c a t i o n
@ -402,7 +399,6 @@ if(WITH_WINDOWLESSCGLAPPLICATION)
$ { M a g n u m W i n d o w l e s s C g l A p p l i c a t i o n _ S R C S }
$ { M a g n u m W i n d o w l e s s C g l A p p l i c a t i o n _ H E A D E R S } )
set_target_properties ( MagnumWindowlessCglApplication PROPERTIES DEBUG_POSTFIX "-d" )
target_link_libraries ( MagnumWindowlessCglApplication Magnum )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
target_link_libraries ( MagnumWindowlessCglApplication Magnum )
@ -414,7 +410,7 @@ if(WITH_WINDOWLESSCGLAPPLICATION)
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m W i n d o w l e s s C g l A p p l i c a t i o n l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_WINDOWLESSCGLAPPLICATION_LIBRARY MagnumWindowlessCglApplication CACHE INTERNAL "" )
add_library ( Magnum::WindowlessCglApplication ALIAS MagnumWindowlessCglApplication )
endif ( )
# A b s t r a c t X a p p l i c a t i o n
@ -425,8 +421,9 @@ if(NEED_ABSTRACTXAPPLICATION)
add_library ( MagnumAbstractXApplication OBJECT
$ { M a g n u m A b s t r a c t X A p p l i c a t i o n _ S R C S }
$ { M a g n u m A b s t r a c t X A p p l i c a t i o n _ H E A D E R S } )
target_include_directories ( MagnumAbstractXApplication PUBLIC $< TARGET_PROPERTY:Magnum,INTERFACE_INCLUDE_DIRECTORIES > )
# X 1 1 m a c r o s a r e a m e s s , d i s a b l e w a r n i n g s f o r C - s t y l e c a s t s
set_target_propertie s( MagnumAbstractXApplication PROPERTIES COMPILE_FLAGS "-Wno-old-style-cast" )
target_compile_option s( MagnumAbstractXApplication PRIVATE "-Wno-old-style-cast" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h e A p p l i c a t i o n l i b i s a l w a y s
# l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e s h a r e d l i b
@ -444,8 +441,9 @@ if(NEED_GLXCONTEXTHANDLER)
add_library ( MagnumGlxContextHandler OBJECT
$ { M a g n u m G l x C o n t e x t H a n d l e r _ S R C S }
$ { M a g n u m G l x C o n t e x t H a n d l e r _ P R I V A T E _ H E A D E R S } )
target_include_directories ( MagnumGlxContextHandler PUBLIC $< TARGET_PROPERTY:Magnum,INTERFACE_INCLUDE_DIRECTORIES > )
# X 1 1 m a c r o s a r e a m e s s , d i s a b l e w a r n i n g s f o r C - s t y l e c a s t s
set_target_properties ( MagnumGlxContextHandler PROPERTIES COMPILE_FLAGS "-Wno-old-style-cast" )
target_compile_options ( MagnumGlxContextHandler PRIVATE "-Wno-old-style-cast" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h i s i s p a r t o f A p p l i c a t i o n l i b ,
# w h i c h i s a l w a y s l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e
# s h a r e d l i b
@ -458,8 +456,6 @@ if(NEED_EGLCONTEXTHANDLER)
message ( FATAL_ERROR "EGL library, required by some contexts, was not found. Set WITH_*EGL*APPLICATION to OFF to skip building them." )
endif ( )
include_directories ( ${ EGL_INCLUDE_DIR } )
set ( MagnumEglContextHandler_SRCS
I m p l e m e n t a t i o n / E g l C o n t e x t H a n d l e r . c p p
I m p l e m e n t a t i o n / E g l . c p p )
@ -471,8 +467,11 @@ if(NEED_EGLCONTEXTHANDLER)
add_library ( MagnumEglContextHandler OBJECT
$ { M a g n u m E g l C o n t e x t H a n d l e r _ S R C S }
$ { M a g n u m E g l C o n t e x t H a n d l e r _ P R I V A T E _ H E A D E R S } )
target_include_directories ( MagnumEglContextHandler PUBLIC
$ < T A R G E T _ P R O P E R T Y : M a g n u m , I N T E R F A C E _ I N C L U D E _ D I R E C T O R I E S >
$ < T A R G E T _ P R O P E R T Y : E G L : : E G L , I N T E R F A C E _ I N C L U D E _ D I R E C T O R I E S > )
# X 1 1 m a c r o s a r e a m e s s , d i s a b l e w a r n i n g s f o r C - s t y l e c a s t s
set_target_properties ( MagnumEglContextHandler PROPERTIES COMPILE_FLAGS "-Wno-old-style-cast" )
target_compile_options ( MagnumEglContextHandler PRIVATE "-Wno-old-style-cast" )
# A s s u m i n g t h a t P I C i s n o t n e e d e d b e c a u s e t h i s i s p a r t o f A p p l i c a t i o n l i b ,
# w h i c h i s a l w a y s l i n k e d t o t h e e x e c u t a b l e a n d n o t t o a n y i n t e r m e d i a t e
# s h a r e d l i b
@ -502,6 +501,7 @@ endif()
# C G L c o n t e x t
if ( NEED_CGLCONTEXT OR WITH_CGLCONTEXT )
add_library ( MagnumCglContextObjects OBJECT ${ MagnumContext_SRCS } )
target_include_directories ( MagnumCglContextObjects PUBLIC $< TARGET_PROPERTY:Magnum,INTERFACE_INCLUDE_DIRECTORIES > )
if ( BUILD_STATIC_PIC )
set_target_properties ( MagnumCglContextObjects PROPERTIES POSITION_INDEPENDENT_CODE ON )
endif ( )
@ -523,8 +523,8 @@ if(NEED_CGLCONTEXT OR WITH_CGLCONTEXT)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m C g l C o n t e x t l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_CGLCONTEXT_LIBRARY MagnumCglContext CACHE INTERNAL "" )
# M a g n u m C g l C o n t e x t t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::CglContext ALIAS MagnumCglContext )
endif ( )
endif ( )
@ -535,10 +535,11 @@ if(NEED_EGLCONTEXT OR WITH_EGLCONTEXT)
message ( FATAL_ERROR "EGL library, required by some contexts, was not found. Set WITH_*APPLICATION and/or WITH_EGLCONTEXT to OFF to skip building them." )
endif ( )
include_directories ( ${ EGL_INCLUDE_DIR } )
add_library ( MagnumEglContextObjects OBJECT ${ MagnumContext_SRCS } )
set_target_properties ( MagnumEglContextObjects PROPERTIES COMPILE_DEFINITIONS "MAGNUM_PLATFORM_USE_EGL" )
target_include_directories ( MagnumEglContextObjects PUBLIC
$ < T A R G E T _ P R O P E R T Y : M a g n u m , I N T E R F A C E _ I N C L U D E _ D I R E C T O R I E S >
$ < T A R G E T _ P R O P E R T Y : E G L : : E G L , I N T E R F A C E _ I N C L U D E _ D I R E C T O R I E S > )
target_compile_definitions ( MagnumEglContextObjects PRIVATE "MAGNUM_PLATFORM_USE_EGL" )
if ( BUILD_STATIC_PIC )
set_target_properties ( MagnumEglContextObjects PROPERTIES POSITION_INDEPENDENT_CODE ON )
endif ( )
@ -550,22 +551,25 @@ if(NEED_EGLCONTEXT OR WITH_EGLCONTEXT)
if ( BUILD_STATIC_PIC )
set_target_properties ( MagnumEglContext PROPERTIES POSITION_INDEPENDENT_CODE ON )
endif ( )
target_link_libraries ( MagnumEglContext Magnum )
target_link_libraries ( MagnumEglContext Magnum EGL::EGL )
install ( TARGETS MagnumEglContext
R U N T I M E D E S T I N A T I O N $ { M A G N U M _ B I N A R Y _ I N S T A L L _ D I R }
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m E g l C o n t e x t l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_EGLCONTEXT_LIBRARY MagnumEglContext CACHE INTERNAL "" )
# M a g n u m E g l C o n t e x t t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::EglContext ALIAS MagnumEglContext )
endif ( )
endif ( )
# G L X c o n t e x t
if ( NEED_GLXCONTEXT OR WITH_GLXCONTEXT )
add_library ( MagnumGlxContextObjects OBJECT ${ MagnumContext_SRCS } )
set_target_properties ( MagnumGlxContextObjects PROPERTIES COMPILE_DEFINITIONS "MAGNUM_PLATFORM_USE_GLX" )
target_include_directories ( MagnumGlxContextObjects PUBLIC
$ < T A R G E T _ P R O P E R T Y : M a g n u m , I N T E R F A C E _ I N C L U D E _ D I R E C T O R I E S >
$ { X 1 1 _ I N C L U D E _ D I R } )
target_compile_definitions ( MagnumGlxContextObjects PRIVATE "MAGNUM_PLATFORM_USE_GLX" )
if ( BUILD_STATIC_PIC )
set_target_properties ( MagnumGlxContextObjects PROPERTIES POSITION_INDEPENDENT_CODE ON )
endif ( )
@ -577,21 +581,23 @@ if(NEED_GLXCONTEXT OR WITH_GLXCONTEXT)
if ( BUILD_STATIC_PIC )
set_target_properties ( MagnumGlxContext PROPERTIES POSITION_INDEPENDENT_CODE ON )
endif ( )
target_link_libraries ( MagnumGlxContext Magnum )
target_include_directories ( MagnumGlxContext PUBLIC ${ X11_INCLUDE_DIR } )
target_link_libraries ( MagnumGlxContext Magnum ${ X11_LIBRARIES } )
install ( TARGETS MagnumGlxContext
R U N T I M E D E S T I N A T I O N $ { M A G N U M _ B I N A R Y _ I N S T A L L _ D I R }
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m G l x C o n t e x t l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_GLXCONTEXT_LIBRARY MagnumGlxContext CACHE INTERNAL "" )
# M a g n u m G l x C o n t e x t t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::GlxContext ALIAS MagnumGlxContext )
endif ( )
endif ( )
# W G L c o n t e x t
if ( NEED_WGLCONTEXT OR WITH_WGLCONTEXT )
add_library ( MagnumWglContextObjects OBJECT ${ MagnumContext_SRCS } )
target_include_directories ( MagnumWglContextObjects PUBLIC $< TARGET_PROPERTY:Magnum,INTERFACE_INCLUDE_DIRECTORIES > )
if ( BUILD_STATIC_PIC )
set_target_properties ( MagnumWglContextObjects PROPERTIES POSITION_INDEPENDENT_CODE ON )
endif ( )
@ -610,14 +616,15 @@ if(NEED_WGLCONTEXT OR WITH_WGLCONTEXT)
L I B R A R Y D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R }
A R C H I V E D E S T I N A T I O N $ { M A G N U M _ L I B R A R Y _ I N S T A L L _ D I R } )
# M a g n u m W g l C o n t e x t l i b r a r y f o r s u p e r p r o j e c t s
set ( MAGNUM_WGLCONTEXT_LIBRARY MagnumWglContext CACHE INTERNAL "" )
# M a g n u m W g l C o n t e x t t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_library ( Magnum::WglContext ALIAS MagnumWglContext )
endif ( )
endif ( )
# M a g n u m I n f o
if ( WITH_MAGNUMINFO )
add_executable ( magnum-info magnum-info.cpp )
target_link_libraries ( magnum-info Magnum )
if ( CORRADE_TARGET_APPLE )
target_link_libraries ( magnum-info MagnumWindowlessCglApplication )
elseif ( CORRADE_TARGET_NACL )
@ -633,7 +640,6 @@ if(WITH_MAGNUMINFO)
else ( )
message ( FATAL_ERROR "magnum-info is not available on this platform. Set WITH_MAGNUMINFO to OFF to skip building it." )
endif ( )
target_link_libraries ( magnum-info Magnum )
install ( TARGETS magnum-info DESTINATION ${ MAGNUM_BINARY_INSTALL_DIR } )
if ( CORRADE_TARGET_NACL )
@ -641,6 +647,9 @@ if(WITH_MAGNUMINFO)
install ( FILES magnum-info-nacl.nmf DESTINATION ${ MAGNUM_DATA_INSTALL_DIR } RENAME magnum-info.nmf )
list ( APPEND MagnumPlatform_FILES magnum-info-nacl.html magnum-info-nacl.nmf )
endif ( )
# M a g n u m i n f o t a r g e t a l i a s f o r s u p e r p r o j e c t s
add_executable ( Magnum::info ALIAS magnum-info )
endif ( )
# F o r c e I D E s d i s p l a y a l s o a l l h e a d e r f i l e s a n d a d d i t i o n a l f i l e s i n p r o j e c t v i e w