| 1 |
libv4lconvert_sources = files( |
| 2 |
'bayer.c', |
| 3 |
'control/libv4lcontrol-priv.h', |
| 4 |
'control/libv4lcontrol.c', |
| 5 |
'control/libv4lcontrol.h', |
| 6 |
'cpia1.c', |
| 7 |
'crop.c', |
| 8 |
'flip.c', |
| 9 |
'helper-funcs.h', |
| 10 |
'jidctflt.c', |
| 11 |
'jl2005bcd.c', |
| 12 |
'jpeg.c', |
| 13 |
'jpgl.c', |
| 14 |
'libv4lconvert-priv.h', |
| 15 |
'libv4lconvert.c', |
| 16 |
'libv4lsyscall-priv.h', |
| 17 |
'mr97310a.c', |
| 18 |
'nv12_16l16.c', |
| 19 |
'pac207.c', |
| 20 |
'processing/autogain.c', |
| 21 |
'processing/gamma.c', |
| 22 |
'processing/libv4lprocessing-priv.h', |
| 23 |
'processing/libv4lprocessing.c', |
| 24 |
'processing/libv4lprocessing.h', |
| 25 |
'processing/whitebalance.c', |
| 26 |
'rgbyuv.c', |
| 27 |
'se401.c', |
| 28 |
'sn9c10x.c', |
| 29 |
'sn9c2028-decomp.c', |
| 30 |
'sn9c20x.c', |
| 31 |
'spca501.c', |
| 32 |
'spca561-decompress.c', |
| 33 |
'sq905c.c', |
| 34 |
'stv0680.c', |
| 35 |
'tinyjpeg-internal.h', |
| 36 |
'tinyjpeg.c', |
| 37 |
'tinyjpeg.h', |
| 38 |
) |
| 39 |
|
| 40 |
libv4lconvert_api = files( |
| 41 |
'../include/libv4lconvert.h', |
| 42 |
) |
| 43 |
|
| 44 |
install_headers(libv4lconvert_api) |
| 45 |
|
| 46 |
libv4lconvert_deps = [ |
| 47 |
dep_libm, |
| 48 |
dep_librt, |
| 49 |
] |
| 50 |
|
| 51 |
libv4lconvert_priv_libs = [ |
| 52 |
'-lm', |
| 53 |
'-lrt', |
| 54 |
] |
| 55 |
|
| 56 |
libv4lconvertprivdir = get_option('prefix') / get_option('libdir') / get_option('libv4lconvertsubdir') |
| 57 |
|
| 58 |
libv4lconvert_c_args = ['-DLIBV4LCONVERT_PRIV_DIR="@0@"'.format(libv4lconvertprivdir)] |
| 59 |
|
| 60 |
if dep_jpeg.found() |
| 61 |
libv4lconvert_deps += dep_jpeg |
| 62 |
libv4lconvert_priv_libs += dep_jpeg_priv_libs |
| 63 |
libv4lconvert_sources += files( |
| 64 |
'jpeg_memsrcdest.c', |
| 65 |
'jpeg_memsrcdest.h' |
| 66 |
) |
| 67 |
libv4lconvert_c_args += [ |
| 68 |
'-DHAVE_JPEG', |
| 69 |
] |
| 70 |
endif |
| 71 |
|
| 72 |
if have_fork |
| 73 |
libv4lconvert_sources += files( |
| 74 |
'helper.c', |
| 75 |
) |
| 76 |
ov511_decomp_sources = files( |
| 77 |
'ov511-decomp.c', |
| 78 |
) |
| 79 |
ov511_decomp = executable('ov511-decomp', |
| 80 |
ov511_decomp_sources, |
| 81 |
install : true, |
| 82 |
install_dir : libv4lconvertprivdir, |
| 83 |
include_directories : v4l2_utils_incdir) |
| 84 |
ov518_decomp_sources = files( |
| 85 |
'ov518-decomp.c', |
| 86 |
) |
| 87 |
ov518_decomp = executable('ov518-decomp', |
| 88 |
ov518_decomp_sources, |
| 89 |
install : true, |
| 90 |
install_dir : libv4lconvertprivdir, |
| 91 |
include_directories : v4l2_utils_incdir) |
| 92 |
endif |
| 93 |
|
| 94 |
if have_visibility and have_fork |
| 95 |
libv4lconvert_c_args += [ |
| 96 |
'-fvisibility=hidden', |
| 97 |
'-DHAVE_LIBV4LCONVERT_HELPERS', |
| 98 |
] |
| 99 |
endif |
| 100 |
|
| 101 |
libv4lconvert = library('v4lconvert', |
| 102 |
libv4lconvert_sources, |
| 103 |
soversion: '0', |
| 104 |
version: '0.0.0', |
| 105 |
install : true, |
| 106 |
dependencies : libv4lconvert_deps, |
| 107 |
c_args : libv4lconvert_c_args, |
| 108 |
include_directories : v4l2_utils_incdir) |
| 109 |
|
| 110 |
dep_libv4lconvert = declare_dependency(link_with : libv4lconvert) |
| 111 |
meson.override_dependency('libv4lconvert', dep_libv4lconvert) |
| 112 |
|
| 113 |
pkg.generate( |
| 114 |
libv4lconvert, |
| 115 |
name : 'libv4lconvert', |
| 116 |
version : meson.project_version(), |
| 117 |
description : 'v4l format conversion library') |