Skip to content

Commit df15a77

Browse files
Merge branch 'matthias_setuppy' into 'master'
Add ql build include dir to include the autogenerated headers See merge request qs/oreswig!31
2 parents 7c855ad + 0dae409 commit df15a77

1 file changed

Lines changed: 11 additions & 4 deletions

File tree

OREAnalytics-SWIG/Python/setup.py

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -137,17 +137,24 @@ def finalize_options(self):
137137

138138
# ADD INCLUDE DIRECTORIES
139139
self.include_dirs.append(self.validate_path(BOOST_DIR))
140+
self.include_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'QuantLib')))
140141
self.include_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'QuantLib')))
141142
self.include_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'QuantExt')))
142143
self.include_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'OREData')))
143144
self.include_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'OREAnalytics')))
144145

145146
# ADD LIBRARY DIRECTORIES
147+
148+
target = "Release"
149+
150+
if self.debug:
151+
target = "Debug"
152+
146153
self.library_dirs.append(self.validate_path(BOOST_LIB))
147-
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'QuantLib', 'ql', 'Release')))
148-
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'QuantExt', 'qle', 'Release')))
149-
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'OREData', 'ored', 'Release')))
150-
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'OREAnalytics', 'orea', 'Release')))
154+
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'QuantLib', 'ql', target)))
155+
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'QuantExt', 'qle', target)))
156+
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'OREData', 'ored', target)))
157+
self.library_dirs.append(self.validate_path(os.path.join(ORE_DIR, 'build', 'OREAnalytics', 'orea', target)))
151158

152159
#if 'INCLUDE' in os.environ:
153160
# dirs = [dir for dir in os.environ['INCLUDE'].split(';')]

0 commit comments

Comments
 (0)