diff options
author | Daiki Ueno <dueno@redhat.com> | 2019-05-15 13:09:25 +0200 |
---|---|---|
committer | Daiki Ueno <ueno@gnu.org> | 2019-06-18 14:17:28 +0200 |
commit | 4f956698b64ac6eb8e5e8b7d143ceb11f1133814 (patch) | |
tree | 95b8c43ebcddf75f04ac900523e35882a14ae4d4 /p11-kit/gen-pkcs11-gnu.sh | |
parent | 411a7a6d31cd5584ff9837260d77d8c306d3b557 (diff) |
build: Add meson build support
This adds support for meson as an alternative build system.
Diffstat (limited to 'p11-kit/gen-pkcs11-gnu.sh')
-rwxr-xr-x | p11-kit/gen-pkcs11-gnu.sh | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/p11-kit/gen-pkcs11-gnu.sh b/p11-kit/gen-pkcs11-gnu.sh new file mode 100755 index 0000000..a8b204d --- /dev/null +++ b/p11-kit/gen-pkcs11-gnu.sh @@ -0,0 +1,16 @@ +#!/bin/sh + +source="$1" +target="$2" + +rm -f $target-t $target && \ + { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ + echo; \ + echo '#include <stdlib.h>'; \ + echo '#include "p11-kit/p11-kit.h"'; \ + cat $source; \ + echo "void *${target}_funcs[] = {" | sed 's/[^][ *a-z0-9_={]/_/g'; \ + sed -n -e '/^typedef/d' -e 's/.* \(p11_kit_[^ ]*\) *(.*/ \1,/p' $source; \ + echo '};'; \ + } > $target-t && \ + mv -f $target-t $target |