1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
|
#!/bin/sh
set -e
cd "$AUTOPKGTEST_TMP"
if [ -n "${DEB_HOST_GNU_TYPE:-}" ]; then
CROSS_COMPILE="$DEB_HOST_GNU_TYPE-"
else
CROSS_COMPILE=
fi
cat >wmf-api.c <<EOF
#include <libwmf/api.h>
#include <libwmf/gd.h>
int main (void) {
wmfAPI_Options options;
wmfAPI* API;
wmf_error_t error;
unsigned long flags;
/* */
flags = WMF_OPT_FUNCTION;
options.function = wmf_gd_function;
/* Other Options */
error = wmf_api_create (&API,flags,&options);
return error == wmf_E_None;
}
EOF
${CROSS_COMPILE}gcc -o wmf-api wmf-api.c $("${CROSS_COMPILE}pkg-config" --cflags --libs libwmf)
test -x wmf-api
echo "everything seems OK"
|