summaryrefslogtreecommitdiffstats
path: root/contrib/x265_10bit/module.defs
blob: a4a5916f9c9b1e4f74f92c38ff4aae68329d402f (plain)
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
__deps__ := X265_8
$(eval $(call import.MODULE.defs,X265_10,x265_10,$(__deps__),x265))
$(eval $(call import.CONTRIB.defs,X265_10))

X265_10.FETCH.url     = https://download.handbrake.fr/contrib/x265_3.1.1.tar.gz
X265_10.FETCH.url    += https://bitbucket.org/multicoreware/x265/downloads/x265_3.1.1.tar.gz
X265_10.FETCH.url    += https://download.videolan.org/pub/videolan/x265/x265_3.1.1.tar.gz
X265_10.FETCH.sha256  = 827900c7cc0a0105b8a96460fab7cd22b97afa7b2835b5cb979c44bddaa3c8d0
X265_10.EXTRACT.tarbase = x265_3.1.1

# Silence "warning: overriding recipe for target" messages
X265_10.FETCH.target =

X265_10.build_dir             = 10bit
X265_10.CONFIGURE.exe         = cmake
X265_10.CONFIGURE.args.prefix = -DCMAKE_INSTALL_PREFIX="$(X265_10.CONFIGURE.prefix)"
X265_10.CONFIGURE.deps        =
X265_10.CONFIGURE.static      =
X265_10.CONFIGURE.shared      = -DENABLE_SHARED=OFF
X265_10.CONFIGURE.extra       = -DENABLE_CLI=OFF -DHIGH_BIT_DEPTH=ON -DEXPORT_C_API=OFF

ifneq (1,$(FEATURE.numa))
    X265_10.CONFIGURE.extra  += -DENABLE_LIBNUMA=OFF
endif

ifneq (none,$(X265_10.GCC.g))
    X265_10.CONFIGURE.extra += -DCMAKE_BUILD_TYPE=Debug
else
    X265_10.CONFIGURE.extra += -DCMAKE_BUILD_TYPE=Release
endif

ifeq (1,$(HOST.cross))
    ifeq (mingw,$(HOST.system))
        X265_10.CONFIGURE.extra += -DWIN32=ON
        X265_10.CONFIGURE.extra += -DCMAKE_SYSTEM_NAME=Windows
        X265_10.CONFIGURE.extra += -DCMAKE_C_COMPILER=$(X265_10.GCC.gcc)
        X265_10.CONFIGURE.extra += -DCMAKE_C_FLAGS="-static-libgcc -static-libstdc++ -static"
        X265_10.CONFIGURE.extra += -DCMAKE_SHARED_LIBRARY_LINK_C_FLAGS="-static-libgcc -static-libstdc++ -static"
        X265_10.CONFIGURE.extra += -DCMAKE_CXX_COMPILER=$(X265_10.GCC.gxx)
        X265_10.CONFIGURE.extra += -DCMAKE_CXX_FLAGS="-static-libgcc -static-libstdc++ -static"
        X265_10.CONFIGURE.extra += -DCMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS="-static-libgcc -static-libstdc++ -static"
        X265_10.CONFIGURE.extra += -DCMAKE_RC_COMPILER=$(HOST.cross.prefix)windres
    endif
    X265_10.CONFIGURE.args.host  = -DCMAKE_SYSTEM_NAME="$(X265_10.CONFIGURE.host)"
    X265_10.CONFIGURE.args.build = -DCMAKE_HOST_SYSTEM="$(X265_10.CONFIGURE.build)"
else
    X265_10.CONFIGURE.args.host  = -DCMAKE_HOST_SYSTEM="$(X265_10.CONFIGURE.host)"
endif

## find CMakeLists.txt
X265_10.CONFIGURE.extra += "$(call fn.ABSOLUTE,$(X265_10.EXTRACT.dir/)source/)"

X265_10.INSTALL.make = $(MV.exe)
X265_10.INSTALL.args.dir = cd $(1);
X265_10.INSTALL.extra = libx265.a libx265_main10.a
X265_10.INSTALL.args = @dir !make !extra

# Override operations that are not needed
X265_10.FETCH =
X265_10.VERIFY = $(TOUCH.exe) $@
X265_10.EXTRACT = $(TOUCH.exe) $@
X265_10.PATCH = $(TOUCH.exe) $@
X265_10.XCLEAN =