forked from Freetz/freetz
-
-
Notifications
You must be signed in to change notification settings - Fork 108
/
Copy pathopenjp2.mk
77 lines (60 loc) · 2.59 KB
/
openjp2.mk
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
$(call PKG_INIT_LIB, a5891555eb49ed7cc26b2901ea680acda136d811)
$(PKG)_LIB_VERSION:=2.5.0
$(PKG)_SOURCE:=$(pkg)-$($(PKG)_VERSION).tar.gz
$(PKG)_HASH:=eb777df08834b9d0293763077581709c8fb38ab0e253c74e9f9b33bc45ec324c
$(PKG)_SITE:=git@https://github.com/uclouvain/openjpeg.git
### VERSION:=2.5.0
### WEBSITE:=https://www.openjpeg.org/
### MANPAGE:=https://github.com/uclouvain/openjpeg/wiki
### CHANGES:=https://github.com/uclouvain/openjpeg/blob/master/NEWS.md
### CVSREPO:=https://github.com/uclouvain/openjpeg
$(PKG)_LIBNAME:=libopenjp2.so.$($(PKG)_LIB_VERSION)
$(PKG)_BINARY:=$($(PKG)_DIR)/bin/$($(PKG)_LIBNAME)
$(PKG)_STAGING_BINARY:=$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/$($(PKG)_LIBNAME)
$(PKG)_TARGET_BINARY:=$($(PKG)_TARGET_DIR)/$($(PKG)_LIBNAME)
$(PKG)_DEPENDS_ON += cmake-host
$(PKG)_CONFIGURE_OPTIONS += -DCMAKE_INSTALL_PREFIX="/"
$(PKG)_CONFIGURE_OPTIONS += -DCMAKE_SKIP_INSTALL_RPATH=NO
$(PKG)_CONFIGURE_OPTIONS += -DCMAKE_SKIP_RPATH=NO
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_SHARED_LIBS=ON
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_STATIC_LIBS=ON
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_DOC=OFF
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_JAVA=OFF
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_JPIP=OFF
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_LUTS_GENERATOR=OFF
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_TESTING=OFF
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_THIRDPARTY=OFF
$(PKG)_CONFIGURE_OPTIONS += -DBUILD_UNIT_TESTS=OFF
$(PKG)_CONFIGURE_OPTIONS += -DLCMS_INCLUDE_DIR=""
$(PKG)_CONFIGURE_OPTIONS += -DLCMS2_INCLUDE_DIR=""
$(PKG)_CONFIGURE_OPTIONS += -DTIFF_INCLUDE_DIR=""
$(PKG)_CONFIGURE_OPTIONS += -DZLIB_INCLUDE_DIR=""
$(PKG)_CONFIGURE_OPTIONS += -DPNG_INCLUDE_DIR=""
$(PKG)_CONFIGURE_OPTIONS += -DPNG_PNG_INCLUDE_DIR=""
$(PKG_SOURCE_DOWNLOAD)
$(PKG_UNPACKED)
$(PKG_CONFIGURED_CMAKE)
$($(PKG)_BINARY): $($(PKG)_DIR)/.configured
$(SUBMAKE) -C $(OPENJP2_DIR)
#cmake cd $(GETDNS_DIR) && cmake -LA .
$($(PKG)_STAGING_BINARY): $($(PKG)_BINARY)
$(SUBMAKE) -C $(OPENJP2_DIR) \
DESTDIR=$(TARGET_TOOLCHAIN_STAGING_DIR) \
install
$(PKG_FIX_LIBTOOL_LA) \
$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/pkgconfig/libopenjp2.pc
@touch $@
$($(PKG)_TARGET_BINARY): $($(PKG)_STAGING_BINARY)
$(INSTALL_LIBRARY_STRIP)
$(pkg): $($(PKG)_STAGING_BINARY)
$(pkg)-precompiled: $($(PKG)_TARGET_BINARY)
$(pkg)-clean:
-$(SUBMAKE) -C $(OPENJP2_DIR) clean
$(RM) -r \
$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/openjpeg-2.5/ \
$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/include/openjpeg-2.5/ \
$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/pkgconfig/libopenjp2.pc \
$(TARGET_TOOLCHAIN_STAGING_DIR)/usr/lib/libopenjp2.*
$(pkg)-uninstall:
$(RM) $(OPENJP2_TARGET_DIR)/libopenjp2.so*
$(PKG_FINISH)