Bug 248479 - multimedia/x265: fails to build with SVTHEVC on
Summary: multimedia/x265: fails to build with SVTHEVC on
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-08-05 08:05 UTC by VVD
Modified: 2020-08-10 18:06 UTC (History)
8 users (show)

See Also:
bugzilla: maintainer-feedback? (mi)
vvd: maintainer-feedback?


Attachments
log file (88.68 KB, application/x-xz)
2020-08-05 13:32 UTC, Steve Wills
no flags Details
Make compatible with svt-hevc 1.5.x (1.57 KB, patch)
2020-08-07 02:58 UTC, Mikhail Teterin
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description VVD 2020-08-05 08:05:50 UTC
12.1 amd64:

FAILED: encoder/CMakeFiles/encoder.dir/api.cpp.o 
/usr/bin/c++  -DENABLE_HDR10_PLUS -DEXPORT_C_API=1 -DHAVE_INT_TYPES_H=1 -DHIGH_BIT_DEPTH=0 -DSVT_HEVC -DX265_ARCH_X86=1 -DX265_DEPTH=8 -DX265_NS=x265 -DX86_64=1 -D__STDC_LIMIT_MACROS=1 -I/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/. -I/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/dynamicHDR10 -I. -I/usr/local/include/svt-hevc -I/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/common -I/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/encoder -O2 -pipe -DNDEBUG -O3 -fstack-protector-strong -fno-strict-aliasing -O2 -pipe -DNDEBUG -O3 -fstack-protector-strong -fno-strict-aliasing   -Wall -Wextra -Wshadow -std=gnu++11 -fPIC -Wno-array-bounds -ffast-math -mstackrealign -fno-exceptions -Wno-uninitialized -DLINKED_10BIT=1 -DLINKED_12BIT=1 -MD -MT encoder/CMakeFiles/encoder.dir/api.cpp.o -MF encoder/CMakeFiles/encoder.dir/api.cpp.o.d -o encoder/CMakeFiles/encoder.dir/api.cpp.o -c /tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/encoder/api.cpp
/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/encoder/api.cpp:408:55: error: array type 'unsigned char [1024]' is not assignable
                    inputData->dolbyVisionRpu.payload = X265_MALLOC(uint8_t, 1024);
                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/encoder/api.cpp:415:55: error: array type 'unsigned char [1024]' is not assignable
                    inputData->dolbyVisionRpu.payload = NULL;
                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/encoder/api.cpp:653:43: warning: address of array 'inputData->dolbyVisionRpu.payload' will always evaluate to 'true' [-Wpointer-bool-conversion]
            if (inputData->dolbyVisionRpu.payload) X265_FREE(inputData->dolbyVisionRpu.payload);
            ~~  ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
/tmp/work/usr/ports/multimedia/x265/work/x265_3.2.1/source/encoder/api.cpp:1986:39: error: array type 'unsigned char [1024]' is not assignable
    inputData->dolbyVisionRpu.payload = NULL;
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
1 warning and 3 errors generated.
Comment 1 VVD 2020-08-05 08:19:00 UTC
Before update multimedia/svt-hevc from 1.4.3 to 1.5.0 it build fine.
Comment 2 daniel.engberg.lists 2020-08-05 08:41:49 UTC
Please test https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=247035
Comment 3 Steve Wills freebsd_committer 2020-08-05 13:32:40 UTC
Created attachment 217027 [details]
log file

here's my log of the build error
Comment 4 Oleg Sidorkin 2020-08-05 15:50:30 UTC
That's an upstream problem due to svt-hevc API changes. It's still present in 3.4.
Comment 5 Mikhail Teterin freebsd_committer 2020-08-07 02:58:54 UTC
Created attachment 217060 [details]
Make compatible with svt-hevc 1.5.x

Please, try this patch. I prepared it for x265-3.4, but it should apply -- even if with some effort -- to 3.2 as well.

With it, 3.4 compiles here -- and passes its own tests -- but I'm not sure, how comprehensive they are...
Comment 6 VVD 2020-08-07 10:34:33 UTC
(In reply to Mikhail Teterin from comment #5)
> Please, try this patch. I prepared it for x265-3.4, but it should apply -- even if with some effort -- to 3.2 as well.
Build fine for me.

But file multimedia/x265/files/patch-source_encoder_api.cpp have other patch - don't forget this during prepare patch for multimedia/x265.
Comment 7 Mikhail Teterin freebsd_committer 2020-08-07 18:23:36 UTC
(In reply to VVD from comment #6)
> Build fine for me.

Does it work, though? Can you test the SVT functionality?

> But file multimedia/x265/files/patch-source_encoder_api.cpp have other patch

Thanks, that older patch is not, actually, necessary for the 3.4.