...
 
Commits (4)
#!/usr/bin/env python3
import sys, os
from pathlib import Path
output_fd = sys.stdout.buffer.fileno()
for fname in sys.argv[1:]:
inputf = Path(fname)
with inputf.open('rb') as f:
while os.sendfile(output_fd, f.fileno(), None, 1 << 30) != 0:
pass
valaccode_sources = files(
'valaccodeassignment.vala',
'valaccodebinaryexpression.vala',
'valaccodeblock.vala',
'valaccodebreakstatement.vala',
'valaccodecasestatement.vala',
'valaccodecastexpression.vala',
'valaccodecommaexpression.vala',
'valaccodecomment.vala',
'valaccodeconditionalexpression.vala',
'valaccodeconstant.vala',
'valaccodecontinuestatement.vala',
'valaccodedeclaration.vala',
'valaccodedeclarator.vala',
'valaccodedostatement.vala',
'valaccodeelementaccess.vala',
'valaccodeemptystatement.vala',
'valaccodeenum.vala',
'valaccodeenumvalue.vala',
'valaccodeexpressionstatement.vala',
'valaccodeexpression.vala',
'valaccodefeaturetestmacro.vala',
'valaccodefile.vala',
'valaccodeforstatement.vala',
'valaccodefragment.vala',
'valaccodefunctioncall.vala',
'valaccodefunctiondeclarator.vala',
'valaccodefunction.vala',
'valaccodeggnucsection.vala',
'valaccodegotostatement.vala',
'valaccodeidentifier.vala',
'valaccodeifsection.vala',
'valaccodeifstatement.vala',
'valaccodeincludedirective.vala',
'valaccodeinitializerlist.vala',
'valaccodeinvalidexpression.vala',
'valaccodelabel.vala',
'valaccodelinedirective.vala',
'valaccodemacroreplacement.vala',
'valaccodememberaccess.vala',
'valaccodemodifiers.vala',
'valaccodenewline.vala',
'valaccodenode.vala',
'valaccodeoncesection.vala',
'valaccodeparameter.vala',
'valaccodeparenthesizedexpression.vala',
'valaccodereturnstatement.vala',
'valaccodestatement.vala',
'valaccodestruct.vala',
'valaccodeswitchstatement.vala',
'valaccodetypedefinition.vala',
'valaccodeunaryexpression.vala',
'valaccodevariabledeclarator.vala',
'valaccodewhilestatement.vala',
'valaccodewriter.vala'
)
valaccode_lib = static_library(
'valaccode',
valaccode_sources,
dependencies: [gobject_dep, valagee_dep, valacore_dep],
install: false,
vala_args: ['--use-header'],
vala_header: 'valaccode.h',
vala_vapi: 'valaccode.vapi',
)
valaccode_dep = declare_dependency(
link_with: [valaccode_lib],
dependencies: [valagee_dep],
include_directories: include_directories('.'),
)
valacodegen_sources = files(
'valaccode.vala',
'valaccodearraymodule.vala',
'valaccodeassignmentmodule.vala',
'valaccodeattribute.vala',
'valaccodebasemodule.vala',
'valaccodecompiler.vala',
'valaccodecontrolflowmodule.vala',
'valaccodedelegatemodule.vala',
'valaccodememberaccessmodule.vala',
'valaccodemethodcallmodule.vala',
'valaccodemethodmodule.vala',
'valaccodestructmodule.vala',
'valaclassregisterfunction.vala',
'valactype.vala',
'valaenumregisterfunction.vala',
'valagasyncmodule.vala',
'valagdbusclientmodule.vala',
'valagdbusmodule.vala',
'valagdbusservermodule.vala',
'valagerrormodule.vala',
'valagirwriter.vala',
'valagobjectmodule.vala',
'valagsignalmodule.vala',
'valagtkmodule.vala',
'valagtypemodule.vala',
'valagvariantmodule.vala',
'valainterfaceregisterfunction.vala',
'valastructregisterfunction.vala',
'valatyperegisterfunction.vala',
)
valacodegen_lib = shared_library(
'valacodegen',
valacodegen_sources,
dependencies: [gobject_dep, valacore_dep, valaccode_dep],
install_rpath: pkglibdir,
install_dir: pkglibdir,
install: [ true, false, false ],
vala_args: ['--use-header'],
vala_header: 'valacodegen.h',
vala_vapi: 'valacodegen.vapi',
)
valacodegen_dep = declare_dependency(
link_with: [valacodegen_lib],
dependencies: [valacore_dep, valaccode_dep],
include_directories: include_directories('.'),
)
valac_sources = files(
'valacompiler.vala',
)
valac_name = 'valac@0@'.format(vala_version_suffix)
valac_exe = executable(
valac_name,
valac_sources,
dependencies: [glib_dep, valacodegen_dep],
install: true,
)
vala_name = 'vala@0@'.format(vala_version_suffix)
# https://github.com/mesonbuild/meson/issues/1602
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@; ln -fs --relative @1@ valac'.format(join_paths(get_option('prefix'), get_option('bindir')), valac_name))
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@; ln -fs --relative @1@ @2@'.format(join_paths(get_option('prefix'), get_option('bindir')), valac_name, vala_name))
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@; ln -fs --relative @1@ vala'.format(join_paths(get_option('prefix'), get_option('bindir')), valac_name))
/* Name of package */
#mesondefine PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#mesondefine PACKAGE_BUGREPORT
#mesondefine PACKAGE_DATADIR
/* Define to the full name of this package. */
#mesondefine PACKAGE_NAME
/* Define to the full name and version of this package. */
#mesondefine PACKAGE_STRING
/* Define to the suffix of this package */
#mesondefine PACKAGE_SUFFIX
/* Define to the one symbol short name of this package. */
#mesondefine PACKAGE_TARNAME
/* Define to the home page for this package. */
#mesondefine PACKAGE_URL
/* Define to the version of this package. */
#mesondefine PACKAGE_VERSION
/* Version number of package */
#mesondefine VERSION
manpages = files(
'vala-gen-introspect.1',
'valac.1',
'valadoc.1',
'vapigen.1',
)
install_man(manpages)
# https://github.com/mesonbuild/meson/issues/1602
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@/man1; ln -fs --relative vala-gen-introspect.1 @1@'.format(join_paths(get_option('prefix'), get_option('mandir')), 'vala-gen-introspect@0@.1'.format(vala_version_suffix)))
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@/man1; ln -fs --relative valac.1 @1@'.format(join_paths(get_option('prefix'), get_option('mandir')), 'valac@0@.1'.format(vala_version_suffix)))
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@/man1; ln -fs --relative valadoc.1 @1@'.format(join_paths(get_option('prefix'), get_option('mandir')), 'valadoc@0@.1'.format(vala_version_suffix)))
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@/man1; ln -fs --relative vapigen.1 @1@'.format(join_paths(get_option('prefix'), get_option('mandir')), 'vapigen@0@.1'.format(vala_version_suffix)))
valagee_sources = files(
'arraylist.vala',
'collection.vala',
'hashmap.vala',
'hashset.vala',
'iterable.vala',
'iterator.vala',
'list.vala',
'mapiterator.vala',
'map.vala',
'set.vala',
'timsort.vala',
)
valagee_lib = static_library(
'valagee',
valagee_sources,
dependencies: [gobject_dep],
install: [ false, true, false ],
install_dir: [
false,
join_paths (get_option('includedir'), 'vala@0@'.format (vala_version_suffix)),
false
],
vala_args: ['--use-header'],
vala_header: 'valagee.h',
vala_vapi: 'gee.vapi',
)
valagee_dep = declare_dependency(
link_with: [valagee_lib],
include_directories: include_directories('.', '..'),
)
gidl_sources = files(
'gidlmodule.c',
'gidlnode.c',
'gidlparser.c',
'gmetadata.c',
)
gidl_lib = static_library('gidl',
gidl_sources,
dependencies: [gobject_dep, gmodule_dep])
gidl_dep = declare_dependency(
link_with: [gidl_lib],
include_directories: include_directories('.'),
)
flex = find_program('flex')
bison = find_program('bison')
lgen = generator(flex,
output: '@PLAINNAME@.c',
arguments: ['-o', '@OUTPUT@', '@INPUT@'])
lfiles = lgen.process('scannerlexer.l')
pgen = generator(bison,
output: ['@BASENAME@.c', '@BASENAME@.h'],
arguments: ['@INPUT@', '--defines=@OUTPUT1@', '--output=@OUTPUT0@'],
)
pfiles = pgen.process('scannerparser.y')
gen_introspect_sources = files(
'gidlwriter.c',
'scanner.c',
)
gen_introspect_name = 'gen-introspect@0@'.format(vala_version_suffix)
gen_introspect_exe = executable(gen_introspect_name,
[gen_introspect_sources, lfiles, pfiles],
install: true,
install_dir: pkglibdir,
dependencies: [gobject_dep, gmodule_dep, gidl_dep],
)
libvaladoc_sources = files(
'doclet.vala',
'errorreporter.vala',
'filehelper.vala',
'moduleloader.vala',
'settings.vala',
'markupwriter.vala',
'gtkdocmarkupwriter.vala',
'devhelp-markupwriter.vala',
'ctyperesolver.vala',
'gtkdocrenderer.vala',
'gvc-compat.c',
'documentation/commentscanner.vala',
'documentation/documentation.vala',
'documentation/documentationparser.vala',
'documentation/wiki.vala',
'documentation/wikiscanner.vala',
'documentation/gtkdoccommentparser.vala',
'documentation/gtkdoccommentscanner.vala',
'documentation/gtkdocmarkdownparser.vala',
'documentation/gtkdocmarkdownscanner.vala',
'documentation/importerhelper.vala',
'documentation/girmetadata.vala',
'importer/documentationimporter.vala',
'importer/valadocdocumentationimporter.vala',
'importer/valadocdocumentationimporterscanner.vala',
'importer/girdocumentationimporter.vala',
'importer/internalidregistrar.vala',
'api/sourcecomment.vala',
'api/girsourcecomment.vala',
'api/attribute.vala',
'api/array.vala',
'api/callable.vala',
'api/childsymbolregistrar.vala',
'api/class.vala',
'api/constant.vala',
'api/delegate.vala',
'api/enum.vala',
'api/enumvalue.vala',
'api/errorcode.vala',
'api/errordomain.vala',
'api/field.vala',
'api/formalparameter.vala',
'api/interface.vala',
'api/item.vala',
'api/method.vala',
'api/namespace.vala',
'api/node.vala',
'api/nodetype.vala',
'api/ownership.vala',
'api/package.vala',
'api/pointer.vala',
'api/property.vala',
'api/propertyaccessor.vala',
'api/signal.vala',
'api/signaturebuilder.vala',
'api/sourcefile.vala',
'api/struct.vala',
'api/symbol.vala',
'api/tree.vala',
'api/typeparameter.vala',
'api/typereference.vala',
'api/typesymbol.vala',
'api/visitor.vala',
'api/driver.vala',
'content/block.vala',
'content/blockcontent.vala',
'content/comment.vala',
'content/contentfactory.vala',
'content/contentelement.vala',
'content/contentrenderer.vala',
'content/contentvisitor.vala',
'content/embedded.vala',
'content/headline.vala',
'content/inline.vala',
'content/inlinetaglet.vala',
'content/inlinecontent.vala',
'content/wikilink.vala',
'content/link.vala',
'content/list.vala',
'content/listitem.vala',
'content/page.vala',
'content/paragraph.vala',
'content/warning.vala',
'content/note.vala',
'content/resourcelocator.vala',
'content/run.vala',
'content/sourcecode.vala',
'content/styleattributes.vala',
'content/symbollink.vala',
'content/table.vala',
'content/tablecell.vala',
'content/tablerow.vala',
'content/taglet.vala',
'content/text.vala',
'charts/chart.vala',
'charts/chartfactory.vala',
'charts/hierarchychart.vala',
'charts/simplechartfactory.vala',
'parser/manyrule.vala',
'parser/oneofrule.vala',
'parser/optionalrule.vala',
'parser/parser.vala',
'parser/parsercallback.vala',
'parser/rule.vala',
'parser/scanner.vala',
'parser/sequencerule.vala',
'parser/stubrule.vala',
'parser/token.vala',
'parser/tokentype.vala',
'taglets/tagletdeprecated.vala',
'taglets/tagletinheritdoc.vala',
'taglets/tagletinit.vala',
'taglets/tagletlink.vala',
'taglets/tagletparam.vala',
'taglets/tagletreturn.vala',
'taglets/tagletsee.vala',
'taglets/tagletsince.vala',
'taglets/tagletthrows.vala',
'highlighter/scanner.vala',
'highlighter/codescanner.vala',
'highlighter/xmlscanner.vala',
'highlighter/codetoken.vala',
'highlighter/highlighter.vala',
'html/basicdoclet.vala',
'html/htmlchartfactory.vala',
'html/linkhelper.vala',
'html/cssclassresolver.vala',
'html/htmlmarkupwriter.vala',
'html/htmlrenderer.vala',
)
libvaladoc_lib = shared_library(
'valadoc@0@'.format(vala_version_suffix),
libvaladoc_sources,
dependencies: [gmodule_dep, valacore_dep, valacodegen_dep, libgvc_dep],
soversion: '0.0.0',
install: true,
install_dir: [
true,
join_paths (get_option('includedir'), 'valadoc@0@'.format (vala_version_suffix)),
true
],
c_args: ['-DPACKAGE_VALADOC_LIBDIR="@0@"'.format(join_paths(get_option('prefix'), get_option('libdir'), 'valadoc'))],
vala_args: ['--use-header'],
vala_header: 'valadoc.h',
vala_vapi: 'valadoc@0@.vapi'.format(vala_version_suffix),
)
libvaladoc_dep = declare_dependency(link_with: [libvaladoc_lib], dependencies: [gmodule_dep, valacore_dep, libgvc_dep], include_directories: include_directories('.'))
configure_file(input: 'valadoc.deps.in', output: 'valadoc@0@.deps'.format(vala_version_suffix), configuration: pkgconf)
configure_file(
input: 'valadoc.pc.in',
output: 'valadoc@0@.pc'.format(vala_version_suffix),
configuration: pkgconf,
install_dir: pkg_install_dir,
)
project('vala',
'c', 'vala',
version: '0.43.90',
meson_version: '>= 0.49',
license: 'LGPL2.1'
)
vala_version = meson.project_version()
version_array = vala_version.split('.')
vala_api_version = '0.44'
vala_version_suffix = '-@0@'.format(vala_api_version)
# Minimal required version for an initial build
vala_version_required = '0.16.1'
vala = meson.get_compiler('vala')
if not vala.version().version_compare('>= @0@'.format(vala_version_required))
error('valac >= @0@ required!'.format(vala_version_required))
endif
if not vala.version().version_compare('>= @0@'.format(vala_version))
warning('Proper bootstrap build with valac >= @0@ is required!!!'.format(vala_version))
endif
pkgdatadir = join_paths(get_option('prefix'), get_option('datadir'), 'vala@0@'.format(vala_version_suffix))
pkglibdir = join_paths(get_option('prefix'), get_option('libdir'), 'vala@0@'.format(vala_version_suffix))
conf = configuration_data()
conf.set_quoted('PACKAGE', meson.project_name())
conf.set_quoted('PACKAGE_BUGREPORT', 'https://gitlab.gnome.org/GNOME/vala/issues')
conf.set_quoted('PACKAGE_DATADIR', pkgdatadir)
conf.set_quoted('PACKAGE_NAME', meson.project_name())
conf.set_quoted('PACKAGE_STRING', '@0@ @1@'.format(meson.project_name(), vala_version))
conf.set_quoted('PACKAGE_SUFFIX', vala_version_suffix)
conf.set_quoted('PACKAGE_TARNAME', meson.project_name())
conf.set_quoted('PACKAGE_URL', 'https://wiki.gnome.org/Projects/Vala')
conf.set_quoted('PACKAGE_VERSION', vala_version)
conf.set_quoted('VERSION', vala_version)
conf.set_quoted('API_VERSION', vala_api_version)
conf.set_quoted('BUILD_VERSION', vala_version)
configure_file(input: 'config.h.meson', output: 'config.h', configuration: conf)
vcs_tag(input: 'version.h.meson', output: 'version.h')
pkgconf = configuration_data()
pkgconf.set('prefix', get_option('prefix'))
pkgconf.set('exec_prefix', '${prefix}')
pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
pkgconf.set('bindir', '${exec_prefix}/@0@'.format(get_option('bindir')))
pkgconf.set('datarootdir', '${prefix}/@0@'.format(get_option('datadir')))
pkgconf.set('datadir', '${datarootdir}')
pkgconf.set('includedir', '${prefix}/@0@'.format(get_option('includedir')))
pkgconf.set('pkgdatadir', '${datarootdir}/vala@0@'.format(vala_version_suffix))
pkgconf.set('pkglibdir', '${exec_prefix}/@0@'.format(get_option('libdir'), 'vala@0@'.format(vala_version_suffix)))
pkgconf.set('PACKAGE_SUFFIX', vala_version_suffix)
pkgconf.set('VERSION', vala_version)
pkg_install_dir = '@0@/pkgconfig'.format(get_option('libdir'))
configure_file(
input: 'libvala.pc.in',
output: 'libvala@0@.pc'.format(vala_version_suffix),
configuration: pkgconf,
install_dir: pkg_install_dir
)
versionconf = configuration_data()
versionconf.set('VALA_MAJOR_VERSION', version_array[0])
versionconf.set('VALA_MINOR_VERSION', version_array[1])
versionconf.set('VALA_MICRO_VERSION', version_array[2])
versionconf.set('API_VERSION', vala_api_version)
versionconf.set('PACKAGE_VERSION', vala_version)
add_project_arguments([
'--disable-version-header',
'--vapidir', join_paths(meson.source_root(), 'vapi'),
'--pkg', 'config',
],
language: 'vala'
)
if vala.version().version_compare('>= 0.25.1')
add_project_arguments(['--hide-internal'], language: 'vala')
endif
if vala.version().version_compare('>= 0.39.6')
add_project_arguments(['--abi-stability'], language: 'vala')
endif
add_project_arguments([
'-Wno-discarded-qualifiers',
'-Wno-incompatible-pointer-types',
'-Wno-unused',
'-DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_40',
'-DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_40',
],
language: 'c',
)
glib_version_required = '2.40.0'
libgvc_version_required = '2.16'
glib_dep = dependency('glib-2.0', version: '>= @0@'.format(glib_version_required))
gobject_dep = dependency('gobject-2.0', version: '>= @0@'.format(glib_version_required))
gmodule_dep = dependency('gmodule-2.0', version: '>= @0@'.format(glib_version_required))
libgvc_dep = dependency('libgvc', version: '>= @0@'.format(libgvc_version_required))
# Check for CGraph support of libgvc
cc = meson.get_compiler('c')
if cc.run('''#include <gvc.h>
int main(void) {
#ifdef WITH_CGRAPH
return 0;
#else
return -1;
#endif
}''',
dependencies: libgvc_dep).returncode() == 0
add_project_arguments('-D', 'WITH_CGRAPH', language: 'vala')
endif
subdir('gobject-introspection')
subdir('gee')
subdir('vala')
subdir('ccode')
subdir('codegen')
subdir('compiler')
subdir('vapigen')
subdir('libvaladoc')
subdir('valadoc')
subdir('vapi')
subdir('doc')
subdir('tests')
install_data('vala.m4', install_dir: join_paths('share', 'aclocal'))
pycat = find_program(join_paths(meson.source_root(), 'build-aux', 'meson', 'cat.py'))
#custom_target(
# 'libvala@0@.vapi'.format(vala_version_suffix),
# command: [pycat, '@INPUT@'],
# depends: [valagee_lib, valacore_lib],
# capture: true,
# install: true,
# install_dir: join_paths('share', 'vala', 'vapi'),
# input: [
# join_paths(meson.current_build_dir(), 'gee', 'gee.vapi'),
# join_paths(meson.current_build_dir(), 'vala', 'vala.vapi'),
# ],
# output: 'libvala@0@.vapi'.format(vala_version_suffix),
#)
test_cases = [
'basic-types/integers.vala',
'basic-types/escape-chars.vala',
'basic-types/floats.vala',
'basic-types/strings.vala',
'basic-types/arrays.vala',
'basic-types/arrays-fixed-assignment.vala',
'basic-types/array-uint8-uchar-compat.vala',
'basic-types/pointers.vala',
'basic-types/sizeof.vala',
'basic-types/garray.vala',
'basic-types/glists.vala',
'basic-types/gptrarray.vala',
'basic-types/gvariants.vala',
'basic-types/bug570846.test',
'basic-types/bug571486.vala',
'basic-types/bug591552.vala',
'basic-types/bug595751.vala',
'basic-types/bug596637.vala',
'basic-types/bug596785.vala',
'basic-types/bug604371.vala',
'basic-types/bug604589.test',
'basic-types/bug622178.vala',
'basic-types/bug632322.vala',
'basic-types/bug641308.test',
'basic-types/bug643612.vala',
'basic-types/bug644046.vala',
'basic-types/bug647222.vala',
'basic-types/bug648364.vala',
'basic-types/bug650993.vala',
'basic-types/bug652380.vala',
'basic-types/bug655908.vala',
'basic-types/bug659975.vala',
'basic-types/bug678791.vala',
'basic-types/bug686336.vala',
'basic-types/bug729907.vala',
'basic-types/bug731017.vala',
'basic-types/bug744923.test',
'basic-types/bug756376.vala',
'basic-types/bug761307.vala',
'basic-types/bug761736.vala',
'basic-types/bug771626.test',
'basic-types/bug772426.vala',
'basic-types/bug777697.test',
'basic-types/bug787152.vala',
'basic-types/bug788775.vala',
'chainup/base-class-invalid.test',
'chainup/base-enum-invalid.test',
'chainup/base-invalid.test',
'chainup/base-struct-invalid.test',
'chainup/class-base.vala',
'chainup/class-base-foo.vala',
'chainup/class-object.vala',
'chainup/class-this.vala',
'chainup/class-this-foo.vala',
'chainup/method-lambda-base.vala',
'chainup/no-chainup.vala',
'chainup/struct-base.vala',
'chainup/struct-base-foo.vala',
'chainup/struct-this.vala',
'chainup/struct-this-foo.vala',
'chainup/bug791785.vala',
'pointers/bug590641.vala',
'methods/lambda.vala',
'methods/closures.vala',
'methods/contains.vala',
'methods/iterator.vala',
'methods/prepostconditions.vala',
'methods/same-name.vala',
'methods/symbolresolution.vala',
'methods/bug540483.vala',
'methods/bug595538.vala',
'methods/bug596726.vala',
'methods/bug597426.vala',
'methods/bug598738.vala',
'methods/bug599892.vala',
'methods/bug613483.vala',
'methods/bug615450.test',
'methods/bug620673.test',
'methods/bug620673.vala',
'methods/bug622570.vala',
'methods/bug626783.vala',
'methods/bug634753.vala',
'methods/bug639054.vala',
'methods/bug642350.vala',
'methods/bug642885.vala',
'methods/bug642899.vala',
'methods/bug643088.test',
'methods/bug646345.vala',
'methods/bug648030.test',
'methods/bug648320.vala',
'methods/bug649562.vala',
'methods/bug652098.vala',
'methods/bug653391.vala',
'methods/bug653908.vala',
'methods/bug663210.vala',
'methods/bug710862.vala',
'methods/bug723009.vala',
'methods/bug723195.vala',
'methods/bug726347.vala',
'methods/bug736235.vala',
'methods/bug737222.vala',
'methods/bug743877.vala',
'methods/bug771964.vala',
'methods/bug774060.vala',
'methods/bug775466.test',
'methods/bug781061.vala',
'methods/bug784691.vala',
'methods/bug791215.vala',
'methods/bug791283.vala',
'methods/generics.vala',
'methods/printf-invalid.test',
'methods/printf-constructor.vala',
'methods/printf-constructor-invalid.test',
'methods/varargs-out.vala',
'control-flow/assigned-local-variable.vala',
'control-flow/break.vala',
'control-flow/break-invalid.test',
'control-flow/continue-invalid.test',
'control-flow/double-catch.test',
'control-flow/expressions-conditional.vala',
'control-flow/finally-return.test',
'control-flow/for.vala',
'control-flow/foreach.vala',
'control-flow/missing-break.test',
'control-flow/missing-return.test',
'control-flow/nested-conditional.vala',
'control-flow/switch.vala',
'control-flow/sideeffects.vala',
'control-flow/unassigned-captured-local-variable.test',
'control-flow/unassigned-local-block-variable.test',
'control-flow/unassigned-local-variable.test',
'control-flow/while-false.vala',
'control-flow/bug628336.vala',
'control-flow/bug639482.vala',
'control-flow/bug652549.vala',
'control-flow/bug661985.vala',
'control-flow/bug665904.vala',
'control-flow/bug691514.vala',
'control-flow/bug736774-1.vala',
'control-flow/bug736774-2.vala',
'control-flow/bug790903.test',
'control-flow/bug790903-2.test',
'control-semantic/argument-extra.test',
'control-semantic/argument-incompatible-type-out.test',
'control-semantic/argument-incompatible-type-ref.test',
'control-semantic/argument-missing.test',
'control-semantic/argument-named.test',
'control-semantic/argument-no-out.test',
'control-semantic/argument-no-ref.test',
'control-semantic/argument-null-ref.test',
'control-semantic/argument-owned-out.test',
'control-semantic/argument-owned-ref.test',
'control-semantic/argument-value-out.test',
'control-semantic/argument-value-ref.test',
'control-semantic/member-incompatible-type.test',
'control-semantic/member-invalid.test',
'control-semantic/member-private.test',
'control-semantic/member-readonly.test',
'control-semantic/printf-too-few.test',
'control-semantic/printf-too-many.test',
'control-semantic/variadic-argument-invalid.test',
'enums/enum_only.vala',
'enums/enum-no-gtype.vala',
'enums/enums.vala',
'enums/flags.vala',
'enums/bug666035.vala',
'enums/bug673879.vala',
'enums/bug763831.vala',
'enums/bug780050.vala',
'structs/struct_only.vala',
'structs/struct-empty-still.test',
'structs/struct-no-gtype.vala',
'structs/struct-static-field-initializer.vala',
'structs/struct-static-field-initializer.test',
'structs/struct-static-property-initializer.test',
'structs/structs.vala',
'structs/gvalue.vala',
'structs/bug530605.vala',
'structs/bug572091.vala',
'structs/bug583603.vala',
'structs/bug595587.vala',
'structs/bug596144.vala',
'structs/bug603056.vala',
'structs/bug606202.vala',
'structs/bug609642.vala',
'structs/bug613513.vala',
'structs/bug613825.vala',
'structs/bug621176.vala',
'structs/bug622422.vala',
'structs/bug623092.vala',
'structs/bug651441.vala',
'structs/bug654646.vala',
'structs/bug654753.vala',
'structs/bug656693.vala',
'structs/bug657378.vala',
'structs/bug658048.vala',
'structs/bug660426.vala',
'structs/bug661945.vala',
'structs/bug667890.vala',
'structs/bug669580.vala',
'structs/bug685177.vala',
'structs/bug686190.vala',
'structs/bug688732.vala',
'structs/bug690380.vala',
'structs/bug694140.vala',
'structs/bug749952.vala',
'structs/bug764041.test',
'structs/bug775761.vala',
'structs/bug777194.vala',
'structs/bug777194-2.vala',
'delegates/casting.vala',
'delegates/compatible.vala',
'delegates/delegate_only.vala',
'delegates/delegates.vala',
'delegates/delegates-error.test',
'delegates/error-pos.vala',
'delegates/fields.vala',
'delegates/fields-no-target.vala',
'delegates/instance-method-to-no-target.test',
'delegates/lambda-mixed-instance-static.vala',
'delegates/lambda-shared-closure.vala',
'delegates/reference_transfer.vala',
'delegates/wrapper.vala',
'delegates/bug519949.test',
'delegates/bug539166.vala',
'delegates/bug595610.vala',
'delegates/bug595639.vala',
'delegates/bug598869.test',
'delegates/bug632017.test',
'delegates/bug638415.vala',
'delegates/bug639751.vala',
'delegates/bug659778.vala',
'delegates/bug683925.vala',
'delegates/bug703804.vala',
'delegates/bug761360.vala',
'delegates/bug772204.test',
'delegates/bug792077.vala',
'objects/chainup.vala',
'objects/class_only.vala',
'objects/classes.vala',
'objects/classes-interfaces.vala',
'objects/classes-interfaces-virtuals.vala',
'objects/classes-implicit-implementation.vala',
'objects/compact-class.vala',
'objects/compact-class-destructor.vala',
'objects/constructor-variadic.test',
'objects/constructors.vala',
'objects/destructors.vala',
'objects/duplicating-instance-invalid.test',
'objects/dynamic.vala',
'objects/generics.vala',
'objects/initially-unowned.vala',
'objects/fields.vala',
'objects/gsource.vala',
'objects/interface_only.vala',
'objects/interfaces.vala',
'objects/interface-generics.vala',
'objects/methods.vala',
'objects/paramspec.vala',
'objects/properties.vala',
'objects/property-notify.vala',
'objects/property-read-only-auto.vala',
'objects/property-static.vala',
'objects/regex.vala',
'objects/signals.vala',
'objects/signals-delegate.vala',
'objects/signals-delegate-parameter.vala',
'objects/signals-lambda-delegate.vala',
'objects/singleton.vala',
'objects/test-025.vala',
'objects/test-026.vala',
'objects/test-029.vala',
'objects/test-034.vala',
'objects/bug541728.test',
'objects/bug554329.test',
'objects/bug564011.test',
'objects/bug564090.test',
'objects/bug566909.vala',
'objects/bug574146.test',
'objects/bug585344.test',
'objects/bug587905.test',
'objects/bug588203.vala',
'objects/bug589928.vala',
'objects/bug593137.vala',
'objects/bug593260.vala',
'objects/bug596621.vala',
'objects/bug597155.vala',
'objects/bug597161.vala',
'objects/bug603491.test',
'objects/bug613486.vala',
'objects/bug613840.vala',
'objects/bug620675.vala',
'objects/bug620706.vala',
'objects/bug624594.vala',
'objects/bug626038.vala',
'objects/bug628639.vala',
'objects/bug629593.vala',
'objects/bug631267.vala',
'objects/bug634782.vala',
'objects/bug641418-1.test',
'objects/bug641418-2.test',
'objects/bug641418-3.test',
'objects/bug641828.vala',
'objects/bug642809.vala',
'objects/bug643711.vala',
'objects/bug644938.vala',
'objects/bug646362.vala',
'objects/bug646792.vala',
'objects/bug647018.vala',
'objects/bug653138.vala',
'objects/bug654702.vala',
'objects/bug663134.vala',
'objects/bug664529.vala',
'objects/bug667668.vala',
'objects/bug681356.vala',
'objects/bug683646.vala',
'objects/bug695671.vala',
'objects/bug702736.vala',
'objects/bug702846.vala',
'objects/bug731547.vala',
'objects/bug741465.vala',
'objects/bug751338.vala',
'objects/bug758816.vala',
'objects/bug760031.test',
'objects/bug764481.vala',
'objects/bug767092.test',
'objects/bug768823.test',
'objects/bug773956-1.test',
'objects/bug773956-2.test',
'objects/bug615830-1.test',
'objects/bug615830-2.test',
'objects/bug766739.vala',
'objects/bug778632.vala',
'objects/bug779038-1.test',
'objects/bug779038-2.test',
'objects/bug779038-3.test',
'objects/bug779219.vala',
'objects/bug779955.vala',
'objects/bug783897.vala',
'objects/bug788964.vala',
'objects/bug795225-1.test',
'objects/bug795225-2.test',
'objects/bug795225-3.test',
'objects/bug795225-4.test',
'objects/bug795521.vala',
'errors/catch-error-code.vala',
'errors/catch-in-finally.vala',
'errors/errors.vala',
'errors/errorcode.vala',
'errors/errordomain.vala',
'errors/invalid-type-check.test',
'errors/method-throws.vala',
'errors/bug567181.vala',
'errors/bug579101.vala',
'errors/bug596228.vala',
'errors/bug623049.vala',
'errors/bug639589.vala',
'errors/bug651145.vala',
'errors/bug762377.vala',
'errors/bug778224.vala',
'asynchronous/bug595735.vala',
'asynchronous/bug595755.vala',
'asynchronous/bug596177.vala',
'asynchronous/bug596861.vala',
'asynchronous/bug597294.vala',
'asynchronous/bug598677.vala',
'asynchronous/bug598697.vala',
'asynchronous/bug598698.vala',
'asynchronous/bug599568.vala',
'asynchronous/bug600827.vala',
'asynchronous/bug601558.vala',
'asynchronous/bug612641.vala',
'asynchronous/bug613484.vala',
'asynchronous/bug614294.vala',
'asynchronous/bug620740.vala',
'asynchronous/bug626053.vala',
'asynchronous/bug639591.vala',
'asynchronous/bug640721.vala',
'asynchronous/bug641182.vala',
'asynchronous/bug646945.vala',
'asynchronous/bug652252.vala',
'asynchronous/bug653861.vala',
'asynchronous/bug654336.vala',
'asynchronous/bug654337.vala',
'asynchronous/bug659886.vala',
'asynchronous/bug661961.vala',
'asynchronous/bug710103.vala',
'asynchronous/bug741929.vala',
'asynchronous/bug742621.vala',
'asynchronous/bug762819.vala',
'asynchronous/bug777242.vala',
'asynchronous/bug783543.vala',
'asynchronous/bug792660.vala',
'asynchronous/bug792942.vala',
'asynchronous/bug793158.vala',
'asynchronous/catch-error-scope.vala',
'asynchronous/catch-in-finally.vala',
'asynchronous/closures.vala',
'asynchronous/generator.vala',
'asynchronous/out-parameter-invalid.test',
'asynchronous/result-pos.vala',
'asynchronous/yield.vala',
'generics/bug640330.test',
'generics/bug640330.vala',
'generics/bug694765-1.vala',
'generics/bug694765-2.vala',
'generics/bug694765-3.vala',
'annotations/deprecated.vala',
'annotations/description.vala',
'annotations/noaccessormethod.test',
'parser/assignment.vala',
'parser/attribute-duplicate.test',
'parser/attribute-wrong-number.test',
'parser/constructor-class-exists.test',
'parser/constructor-exists.test',
'parser/constructor-no-new.test',
'parser/constructor-no-static-class.test',
'parser/constructor-static-exists.test',
'parser/continue-statement.vala',
'parser/creation-no-abstract.test',
'parser/creation-no-override.test',
'parser/creation-no-virtual.test',
'parser/delegate-no-new.test',
'parser/destructor-class-exists.test',
'parser/destructor-exists.test',
'parser/destructor-no-new.test',
'parser/destructor-no-static-class.test',
'parser/destructor-static-exists.test',
'parser/destructor-wrong-name.test',
'parser/do-statement.vala',
'parser/expect-endbrace.test',
'parser/expect-error.test',
'parser/field-no-abstract.test',
'parser/field-no-override.test',
'parser/field-no-static-class.test',
'parser/field-no-virtual.test',
'parser/foreach-no-type.test',
'parser/function-syntax-error.test',
'parser/inner-array-size.test',
'parser/invalid-brace.test',
'parser/lock-statement.vala',
'parser/method-no-abstract-override.test',
'parser/method-no-abstract-virtual-override.test',
'parser/method-no-abstract-virtual.test',
'parser/method-no-class-abstract.test',
'parser/method-no-class-override.test',
'parser/method-no-class-virtual.test',
'parser/method-no-static-abstract.test',
'parser/method-no-static-class.test',
'parser/method-no-static-override.test',
'parser/method-no-static-virtual.test',
'parser/method-no-virtual-override.test',
'parser/namespaces.vala',
'parser/namespace-missing-bracket.test',
'parser/preprocessor.vala',
'parser/preprocessor-glib.vala',
'parser/preprocessor-vala.vala',
'parser/property-default-redefined.test',
'parser/property-get-must-have-body.test',
'parser/property-get-redefined.test',
'parser/property-get-set-construct.test',
'parser/property-no-abstract-override.test',
'parser/property-no-abstract-virtual.test',
'parser/property-no-abstract-virtual-override.test',
'parser/property-no-static-class.test',
'parser/property-no-virtual-override.test',
'parser/property-set-must-have-body.test',
'parser/property-set-redefined.test',
'parser/signal-no-class.test',
'parser/signal-no-static.test',
'parser/statement-outside-root.test',
'parser/switch-statement.vala',
'parser/template.vala',
'parser/tuple.vala',
'parser/unsupported-property-async.test',
'parser/unsupported-property-throws.test',
'parser/using-ambiguous-reference.test',
'parser/using-directive.vala',
'parser/using-invalid-namespace.test',
'parser/yield-method.test',
'parser/yield-return.test',
'parser/yield-return.vala',
'parser/bug728574.vala',
'parser/bug749576.vala',
'resolver/class-base-cycle.test',
'resolver/interface-prerequisite-cycle.test',
'resolver/struct-base-cycle.test',
'ordering/delegate-class.vala',
'ordering/delegate-enum.vala',
'ordering/delegate-interface.vala',
'ordering/delegate-struct.vala',
'ordering/struct-delegate.vala',
'semantic/array-stacked.test',
'semantic/array-incompatible-initializer.test',
'semantic/array-incompatible-initializer2.test',
'semantic/assignment-element-incompatible-ownership.test',
'semantic/assignment-element-incompatible-type.test',
'semantic/assignment-same-variable.vala',
'semantic/assignment-signal-incompatible-method.test',
'semantic/assignment-signal-incompatible-type.test',
'semantic/chainup-gobject-incompatible-type-property.test',
'semantic/chainup-gobject-unknown-property.test',
'semantic/chainup-gobject-unsupported-type-property.test',
'semantic/class-base-type-invalid.test',
'semantic/class-base-type-less-accessible.test',
'semantic/class-compact-field-class.test',
'semantic/class-compact-field-lock.test',
'semantic/class-compact-field-private.test',
'semantic/class-compact-derived-instance-field.test',
'semantic/class-compact-interface.test',
'semantic/class-compact-method-baseaccess.test',
'semantic/class-compact-property-baseaccess.test',
'semantic/class-missing-implement-interface-method.test',
'semantic/class-missing-implement-interface-property.test',
'semantic/class-missing-implement-interfaces-methods.test',
'semantic/class-missing-implement-interfaces-methods2.test',
'semantic/class-missing-implement-interfaces-methods3.test',
'semantic/class-missing-implement-method.test',
'semantic/class-missing-implement-property.test',
'semantic/class-missing-prerequisites.test',
'semantic/class-singleton-base.test',
'semantic/class-singleton-non-gobject.test',
'semantic/class-too-few-type-arguments.test',
'semantic/class-too-many-type-arguments.test',
'semantic/constant-extern.test',
'semantic/constant-value.test',
'semantic/constant-value-missing.test',
'semantic/constant-value-type.test',
'semantic/constant-void.test',
'semantic/construct-without-gobject.test',
'semantic/delegate-too-few-type-arguments.test',
'semantic/delegate-too-many-type-arguments.test',
'semantic/enum-empty.test',
'semantic/errordomain-empty.test',
'semantic/field-accessibility.test',
'semantic/field-compact-static.test',
'semantic/field-external.test',
'semantic/field-incompatible.test',
'semantic/field-interface.test',
'semantic/field-namespace-owned.test',
'semantic/field-non-constant.test',
'semantic/field-owned-to-unowned.test',
'semantic/field-static-instance-access.test',
'semantic/field-void.test',
'semantic/floating-reference.vala',
'semantic/foreach-iterator-args.test',
'semantic/foreach-iterator-element-owned.test',
'semantic/foreach-iterator-void.test',
'semantic/foreach-iterator-wrong-types.test',
'semantic/foreach-missing-generic-type.test',
'semantic/foreach-missing-iterator.test',
'semantic/foreach-missing-next-value.test',
'semantic/foreach-next-args.test',
'semantic/foreach-next-get-args.test',
'semantic/foreach-next-get-void.test',
'semantic/foreach-next-missing-get.test',
'semantic/foreach-next-value-args.test',
'semantic/foreach-next-value-void.test',
'semantic/foreach-next-void.test',
'semantic/foreach-wrong-types.test',
'semantic/initializer-unknown-type.test',
'semantic/localvariable-owned-to-unowned.test',
'semantic/localvariable-var-static-access-instance-field.test',
'semantic/localvariable-var-static-access-instance-method.test',
'semantic/localvariable-var-static-access-instance-property.test',
'semantic/localvariable-var-without-initializer.test',
'semantic/localvariable-void.test',
'semantic/method-abstract.test',
'semantic/method-abstract-body.test',
'semantic/method-async-ref-parameter.test',
'semantic/method-body.test',
'semantic/method-class-abstract.test',
'semantic/method-derived-compact.test',
'semantic/method-error-accessibility.test',
'semantic/method-extern-abstract.test',
'semantic/method-extern-body.test',
'semantic/method-extern-virtual.test',
'semantic/method-interface-already-found.test',
'semantic/method-interface-not-found.test',
'semantic/method-main-async.test',
'semantic/method-main-inline.test',
'semantic/method-main-throws.test',
'semantic/method-override.test',
'semantic/method-postcondition.test',
'semantic/method-precondition.test',
'semantic/method-private-abstract.test',
'semantic/method-private-override.test',
'semantic/method-private-virtual.test',
'semantic/method-protected.test',
'semantic/method-return-accessibility.test',
'semantic/method-too-few-type-arguments.test',
'semantic/method-too-many-type-arguments.test',
'semantic/method-virtual.test',
'semantic/method-virtual-body.test',
'semantic/objectcreation-abstract-class.test',
'semantic/objectcreation-no-creation-method.test',
'semantic/objectcreation-non-public-constructor.test',
'semantic/objectcreation-unsupported-type.test',
'semantic/parameter-accessibility.test',
'semantic/parameter-default-type.test',
'semantic/parameter-out-default.test',
'semantic/parameter-params.test',
'semantic/parameter-ref-default.test',
'semantic/parameter-void.test',
'semantic/property-abstract.test',
'semantic/property-abstract-derived-compact.test',
'semantic/property-accessibility.test',
'semantic/property-construct.test',
'semantic/property-initializer-type.test',
'semantic/property-override.test',
'semantic/property-override-class.test',
'semantic/property-override-interface.test',
'semantic/property-static-instance-access.test',
'semantic/property-struct-abstract.test',
'semantic/property-struct-override.test',
'semantic/property-struct-protected.test',
'semantic/property-struct-virtual.test',
'semantic/property-void.test',
'semantic/signal-clash-inherited.test',
'semantic/signal-compact-class.test',
'semantic/signal-detail-invalid.test',
'semantic/signal-detail-non-string.test',
'semantic/struct-derived.test',
'semantic/struct-field-initializer.test',
'semantic/struct-invalid-base.test',
'semantic/struct-recursive.test',
'semantic/switch-duplicate-label.test',
'semantic/switch-label-not-compatible.test',
'semantic/switch-label-not-constant.test',
'semantic/switch-type-unsupported.test',
'semantic/type-argument-ownership-mismatch.test',
'semantic/yield-call-requires-async-context.test',
'semantic/yield-call-requires-async-method.test',
'semantic/yield-creation-requires-async-context.test',
'semantic/yield-creation-requires-async-method.test',
]
dbus_test_cases = [
'dbus/basic-types.test',
'dbus/arrays.test',
'dbus/structs.test',
'dbus/errors.test',
'dbus/async.test',
'dbus/async-errors.test',
'dbus/enum-string-marshalling.vala',
'dbus/signals.test',
'dbus/filedescriptor.test',
'dbus/filedescriptor-async.test',
'dbus/filedescriptor-errors.test',
'dbus/dicts.test',
'dbus/bug596862.vala',
'dbus/bug602003.test',
'dbus/bug735437.test',
'dbus/bug782719.test',
'dbus/bug783002.test',
'dbus/bug792277.vala',
'dbus/rawvariants.test',
]
gir_test_cases = [
'gir/bug651773.test',
'gir/bug667751.test',
'gir/bug742012.test',
'gir/bug788775.test',
'gir/bug792998.test',
'gir/array-fixed-length.test',
'gir/async-result-pos.test',
'gir/async-sync-out.test',
'gir/class.test',
'gir/delegate-alias-without-target.test',
'gir/delegate-closure-destroy-index-conflict.test',
'gir/delegate-error-pos.test',
'gir/enum.test',
'gir/errordomain.test',
'gir/parameter-nullable-out-simple-type.test',
'gir/property-non-readable.test',
]
test_cases_non_null = [
'nullability/bug611223.vala',
'nullability/local-variable-invalid-convert.test',
'nullability/method-parameter-invalid-convert.test',
'nullability/method-return-invalid-convert.test',
]
test_cases_linux = [
'linux/bug793444.vala',
'posix/file-commandpipe.vala',
]
vala_flags = [
'--vapidir', join_paths(meson.source_root(), 'vapi'),
'--pkg', 'gio-2.0',
'--disable-warnings',
'--main', 'main', '--save-temps',
'-X', '-g',
'-X', '-O0',
'-X', '-pipe',
'-X', '-lm',
'-X', '-DGETTEXT_PACKAGE="valac"',
]
cc = meson.get_compiler('c')
if cc.get_id() == 'gcc' or cc.get_id() == 'clang'
test_cflags = [
'-Werror=init-self',
'-Werror=implicit',
'-Werror=pointer-arith',
'-Werror=redundant-decls',
'-Werror=return-type',
'-Werror=sequence-point',
'-Werror=uninitialized',
'-Werror=int-to-pointer-cast',
'-Werror=pointer-to-int-cast',
'-Wformat=2',
'-Werror=format-security',
'-Werror=format-nonliteral',
'-Werror=int-conversion',
'-Werror=duplicated-branches',
'-Werror=duplicated-cond',
'-Werror=declaration-after-statement',
'-Werror=maybe-uninitialized',
'-Werror=missing-prototypes',
'-Werror=strict-prototypes',
'-Werror=enum-conversion',
]
else
test_cflags = []
endif
supported_test_cflags = cc.get_supported_arguments(test_cflags)
foreach flag : supported_test_cflags
vala_flags += ['-X', flag]
endforeach
vg = find_program('valgrind', required: false)
if (vg.found())
add_test_setup('valgrind',
exe_wrapper: [vg, '--error-exitcode=1', '--leak-check=full', '--track-origins=yes '],
timeout_multiplier: 10,
)
endif
preparetest = find_program('prepare-test.py')
foreach case : test_cases
if case.endswith('.vala')
test(case,
valac_exe,
workdir: meson.current_build_dir(),
args: vala_flags + [join_paths(meson.current_source_dir(), case)],
)
else
invalid_case = run_command(preparetest,
join_paths(meson.current_source_dir(), case),
join_paths(meson.current_build_dir(), case.underscorify() + '.vala'),
)
test(case,
valac_exe,
workdir: meson.current_build_dir(),
should_fail: true,
args: vala_flags + [case.underscorify() + '.vala'],
)
endif
endforeach
foreach case : test_cases_non_null
if case.endswith('.vala')
test(case,
valac_exe,
workdir: meson.current_build_dir(),
args: vala_flags + ['--enable-experimental-non-null', join_paths(meson.current_source_dir(), case)],
)
else
invalid_case = run_command(preparetest,
join_paths(meson.current_source_dir(), case),
join_paths(meson.current_build_dir(), case.underscorify() + '.vala'),
)
test(case,
valac_exe,
workdir: meson.current_build_dir(),
should_fail: true,
args: vala_flags + ['--enable-experimental-non-null', case.underscorify() + '.vala'],
)
endif
endforeach
foreach case : test_cases_linux
if case.endswith('.vala')
test(case,
valac_exe,
workdir: meson.current_build_dir(),
args: vala_flags + ['--pkg', 'linux', join_paths(meson.current_source_dir(), case)],
)
endif
endforeach
#!/usr/bin/env python3
import sys, os, re
from pathlib import Path
if len(sys.argv) != 3:
print("Wrong amount of parameters.")
inputf = Path(sys.argv[1])
outputf = Path(sys.argv[2])
with inputf.open('r') as ifile:
with outputf.open('w') as ofile:
if not ifile.readline().strip() == "Invalid Code":
ifile.seek(0)
lines = ifile.readlines()
ofile.writelines(lines)
#!/bin/sh
cd "${DESTDIR}/${MESON_INSTALL_PREFIX}/mydir"
ln -s -f "${DESTDIR}/${MESON_INSTALL_PREFIX}/mydir"
touch "${DESTDIR}/${MESON_INSTALL_PREFIX}/mydir/file.dat"
install-exec-hook:
cd $(DESTDIR)$(bindir) && $(LN_S) -f vapigen@PACKAGE_SUFFIX@$(EXEEXT) vapigen$(EXEEXT)
cd $(DESTDIR)$(bindir) && $(LN_S) -f vapicheck@PACKAGE_SUFFIX@$(EXEEXT) vapicheck$(EXEEXT)
install-data-hook:
cd $(DESTDIR)$(pkgconfigdir) && $(LN_S) -f vapigen@PACKAGE_SUFFIX@.pc vapigen.pc
valacore_sources = files(
'valaaddressofexpression.vala',
'valaarraycopymethod.vala',
'valaarraycreationexpression.vala',
'valaarraylengthfield.vala',
'valaarraymovemethod.vala',
'valaarrayresizemethod.vala',
'valaarraytype.vala',
'valaassignment.vala',
'valaattribute.vala',
'valabaseaccess.vala',
'valabasicblock.vala',
'valabinaryexpression.vala',
'valablock.vala',
'valabooleanliteral.vala',
'valabooleantype.vala',
'valabreakstatement.vala',
'valacallable.vala',
'valacallabletype.vala',
'valacastexpression.vala',
'valacatchclause.vala',
'valacharacterliteral.vala',
'valaclasstype.vala',
'valaclass.vala',
'valacodecontext.vala',
'valacodegenerator.vala',
'valacodenode.vala',
'valacodevisitor.vala',
'valacodewriter.vala',
'valacomment.vala',
'valaconditionalexpression.vala',
'valaconstant.vala',
'valaconstructor.vala',
'valacontinuestatement.vala',
'valacreationmethod.vala',
'valadatatype.vala',
'valadeclarationstatement.vala',
'valadelegatetype.vala',
'valadelegate.vala',
'valadeletestatement.vala',
'valadestructor.vala',
'valadostatement.vala',
'valadynamicmethod.vala',
'valadynamicproperty.vala',
'valadynamicsignal.vala',
'valaelementaccess.vala',
'valaemptystatement.vala',
'valaenum.vala',
'valaenumvaluetype.vala',
'valaenumvalue.vala',
'valaerrorcode.vala',
'valaerrordomain.vala',
'valaerrortype.vala',
'valaexpressionstatement.vala',
'valaexpression.vala',
'valafieldprototype.vala',
'valafield.vala',
'valafloatingtype.vala',
'valaflowanalyzer.vala',
'valaforeachstatement.vala',
'valaforstatement.vala',
'valagenerictype.vala',
'valagenieparser.vala',
'valageniescanner.vala',
'valagenietokentype.vala',
'valagircomment.vala',
'valagirparser.vala',
'valaifstatement.vala',
'valainitializerlist.vala',
'valaintegerliteral.vala',
'valaintegertype.vala',
'valainterfacetype.vala',
'valainterface.vala',
'valainvalidtype.vala',
'valalambdaexpression.vala',
'valaliteral.vala',
'valalocalvariable.vala',
'valalockable.vala',
'valalockstatement.vala',
'valaloop.vala',
'valamarkupreader.vala',
'valamemberaccess.vala',
'valamemberinitializer.vala',
'valamethodcall.vala',
'valamethodtype.vala',
'valamethod.vala',
'valanamedargument.vala',
'valanamespace.vala',
'valanullliteral.vala',
'valanulltype.vala',
'valaobjectcreationexpression.vala',
'valaobjecttypesymbol.vala',
'valaobjecttype.vala',
'valaparameter.vala',
'valaparser.vala',
'valaphifunction.vala',
'valapointerindirection.vala',
'valapointertype.vala',
'valapostfixexpression.vala',
'valaprofile.vala',
'valapropertyaccessor.vala',
'valaproperty.vala',
'valapropertyprototype.vala',
'valarealliteral.vala',
'valareferencetransferexpression.vala',
'valareferencetype.vala',
'valaregexliteral.vala',
'valareport.vala',
'valareturnstatement.vala',
'valascanner.vala',
'valascope.vala',
'valasemanticanalyzer.vala',
'valasignaltype.vala',
'valasignal.vala',
'valasizeofexpression.vala',
'valasliceexpression.vala',
'valasourcefile.vala',
'valasourcelocation.vala',
'valasourcereference.vala',
'valastatementlist.vala',
'valastatement.vala',
'valastringliteral.vala',
'valastruct.vala',
'valastructvaluetype.vala',
'valasubroutine.vala',
'valaswitchlabel.vala',
'valaswitchsection.vala',
'valaswitchstatement.vala',
'valasymbolresolver.vala',
'valasymbol.vala',
'valatargetvalue.vala',
'valatemplate.vala',
'valathrowstatement.vala',
'valatokentype.vala',
'valatrystatement.vala',
'valatuple.vala',
'valatypecheck.vala',
'valatypeofexpression.vala',
'valatypeparameter.vala',
'valatypesymbol.vala',
'valaunaryexpression.vala',
'valaunlockstatement.vala',
'valaunresolvedsymbol.vala',
'valaunresolvedtype.vala',
'valausedattr.vala',
'valausingdirective.vala',
'valavaluetype.vala',
'valavariable.vala',
'valaversionattribute.vala',
'valavoidtype.vala',
'valawhilestatement.vala',
'valayieldstatement.vala',
)
valaversion_source = configure_file(
input: 'valaversion.vala.in',
output: 'valaversion.vala',
configuration: versionconf,
)
valacore_lib = shared_library(
'vala@0@'.format(vala_version_suffix),
valacore_sources,
valaversion_source,
dependencies: [gobject_dep, gmodule_dep, valagee_dep],
soversion: '0.0.0',
install: true,
vala_args: ['--use-header'],
vala_header: 'vala.h',
vala_vapi: 'vala.vapi',
install_dir: [
true,
join_paths (get_option('includedir'), 'vala@0@'.format (vala_version_suffix)),
false
],
)
valacore_dep = declare_dependency(
link_with: [valacore_lib],
dependencies: [valagee_dep],
include_directories: include_directories('.', '..'),
)
doclet_devhelp_sources = files(
'doclet.vala',
)
shared_module(
'doclet',
doclet_devhelp_sources,
dependencies: [gobject_dep, libvaladoc_dep],
install: true,
install_dir: join_paths(get_option('libdir'), 'valadoc', 'doclets', 'devhelp'),
)
doclet_gtkdoc_sources = files(
'commentconverter.vala',
'dbus.vala',
'doclet.vala',
'gcomment.vala',
'generator.vala',
'utils.vala',
)
shared_module(
'doclet',
doclet_gtkdoc_sources,
dependencies: [gobject_dep, libvaladoc_dep],
install: true,
install_dir: join_paths (get_option('libdir'), 'valadoc', 'doclets', 'gtkdoc'),
)
doclet_html_sources = files(
'doclet.vala',
)
shared_module(
'doclet',
doclet_html_sources,
dependencies: [gobject_dep, libvaladoc_dep],
install: true,
install_dir: join_paths (get_option('libdir'), 'valadoc', 'doclets', 'html'),
c_args: ['-DPACKAGE_VALADOC_ICONDIR="@0@"'.format(join_paths(get_option('prefix'), get_option('datadir'), 'valadoc', 'icons'))],
)
# FIXME clashing shared_module targetnames
#subdir('devhelp')
#subdir('gtkdoc')
subdir('html')
valadoc_data = files(
'abstractclass.png',
'abstractmethod.png',
'abstractproperty.png',
'class.png',
'coll_close.png',
'coll_open.png',
'constant.png',
'constructor.png',
'delegate.png',
'devhelpstyle.css',
'enum.png',
'enumvalue.png',
'errorcode.png',
'errordomain.png',
'field.png',
'interface.png',
'method.png',
'namespace.png',
'package.png',
'packages.png',
'property.png',
'scripts.js',
'signal.png',
'staticmethod.png',
'struct.png',
'style.css',
'tip.png',
'virtualmethod.png',
'virtualproperty.png',
'warning.png',
'wikistyle.css',
)
install_data(
valadoc_data,
install_dir: join_paths('share', 'valadoc', 'icons'),
)
valadoc_sources = files(
'driver.vala',
'girwriter.vala',
'initializerbuilder.vala',
'symbolresolver.vala',
'treebuilder.vala',
'valadoc.vala',
)
valadoc_name = 'valadoc@0@'.format(vala_version_suffix)
valadoc_exe = executable(
valadoc_name,
valadoc_sources,
dependencies: [gobject_dep, valacodegen_dep, libvaladoc_dep],
install: true,
)
# https://github.com/mesonbuild/meson/issues/1602
meson.add_install_script('sh', '-c', 'cd $DESTDIR@0@; ln -fs --relative @1@ valadoc'.format(join_paths(get_option('prefix'), get_option('bindir')), valadoc_name))
subdir('doclets')
subdir('icons')
vapis = files(
'alsa.vapi',
'alsa.deps',
'atk.vapi',
'atspi-2.vapi',
'atspi-2.deps',
'avahi-client.vapi',
'avahi-gobject.deps',
'avahi-gobject.vapi',
'bzlib.vapi',
'cairo.vapi',
'cairo-xcb.deps',
'cairo-xcb.vapi',
'ccss-1.vapi',
'clutter-1.0.deps',
'clutter-1.0.vapi',
'clutter-gdk-1.0.deps',
'clutter-gdk-1.0.vapi',
'clutter-gst-2.0.deps',
'clutter-gst-2.0.vapi',
'clutter-gst-3.0.deps',
'clutter-gst-3.0.vapi',
'clutter-gtk-0.10.deps',
'clutter-gtk-0.10.vapi',
'clutter-gtk-1.0.deps',
'clutter-gtk-1.0.vapi',
'clutter-x11-1.0.deps',
'clutter-x11-1.0.vapi',
'cogl-1.0.vapi',
'cogl-1.0.deps',
'cogl-pango-1.0.vapi',
'cogl-pango-1.0.deps',
'curses.vapi',
'dbus-glib-1.vapi',
'enchant.vapi',
'fuse.deps',
'fuse.vapi',
'gconf-2.0.vapi',
'geocode-glib-1.0.deps',
'geocode-glib-1.0.vapi',
'glib-2.0.vapi',
'gdesktopenums-3.0.vapi',
'gdk-2.0.deps',
'gdk-2.0.vapi',
'gdk-3.0.deps',
'gdk-3.0.vapi',
'gdk-pixbuf-2.0.deps',
'gdk-pixbuf-2.0.vapi',
'gdk-x11-2.0.deps',
'gdk-x11-2.0.vapi',
'gdk-x11-3.0.deps',
'gdk-x11-3.0.vapi',
'gdl-1.0.deps',
'gdl-1.0.vapi',
'gdl-3.0.deps',
'gdl-3.0.vapi',
'gedit-2.20.vapi',
'gedit-2.20.deps',
'gio-2.0.vapi',
'gio-unix-2.0.deps',
'gio-unix-2.0.vapi',
'gio-windows-2.0.deps',
'gio-windows-2.0.vapi',
'gmodule-2.0.vapi',
'gnet-2.0.deps',
'gnet-2.0.vapi',
'gnome-desktop-2.0.deps',
'gnome-desktop-2.0.vapi',
'gnome-desktop-3.0.deps',
'gnome-desktop-3.0.vapi',
'gnome-vfs-2.0.vapi',
'gnutls.vapi',
'gobject-2.0.vapi',
'gobject-introspection-1.0.vapi',
'goocanvas.deps',
'goocanvas.vapi',
'goocanvas-2.0.deps',
'goocanvas-2.0.vapi',
'graphene-1.0.deps',
'graphene-1.0.vapi',
'gsl.vapi',
'gstreamer-1.0.vapi',
'gstreamer-allocators-1.0.vapi',
'gstreamer-allocators-1.0.deps',
'gstreamer-app-1.0.vapi',
'gstreamer-app-1.0.deps',
'gstreamer-audio-1.0.vapi',
'gstreamer-audio-1.0.deps',
'gstreamer-bad-allocators-1.0.deps',
'gstreamer-bad-allocators-1.0.vapi',
'gstreamer-base-1.0.vapi',
'gstreamer-base-1.0.deps',
'gstreamer-check-1.0.vapi',
'gstreamer-check-1.0.deps',
'gstreamer-controller-1.0.vapi',
'gstreamer-controller-1.0.deps',
'gstreamer-fft-1.0.vapi',
'gstreamer-fft-1.0.deps',
'gstreamer-net-1.0.vapi',
'gstreamer-net-1.0.deps',
'gstreamer-pbutils-1.0.vapi',
'gstreamer-pbutils-1.0.deps',
'gstreamer-player-1.0.vapi',
'gstreamer-player-1.0.deps',
'gstreamer-riff-1.0.deps',
'gstreamer-riff-1.0.vapi',
'gstreamer-rtp-1.0.vapi',
'gstreamer-rtp-1.0.deps',
'gstreamer-rtsp-1.0.vapi',
'gstreamer-rtsp-1.0.deps',
'gstreamer-rtsp-server-1.0.vapi',
'gstreamer-rtsp-server-1.0.deps',
'gstreamer-sdp-1.0.vapi',
'gstreamer-sdp-1.0.deps',
'gstreamer-tag-1.0.vapi',
'gstreamer-tag-1.0.deps',
'gstreamer-video-1.0.vapi',
'gstreamer-video-1.0.deps',
'gstreamer-webrtc-1.0.vapi',
'gstreamer-webrtc-1.0.deps',
'gst-editing-services-1.0.vapi',
'gst-editing-services-1.0.deps',
'gtk+-2.0.deps',