mirror of
https://github.com/ivabus/pantry
synced 2024-11-14 04:25:08 +03:00
51 lines
1.2 KiB
YAML
51 lines
1.2 KiB
YAML
|
distributable:
|
||
|
url: https://github.com/uclouvain/openjpeg/archive/v2.5.0.tar.gz
|
||
|
strip-components: 1
|
||
|
|
||
|
versions:
|
||
|
github: uclouvain/openjpeg/tags
|
||
|
|
||
|
dependencies:
|
||
|
libpng.org: ^1
|
||
|
simplesystems.org/libtiff: ^4
|
||
|
|
||
|
build:
|
||
|
dependencies:
|
||
|
tea.xyz/gx/cc: c99
|
||
|
tea.xyz/gx/make: '*'
|
||
|
cmake.org: ^3
|
||
|
working-directory: build
|
||
|
script: |
|
||
|
cmake .. -DCMAKE_INSTALL_PREFIX={{prefix}} -DCMAKE_BUILD_TYPE=Release
|
||
|
make --jobs {{ hw.concurrency }} install
|
||
|
|
||
|
# fix unecessary prefixification of headers
|
||
|
cd {{prefix}}/include
|
||
|
mv openjpeg-{{version.marketing}}/* .
|
||
|
rmdir openjpeg-{{version.marketing}}
|
||
|
# keep unecessary prefixification for tools that expect it for some reason
|
||
|
ln -s . openjpeg-{{version.marketing}}
|
||
|
|
||
|
provides:
|
||
|
- bin/opj_compress
|
||
|
- bin/opj_decompress
|
||
|
- bin/opj_dump
|
||
|
|
||
|
test:
|
||
|
dependencies:
|
||
|
tea.xyz/gx/cc: c99
|
||
|
script: |
|
||
|
mv $FIXTURE test.c
|
||
|
cc test.c -lopenjp2
|
||
|
./a.out
|
||
|
fixture: |
|
||
|
#include <openjpeg.h>
|
||
|
int main () {
|
||
|
opj_image_cmptparm_t cmptparm;
|
||
|
const OPJ_COLOR_SPACE color_space = OPJ_CLRSPC_GRAY;
|
||
|
opj_image_t *image;
|
||
|
image = opj_image_create(1, &cmptparm, color_space);
|
||
|
opj_image_destroy(image);
|
||
|
return 0;
|
||
|
}
|