fs/io: move to separate library

To eliminate the libio.a dependency.
This commit is contained in:
Max Kellermann 2023-03-06 19:30:31 +01:00
parent e4cdf29951
commit 2c66d90626
5 changed files with 21 additions and 3 deletions

View File

@ -425,6 +425,7 @@ subdir('src/lib/crypto')
subdir('src/zeroconf') subdir('src/zeroconf')
subdir('src/fs') subdir('src/fs')
subdir('src/fs/io')
subdir('src/fs/glue') subdir('src/fs/glue')
subdir('src/config') subdir('src/config')
subdir('src/tag') subdir('src/tag')

View File

@ -5,6 +5,7 @@ fs_glue = static_library(
include_directories: inc, include_directories: inc,
dependencies: [ dependencies: [
fs_dep, fs_dep,
fs_io_dep,
fmt_dep, fmt_dep,
log_dep, log_dep,
util_dep, util_dep,

18
src/fs/io/meson.build Normal file
View File

@ -0,0 +1,18 @@
fs_io = static_library(
'fs_io',
'TextFile.cxx',
include_directories: inc,
dependencies: [
fs_dep,
io_dep,
system_dep,
zlib_dep,
],
)
fs_io_dep = declare_dependency(
link_with: fs_io,
dependencies: [
io_dep,
],
)

View File

@ -12,7 +12,6 @@ fs_sources = [
'List.cxx', 'List.cxx',
'LookupFile.cxx', 'LookupFile.cxx',
'DirectoryReader.cxx', 'DirectoryReader.cxx',
'io/TextFile.cxx',
] ]
if is_windows if is_windows
@ -26,7 +25,6 @@ fs = static_library(
fs_sources, fs_sources,
include_directories: inc, include_directories: inc,
dependencies: [ dependencies: [
zlib_dep,
shlwapi_dep, shlwapi_dep,
system_dep, system_dep,
icu_dep, icu_dep,
@ -36,6 +34,5 @@ fs = static_library(
fs_dep = declare_dependency( fs_dep = declare_dependency(
link_with: fs, link_with: fs,
dependencies: [ dependencies: [
io_dep,
], ],
) )

View File

@ -177,6 +177,7 @@ if zlib_dep.found()
include_directories: inc, include_directories: inc,
dependencies: [ dependencies: [
fs_dep, fs_dep,
zlib_dep,
], ],
) )
endif endif