Improve meson.build files

FossilOrigin-Name: da6b5c90d4fae43b05b79b391bc53e391ce491867776a1ac3fb84c6de1a57359
This commit is contained in:
Jonathan Schleifer 2024-08-06 21:56:55 +00:00
parent e1c01cfd01
commit cbd238001b
5 changed files with 44 additions and 36 deletions

View file

@ -1,31 +1,22 @@
fs = import('fs')
subdir('exceptions')
sources = files(
'SL3Connection.m',
'SL3PreparedStatement.m',
)
objsqlite3 = library('objsqlite3',
[
'SL3Connection.m',
'SL3PreparedStatement.m',
'exceptions/SL3BindObjectFailedException.m',
'exceptions/SL3ClearBindingsFailedException.m',
'exceptions/SL3Exception.m',
'exceptions/SL3ExecuteStatementFailedException.m',
'exceptions/SL3OpenFailedException.m',
'exceptions/SL3PrepareStatementFailedException.m',
'exceptions/SL3ResetStatementFailedException.m',
],
sources + exceptions_sources,
include_directories: incdir,
objc_args: ['-DSL3_PUBLIC_IVARS'],
dependencies: [objfw_dep, sqlite3_dep],
install: true)
install_headers(
[
'ObjSQLite3.h',
'SL3Connection.h',
'SL3PreparedStatement.h',
'exceptions/SL3BindObjectFailedException.h',
'exceptions/SL3ClearBindingsFailedException.h',
'exceptions/SL3Exception.h',
'exceptions/SL3ExecuteStatementFailedException.h',
'exceptions/SL3OpenFailedException.h',
'exceptions/SL3PrepareStatementFailedException.h',
'exceptions/SL3ResetStatementFailedException.h',
],
subdir: 'ObjSQLite3')
headers = ['ObjSQLite3.h']
foreach source: sources + exceptions_sources
headers += fs.replace_suffix(source.full_path(), '.h')
endforeach
install_headers(headers, subdir: 'ObjSQLite3')