pngquant.org/lib (#2287)

* new file:   projects/pngquant.org/lib/package.yml
	new file:   projects/pngquant.org/lib/test.c

* script shorter
This commit is contained in:
Andrew 2023-06-24 23:42:42 +03:00 committed by GitHub
parent bb01b94787
commit 70373666f1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 36 additions and 0 deletions

View file

@ -0,0 +1,25 @@
distributable:
url: https://github.com/ImageOptim/libimagequant/archive/{{version}}.tar.gz
strip-components: 1
versions:
github: ImageOptim/libimagequant/tags
display-name: libimagequant
build:
dependencies:
tea.xyz/gx/cc: c99
tea.xyz/gx/make: '*'
github.com/lu-zero/cargo-c: '*'
rust-lang.org/cargo: '*'
working-directory: imagequant-sys
script: cargo cinstall --prefix {{prefix}}
test:
dependencies:
tea.xyz/gx/cc: c99
script:
- cc test.c -limagequant -o test
- ./test

View file

@ -0,0 +1,11 @@
#include <libimagequant.h>
int main() {
liq_attr *attr = liq_attr_create();
if (!attr) {
return 1;
} else {
liq_attr_destroy(attr);
return 0;
}
}