Skip to content

Commit ec83c4d

Browse files
committed
Fixed some build failures
1 parent 531468e commit ec83c4d

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

meson.build

+4-4
Original file line numberDiff line numberDiff line change
@@ -145,9 +145,9 @@ if get_option('MOD_SDORM_SQL') == true
145145
if not cc.has_header('libpq-fe.h', args : '-I/usr/local/include/postgresql')
146146
if cc.has_header('libpq-fe.h', args : '-I/usr/local/include/pgsql')
147147
pqincpath = '/usr/local/include/pgsql'
148-
else if cc.has_header('libpq-fe.h', args : '-I/opt/homebrew/include/postgresql')
148+
elif cc.has_header('libpq-fe.h', args : '-I/opt/homebrew/include/postgresql')
149149
pqincpath = '/opt/homebrew/include/postgresql'
150-
else if cc.has_header('libpq-fe.h', args : '-I/opt/homebrew/include/pgsql')
150+
elif cc.has_header('libpq-fe.h', args : '-I/opt/homebrew/include/pgsql')
151151
pqincpath = '/opt/homebrew/include/pgsql'
152152
else
153153
error('libpq headers not found')
@@ -189,7 +189,7 @@ if get_option('MOD_SDORM_MONGO') == true
189189
if not cc.has_header('bson.h', args : '-I/usr/include/libbson-1.0')
190190
if cc.has_header('bson.h', args : '-I/usr/local/include/libbson-1.0')
191191
global_includes += ['/usr/local/include/libbson-1.0']
192-
else notif cc.has_header('bson.h', args : '-I/opt/homebrew/include/libbson-1.0')
192+
elif cc.has_header('bson.h', args : '-I/opt/homebrew/include/libbson-1.0')
193193
global_includes += ['/opt/homebrew/include/libbson-1.0']
194194
else
195195
error('bson headers not found')
@@ -200,7 +200,7 @@ if get_option('MOD_SDORM_MONGO') == true
200200
if not cc.has_header('mongoc.h', args : '-I/usr/include/libmongoc-1.0')
201201
if cc.has_header('mongoc.h', args : '-I/usr/local/include/libmongoc-1.0')
202202
global_includes += ['/usr/local/include/libmongoc-1.0']
203-
else notif cc.has_header('mongoc.h', args : '-I/opt/homebrew/include/libmongoc-1.0')
203+
elif cc.has_header('mongoc.h', args : '-I/opt/homebrew/include/libmongoc-1.0')
204204
global_includes += ['/opt/homebrew/include/libmongoc-1.0']
205205
else
206206
error('mongoc headers not found')

sconstruct

+2-2
Original file line numberDiff line numberDiff line change
@@ -170,14 +170,14 @@ if bool(mod_mongo):
170170
if FindFile('bson.h', '/usr/include/libbson-1.0'):
171171
conf.env.Append(CPPPATH=['/usr/include/libbson-1.0'])
172172
conf.env.Append(CPPPATH=['/usr/include/libmongoc-1.0'])
173+
conf.env.Append(CPPDEFINES=['HAVE_BSONLIB', 'HAVE_MONGOCLIB', 'HAVE_BSONINC', 'HAVE_MONGOINC', 'INC_SDORM', 'INC_SDORM_MONGO'])
173174
elif FindFile('bson.h', '/usr/local/include/libbson-1.0'):
174175
conf.env.Append(CPPPATH=['/usr/local/include/libbson-1.0'])
175176
conf.env.Append(CPPPATH=['/usr/local/include/libmongoc-1.0'])
177+
conf.env.Append(CPPDEFINES=['HAVE_BSONLIB', 'HAVE_MONGOCLIB', 'HAVE_BSONINC', 'HAVE_MONGOINC', 'INC_SDORM', 'INC_SDORM_MONGO'])
176178
elif FindFile('bson.h', '/opt/homebrewinclude/libbson-1.0'):
177179
conf.env.Append(CPPPATH=['/opt/homebrew/include/libbson-1.0'])
178180
conf.env.Append(CPPPATH=['/opt/homebrew/include/libmongoc-1.0'])
179-
180-
if oi or li:
181181
conf.env.Append(CPPDEFINES=['HAVE_BSONLIB', 'HAVE_MONGOCLIB', 'HAVE_BSONINC', 'HAVE_MONGOINC', 'INC_SDORM', 'INC_SDORM_MONGO'])
182182
else:
183183
print('Did not find mongo development files!')

0 commit comments

Comments
 (0)