Lines 23-29
OPTIONS_DEFAULT= OPTIMIZED_FLAGS HI8P HI10P HI12P
Link Here
|
23 |
OPTIONS_DEFINE_aarch64= ASM |
23 |
OPTIONS_DEFINE_aarch64= ASM |
24 |
OPTIONS_DEFINE_amd64= ASM SVTHEVC |
24 |
OPTIONS_DEFINE_amd64= ASM SVTHEVC |
25 |
OPTIONS_DEFINE_i386= ASM |
25 |
OPTIONS_DEFINE_i386= ASM |
|
|
26 |
OPTIONS_DEFINE_powerpc64= ASM |
26 |
OPTIONS_DEFAULT_amd64= ASM |
27 |
OPTIONS_DEFAULT_amd64= ASM |
|
|
28 |
OPTIONS_DEFAULT_powerpc64= ASM |
27 |
|
29 |
|
28 |
OPTIONS_MULTI= PixelWidth |
30 |
OPTIONS_MULTI= PixelWidth |
29 |
OPTIONS_MULTI_PixelWidth=HI8P HI10P HI12P |
31 |
OPTIONS_MULTI_PixelWidth=HI8P HI10P HI12P |
Lines 62-72
WRKSRC= ${WRKDIR}/source
Link Here
|
62 |
.if ${ARCH} == aarch64 && ${PORT_OPTIONS:MASM} |
64 |
.if ${ARCH} == aarch64 && ${PORT_OPTIONS:MASM} |
63 |
BUILD_DEPENDS= as:devel/binutils |
65 |
BUILD_DEPENDS= as:devel/binutils |
64 |
USE_GCC= yes |
66 |
USE_GCC= yes |
65 |
ASM_PREVENTS= HI10P HI12P |
|
|
66 |
ASM_PREVENTS_MSG= Currently HI10P and HI12P doesn't build with assembly |
67 |
.endif |
67 |
.endif |
68 |
|
68 |
|
69 |
.if ${ARCH} != aarch64 && ${PORT_OPTIONS:MASM} |
69 |
.if ${ARCH} == powerpc64 && ${PORT_OPTIONS:MASM} |
|
|
70 |
CMAKE_ARGS+= -DCPU_POWER8=ON \ |
71 |
-DENABLE_ALTIVEC=ON |
72 |
.endif |
73 |
|
74 |
.if ${ARCH} != aarch64 && ${ARCH} != powerpc64 && ${PORT_OPTIONS:MASM} |
70 |
BUILD_DEPENDS= nasm:devel/nasm |
75 |
BUILD_DEPENDS= nasm:devel/nasm |
71 |
.endif |
76 |
.endif |
72 |
|
77 |
|
Lines 90-95
CFLAGS:= ${CFLAGS:N-O*} -O0 -g
Link Here
|
90 |
.for b in ${OTHER_DEPTHS:C/HI([0-9]+)P/\1/} |
95 |
.for b in ${OTHER_DEPTHS:C/HI([0-9]+)P/\1/} |
91 |
EXTRA_LINK_FLAGS+=-L${WRKSRC:H}/$bbit |
96 |
EXTRA_LINK_FLAGS+=-L${WRKSRC:H}/$bbit |
92 |
|
97 |
|
|
|
98 |
.if ${ARCH} == powerpc64 |
99 |
|
100 |
.if $b != 8 || ! ${PORT_OPTIONS:MASM} |
101 |
ASSEMBLY=false |
102 |
.else |
103 |
ASSEMBLY=true |
104 |
.endif |
105 |
|
106 |
.if ${PORT_OPTIONS:MASM} |
107 |
POWER8= true |
108 |
.else |
109 |
POWER8= false |
110 |
.endif |
111 |
|
112 |
pre-build:: |
113 |
@${ECHO_MSG} "---> Building the $b-bit library ---" |
114 |
${MKDIR} ${WRKSRC:H}/$bbit |
115 |
${CMAKE_BIN} -S ${WRKSRC} -B ${WRKSRC:H}/$bbit \ |
116 |
${CMAKE_OTHER_ARGS} ${b:C/1./-DHIGH_BIT_DEPTH:BOOL=true/} \ |
117 |
-DMAIN$b:BOOL=true -DENABLE_ALTIVEC=${ASSEMBLY} -DCPU_POWER8=${POWER8} \ |
118 |
-DEXPORT_C_API:BOOL=false -DENABLE_CLI=false |
119 |
${SETENV} ${MAKE_ENV} ${MAKE_CMD} -C ${WRKSRC:H}/$bbit ${MAKE_ARGS} |
120 |
${LN} -f ${WRKSRC:H}/$bbit/libx265.a ${WRKSRC:H}/$bbit/libx265_$bbit.a |
121 |
${ECHO_MSG} "---> Built the $b-bit library ---" |
122 |
|
123 |
.else |
93 |
.if ${ARCH} == i386 && $b != 8 || ! ${PORT_OPTIONS:MASM} |
124 |
.if ${ARCH} == i386 && $b != 8 || ! ${PORT_OPTIONS:MASM} |
94 |
ASSEMBLY=false |
125 |
ASSEMBLY=false |
95 |
.else |
126 |
.else |
Lines 106-111
pre-build::
Link Here
|
106 |
${SETENV} ${MAKE_ENV} ${MAKE_CMD} -C ${WRKSRC:H}/$bbit ${MAKE_ARGS} |
137 |
${SETENV} ${MAKE_ENV} ${MAKE_CMD} -C ${WRKSRC:H}/$bbit ${MAKE_ARGS} |
107 |
${LN} -f ${WRKSRC:H}/$bbit/libx265.a ${WRKSRC:H}/$bbit/libx265_$bbit.a |
138 |
${LN} -f ${WRKSRC:H}/$bbit/libx265.a ${WRKSRC:H}/$bbit/libx265_$bbit.a |
108 |
${ECHO_MSG} "---> Built the $b-bit library ---" |
139 |
${ECHO_MSG} "---> Built the $b-bit library ---" |
|
|
140 |
.endif |
109 |
.endfor |
141 |
.endfor |
110 |
|
142 |
|
111 |
.if "${EXTRA_LINK_FLAGS}" |
143 |
.if "${EXTRA_LINK_FLAGS}" |
Lines 119-125
CMAKE_ARGS+= -DENABLE_SHARED:BOOL=true
Link Here
|
119 |
.if ${ARCH} == i386 && ${DEFAULT_DEPTH} != "HI8P" || ! ${PORT_OPTIONS:MASM} |
151 |
.if ${ARCH} == i386 && ${DEFAULT_DEPTH} != "HI8P" || ! ${PORT_OPTIONS:MASM} |
120 |
CMAKE_ARGS+= -DENABLE_ASSEMBLY:BOOL=false |
152 |
CMAKE_ARGS+= -DENABLE_ASSEMBLY:BOOL=false |
121 |
.else |
153 |
.else |
|
|
154 |
.if ${ARCH} != powerpc64 |
122 |
CMAKE_ARGS+= -DENABLE_ASSEMBLY:BOOL=true |
155 |
CMAKE_ARGS+= -DENABLE_ASSEMBLY:BOOL=true |
|
|
156 |
.else |
157 |
CMAKE_ARGS+= -DCPU_POWER8=ON \ |
158 |
-DENABLE_ALTIVEC=ON |
159 |
.endif |
123 |
|
160 |
|
124 |
do-test: |
161 |
do-test: |
125 |
${WRKDIR}/.build/test/TestBench |
162 |
${WRKDIR}/.build/test/TestBench |