Mercurial > mxe-octave
annotate src/openexr.mk @ 5297:cf95c2205f38
* src/openexr.mk: dont depend on external ilmbase
author | John Donoghue <john.donoghue@ieee.org> |
---|---|
date | Sun, 09 Feb 2020 09:15:27 -0500 |
parents | c855d59598ec |
children | 01b7cef56cf7 |
rev | line source |
---|---|
2333
f653602a0500
Rebrand to new project name MXE
Volker Grabsch <vog@notjusthosting.com>
parents:
2256
diff
changeset
|
1 # This file is part of MXE. |
2353
99516e73b368
Move doc/index.html -> index.html
Volker Grabsch <vog@notjusthosting.com>
parents:
2349
diff
changeset
|
2 # See index.html for further information. |
414
d2a6561bcb6d
add a copyright notice and license to each source file
Volker Grabsch <vog@notjusthosting.com>
parents:
306
diff
changeset
|
3 |
306
85ffa9259036
validate downloads using SHA-1 checksums
Volker Grabsch <vog@notjusthosting.com>
parents:
266
diff
changeset
|
4 PKG := openexr |
448
e9afec55fd6b
improved version recognition, enable the notation of ignored (bad) package versions
Volker Grabsch <vog@notjusthosting.com>
parents:
417
diff
changeset
|
5 $(PKG)_IGNORE := |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
6 $(PKG)_VERSION := 2.4.0 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
7 $(PKG)_CHECKSUM := 0b9a24b8fa6b3f7f1d8813e91234308d3e43d10f |
306
85ffa9259036
validate downloads using SHA-1 checksums
Volker Grabsch <vog@notjusthosting.com>
parents:
266
diff
changeset
|
8 $(PKG)_SUBDIR := openexr-$($(PKG)_VERSION) |
85ffa9259036
validate downloads using SHA-1 checksums
Volker Grabsch <vog@notjusthosting.com>
parents:
266
diff
changeset
|
9 $(PKG)_FILE := openexr-$($(PKG)_VERSION).tar.gz |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
10 $(PKG)_URL := https://github.com/$(PKG)/$(PKG)/archive/v$($(PKG)_VERSION).tar.gz |
5297
cf95c2205f38
* src/openexr.mk: dont depend on external ilmbase
John Donoghue <john.donoghue@ieee.org>
parents:
5175
diff
changeset
|
11 $(PKG)_DEPS := pthreads zlib |
240
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
12 |
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
13 define $(PKG)_UPDATE |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
14 $(WGET) -q -O- 'https://github.com/$(PKG)/$(PKG)/tags' | \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
15 $(SED) -n 's|.*releases/tag/v\([^"]*\).*|\1|p' | \ |
240
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
16 head -1 |
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
17 endef |
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
18 |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
19 ifeq ($(MXE_NATIVE_BUILD),yes) |
240
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
20 define $(PKG)_BUILD |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
21 mkdir '$(1)/build' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
22 cd '$(1)/build' && cmake .. \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
23 -DCMAKE_TOOLCHAIN_FILE='$(CMAKE_TOOLCHAIN_FILE)' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
24 -DBUILD_TESTING='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
25 -DPYILMBASE_ENABLE='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
26 -DOPENEXR_VIEWERS_ENABLE='OFF' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
27 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
28 $(MAKE) -C '$(1)/build' -j '$(JOBS)' VERBOSE=1 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
29 $(MAKE) -C '$(1)/build' -j 1 install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= DESTDIR='$(3)' |
240
9a4d6e48157b
new package: openexr (by Martin Lambers)
Volker Grabsch <vog@notjusthosting.com>
parents:
diff
changeset
|
30 endef |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
31 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
32 else |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
33 define $(PKG)_BUILD |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
34 # native build of parts |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
35 mkdir '$(1)/native' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
36 cd '$(1)/native' && cmake .. \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
37 -DCMAKE_BUILD_TYPE='Release' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
38 -DBUILD_SHARED_LIBS='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
39 -DBUILD_TESTING='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
40 -DPYILMBASE_ENABLE='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
41 -DOPENEXR_VIEWERS_ENABLE='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
42 -DCMAKE_FIND_ROOT_PATH='$(ROOT_PREFIX)' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
43 $(MAKE) -C '$(1)/native/IlmBase/Half/' eLut toFloat VERBOSE=1 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
44 $(MAKE) -C '$(1)/native/OpenEXR/IlmImf' dwaLookups b44ExpLogTable VERBOSE=1 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
45 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
46 # cross compile part |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
47 mkdir '$(1)/build' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
48 cd '$(1)/build' && cmake .. \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
49 -DCMAKE_TOOLCHAIN_FILE='$(CMAKE_TOOLCHAIN_FILE)' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
50 -DBUILD_TESTING='OFF' \ |
5175
c855d59598ec
* src/openexr.mk: in cross build, disable lib suffix
John Donoghue
parents:
5171
diff
changeset
|
51 -DCMAKE_VERBOSE_MAKEFILE='ON' \ |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
52 -DPYILMBASE_ENABLE='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
53 -DOPENEXR_VIEWERS_ENABLE='OFF' \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
54 -DOPENEXR_INSTALL_PKG_CONFIG='ON' \ |
5175
c855d59598ec
* src/openexr.mk: in cross build, disable lib suffix
John Donoghue
parents:
5171
diff
changeset
|
55 -DILMBASE_LIB_SUFFIX='' \ |
c855d59598ec
* src/openexr.mk: in cross build, disable lib suffix
John Donoghue
parents:
5171
diff
changeset
|
56 -DOPENEXR_LIB_SUFFIX='' \ |
5171
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
57 -DCMAKE_CXX_STANDARD=11 \ |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
58 -DCMAKE_CXX_FLAGS='-D_WIN32_WINNT=0x0500' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
59 $(MAKE) -C '$(1)/build/IlmBase/Half/' eLut toFloat VERBOSE=1 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
60 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
61 # now use native build generators |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
62 cd '$(1)/build/IlmBase/Half/' && '$(1)/native/IlmBase/Half/toFloat' > toFloat.h |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
63 cd '$(1)/build/IlmBase/Half/' && '$(1)/native/IlmBase/Half/eLut' > eLut.h |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
64 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
65 $(MAKE) -C '$(1)/build/OpenEXR/IlmImf' dwaLookups b44ExpLogTable VERBOSE=1 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
66 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
67 cd '$(1)/build/OpenEXR/IlmImf/' && '$(1)/native/bin/dwaLookups' > dwaLookups.h |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
68 cd '$(1)/build/OpenEXR/IlmImf/' && '$(1)/native/bin/b44ExpLogTable' > b44ExpLogTable.h |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
69 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
70 $(MAKE) -C '$(1)/build' -j '$(JOBS)' VERBOSE=1 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
71 $(MAKE) -C '$(1)/build' -j 1 install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= DESTDIR='$(3)' |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
72 |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
73 endef |
6215676cc6ff
* src/openexr.mk: update openexr, handle native and cross builds
John Donoghue
parents:
3628
diff
changeset
|
74 endif |