challenger

OAuth 2.0-based authentication service that validates user can receive messages at a certain address
Log | Files | Refs | Submodules | README | LICENSE

meson.build (2695B)


      1 # This file is in the public domain
      2 
      3 install_data('challenger_db_postgres.conf', install_dir: pkgcfgdir)
      4 
      5 
      6 sqldir = get_option('datadir') / 'challenger' / 'sql'
      7 
      8 # FIXME possibly provide this output in the tgz through dist script
      9 run_command('make', '-f', 'Makefile.sql', 'all', check: true)
     10 
     11 sql_DATA = [
     12     'versioning.sql',
     13     'procedures.sql',
     14     'challenger-0001.sql',
     15     'challenger-0002.sql',
     16     'drop.sql',
     17 ]
     18 
     19 install_data(sources: sql_DATA, install_dir: sqldir)
     20 
     21 # This makes meson copy the files into the build directory for testing
     22 foreach f : sql_DATA
     23     configure_file(input: f, output: f, copy: true)
     24 endforeach
     25 
     26 
     27 
     28 libchallengerdb_SOURCES = [
     29     'address_get.c',
     30     'client_add.c',
     31     'client_modify.c',
     32     'client_delete.c',
     33     'client_check.c',
     34     'create_tables.c',
     35     'drop_tables.c',
     36     'gc.c',
     37     'info_get_token.c',
     38     'token_add_token.c',
     39     'setup_nonce.c',
     40     'preflight.c',
     41     'pg.c',
     42     'authorize_start.c',
     43     'challenge_set_address_and_pin.c',
     44     'validate_solve_pin.c',
     45     'validation_get.c',
     46     'validation_get_pkce.c',
     47 ]
     48 libchallengerdb = library(
     49     'challengerdb',
     50     libchallengerdb_SOURCES,
     51     soversion: solibversions['libchallengerdb']['soversion'],
     52     version: solibversions['libchallengerdb']['soversion'],
     53     install_rpath: rpath_option,
     54     dependencies: [
     55         libchallengerutil_dep,
     56         talerpq_dep,
     57         gnunetutil_dep,
     58         gnunetpq_dep,
     59         pq_dep,
     60     ],
     61     include_directories: [incdir, configuration_inc],
     62     install: true,
     63     install_dir: get_option('libdir'),
     64 )
     65 
     66 libchallengerdb_dep = declare_dependency(link_with: libchallengerdb)
     67 pkg.generate(
     68     libchallengerdb,
     69     url: 'https://taler.net',
     70     description: 'GNU Taler challenger DB library',
     71 )
     72 
     73 executable(
     74     'challenger-dbinit',
     75     ['challenger-dbinit.c'],
     76     dependencies: [
     77         libchallengerutil_dep,
     78         libchallengerdb_dep,
     79         gnunetutil_dep,
     80         talerutil_dep,
     81     ],
     82     include_directories: [incdir, configuration_inc],
     83     install: true,
     84 )
     85 
     86 configure_file(
     87     input: 'test_challenger_db_postgres.conf',
     88     output: 'test_challenger_db_postgres.conf',
     89     copy: true,
     90 )
     91 
     92 test_challenger_db_postgres = executable(
     93     'test_challenger_db-postgres',
     94     ['test_challenger_db.c'],
     95     dependencies: [
     96         gnunetutil_dep,
     97         libchallengerutil_dep,
     98         libchallengerdb_dep,
     99         gnunetpq_dep,
    100         talerutil_dep,
    101     ],
    102     include_directories: [incdir, configuration_inc],
    103     build_by_default: false,
    104     install: false,
    105 )
    106 test(
    107     'test_challenger_db-postgres',
    108     test_challenger_db_postgres,
    109     workdir: meson.current_build_dir(),
    110     suite: ['challengerdb'],
    111     is_parallel: false,
    112 )