@@ -21,12 +21,14 @@ class OpenDocumentCoreConan(ConanFile):
2121 "fPIC" : [True , False ],
2222 "with_pdf2htmlEX" : [True , False ],
2323 "with_wvWare" : [True , False ],
24+ "with_libmagic" : [True , False ],
2425 }
2526 default_options = {
2627 "shared" : False ,
2728 "fPIC" : True ,
2829 "with_pdf2htmlEX" : True ,
2930 "with_wvWare" : True ,
31+ "with_libmagic" : True ,
3032 }
3133
3234 def config_options (self ):
@@ -36,6 +38,7 @@ def config_options(self):
3638 # But by the time config_options() is executed, default_options is already done parsed.
3739 del self .options .with_pdf2htmlEX
3840 del self .options .with_wvWare
41+ del self .options .with_libmagic
3942
4043 def configure (self ):
4144 if self .options .shared :
@@ -56,6 +59,8 @@ def requirements(self):
5659 self .requires ("pdf2htmlex/0.18.8.rc1-odr-git-eb5d291" )
5760 if self .options .get_safe ("with_wvWare" ):
5861 self .requires ("wvware/1.2.9-odr" )
62+ if self .options .get_safe ("with_libmagic" , False ):
63+ self .requires ("libmagic/5.45" )
5964
6065 def build_requirements (self ):
6166 self .test_requires ("gtest/1.14.0" )
@@ -80,6 +85,7 @@ def generate(self):
8085 tc .variables ["ODR_TEST" ] = False
8186 tc .variables ["WITH_PDF2HTMLEX" ] = self .options .get_safe ("with_pdf2htmlEX" , False )
8287 tc .variables ["WITH_WVWARE" ] = self .options .get_safe ("with_wvWare" , False )
88+ tc .variables ["WITH_LIBMAGIC" ] = self .options .get_safe ("with_libmagic" , False )
8389 tc .generate ()
8490
8591 deps = CMakeDeps (self )
0 commit comments