2020-07-24 12:43:33 +02:00
|
|
|
#!/bin/sh
|
|
|
|
# Helper script to recompute error codes based on submodule
|
|
|
|
# Run from exchange/ main directory.
|
|
|
|
set -eu
|
|
|
|
|
2022-05-11 10:27:50 +02:00
|
|
|
domake ()
|
|
|
|
{
|
2022-06-04 14:59:14 +02:00
|
|
|
# $1 -- dir under contrib/
|
|
|
|
dir="contrib/$1"
|
2022-05-11 10:27:50 +02:00
|
|
|
|
|
|
|
make -C $dir
|
|
|
|
}
|
|
|
|
|
|
|
|
ensure ()
|
|
|
|
{
|
|
|
|
# $1 -- filename
|
2022-06-04 14:59:14 +02:00
|
|
|
# $2 -- src dir under contrib/
|
2022-05-11 10:27:50 +02:00
|
|
|
# $3 -- dst dir under ./
|
|
|
|
fn="$1"
|
2022-06-30 09:32:29 +02:00
|
|
|
src="contrib/$2/$fn"
|
|
|
|
dst="./$3/$fn"
|
2022-05-11 10:27:50 +02:00
|
|
|
|
2022-06-30 09:32:29 +02:00
|
|
|
if ! diff $src $dst > /dev/null
|
2021-08-01 13:56:48 +02:00
|
|
|
then
|
2022-06-30 09:32:29 +02:00
|
|
|
cp $src $dst
|
|
|
|
chmod -w $dst
|
2021-08-01 13:56:48 +02:00
|
|
|
fi
|
2022-05-11 10:27:50 +02:00
|
|
|
}
|
|
|
|
|
2022-06-04 14:59:14 +02:00
|
|
|
domake gana/gnu-taler-error-codes
|
|
|
|
ensure taler_error_codes.c gana/gnu-taler-error-codes src/util
|
|
|
|
ensure taler_error_codes.h gana/gnu-taler-error-codes src/include
|
2022-05-11 10:27:50 +02:00
|
|
|
|
2022-06-04 14:59:14 +02:00
|
|
|
domake gana/gnu-taler-db-events
|
|
|
|
ensure taler_dbevents.h gana/gnu-taler-db-events src/include
|
2022-06-06 08:59:59 +02:00
|
|
|
|
|
|
|
domake sigp
|
|
|
|
ensure taler_signatures.h sigp src/include
|