I'm opening this mainly for tracking adding ARCH=riscv support Reproducible: Always https://github.com/nodejs/node/commit/1d21a8d140f78d4408c5375caedc917a83902a80
Looks like v16 should work, or at least both 16.6.2 (i.e. the latest version in the tree) and 16.9.1 (i.e. the latest upstream version as of right now) both recognise 'riscv64' as a valid arch name. Will give it a try some time soon, once my Starlight has finally finished emerging media-fonts/noto-emoji[buildfont] - 12 hours and counting!
Created attachment 739617 [details] build log for net-libs/nodejs-16.6.2-r1 version of 16.6.2 doesn't work as expected, most obvious error as following | ^~~~~~~~~~~ ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc:1085:10: error: narrowing conversion of ‘v8::internal::RO_FMV_W_X’ from ‘uint32_t’ {aka ‘unsigned int’} to ‘int’ [-Wnarrowing] 1085 | case RO_FMV_W_X: { | ^~~~~~~~~~ ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc:1168:10: error: narrowing conversion of ‘v8::internal::RO_FLE_D’ from ‘uint32_t’ {aka ‘unsigned int’} to ‘int’ [-Wnarrowing] 1168 | case RO_FLE_D: { // RO_FEQ_D RO_FLT_D RO_FLE_D | ^~~~~~~~ ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc:1184:37: error: narrowing conversion of ‘3791650899’ from ‘unsigned int’ to ‘int’ [-Wnarrowing] 1184 | case (RO_FCLASS_D & kRFPTypeMask): { // RO_FCLASS_D , 64D RO_FMV_X_D | ^ ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc:1203:10: error: narrowing conversion of ‘v8::internal::RO_FCVT_W_D’ from ‘uint32_t’ {aka ‘unsigned int’} to ‘int’ [-Wnarrowing] 1203 | case RO_FCVT_W_D: { // RO_FCVT_WU_D , 64F RO_FCVT_L_D RO_FCVT_LU_D | ^~~~~~~~~~~ ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc:1224:10: error: narrowing conversion of ‘v8::internal::RO_FCVT_D_W’ from ‘uint32_t’ {aka ‘unsigned int’} to ‘int’ [-Wnarrowing] 1224 | case RO_FCVT_D_W: { // RO_FCVT_D_WU , 64F RO_FCVT_D_L RO_FCVT_D_LU | ^~~~~~~~~~~ ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc:1246:10: error: narrowing conversion of ‘v8::internal::RO_FMV_D_X’ from ‘uint32_t’ {aka ‘unsigned int’} to ‘int’ [-Wnarrowing] 1246 | case RO_FMV_D_X: { | ^~~~~~~~~~ distcc[558976] ERROR: compile ../deps/v8/src/diagnostics/riscv64/disasm-riscv64.cc on localhost failed make: *** [tools/v8_gypfiles/v8_base_without_compiler.target.mk:945: /var/tmp/portage/net-libs/nodejs-16.6.2-r1/work/node-v16.6.2/out/Release/obj.target/v8_base_without_compiler/deps/v8/src/diagnostics/riscv64/disasm-riscv64.o] Error 1 make: *** Waiting for unfinished jobs.... ../deps/v8/src/codegen/riscv64/assembler-riscv64.cc: In member function ‘void v8::internal::Assembler::GrowBuffer()’: ../deps/v8/src/codegen/riscv64/assembler-riscv64.cc:2695:53: warning: narrowing conversion of ‘((v8::internal::Assembler*)this)->v8::internal::Assembler::<anonymous>.v8::internal::AssemblerBase::pc_offset()’ from ‘int’ to ‘size_t’ {aka ‘long unsigned int’} [-Wnarrowing]
16.9.1 builds successfully but fails several tests.
Created attachment 768170 [details] build.log for nodejs-16.14.1 @guyu, could you show us the emerge command, and attach the full test/build.log for nodejs-16.14.1? as my test here, still show some test failures for test-fs-readdir-ucs2, we need to check if the filesystem support ucs2 encoding or not, otherwise the test can be skipped, see https://github.com/nodejs/node/pull/14029/commits/f03541e9bcc0345eb032e62152f84c7336fa5ef3 ****** just FYI, the error messages [----------] Global test environment tear-down [==========] 127 tests from 21 test suites ran. (14832 ms total) [ PASSED ] 127 tests. === release test-fs-readdir-ucs2 === Path: parallel/test-fs-readdir-ucs2 /var/notmpfs/portage/net-libs/nodejs-16.14.1/work/node-v16.14.1/test/parallel/test-fs-readdir-ucs2.js:23 throw e; ^ Error: EILSEQ: illegal byte sequence, open '/var/notmpfs/portage/net-libs/nodejs-16.14.1/work/node-v16.14.1/test/.tmp.804/=��' at Object.openSync (node:fs:585:3) at Object.<anonymous> (/var/notmpfs/portage/net-libs/nodejs-16.14.1/work/node-v16.14.1/test/parallel/test-fs-readdir-ucs2.js:19:19) at Module._compile (node:internal/modules/cjs/loader:1103:14) at Object.Module._extensions..js (node:internal/modules/cjs/loader:1157:10) at Module.load (node:internal/modules/cjs/loader:981:32) at Function.Module._load (node:internal/modules/cjs/loader:822:12) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12) at node:internal/main/run_main_module:17:47 { errno: -84, syscall: 'open', code: 'EILSEQ', path: '/var/notmpfs/portage/net-libs/nodejs-16.14.1/work/node-v16.14.1/test/.tmp.804/=�\x04�' } Command: out/Release/node /var/notmpfs/portage/net-libs/nodejs-16.14.1/work/node-v16.14.1/test/parallel/test-fs-readdir-ucs2.js === release test-heap-prof === Path: sequential/test-heap-prof Command: out/Release/node /var/notmpfs/portage/net-libs/nodejs-16.14.1/work/node-v16.14.1/test/sequential/test-heap-prof.js --- TIMEOUT --- [22:56|% 100|+ 3060|- 2]: Done * ERROR: net-libs/nodejs-16.14.1::gentoo failed (test phase): * (no error message)
Created attachment 768574 [details] build.log&test.conf for nodejs-16.14.1 @Yixun Lan I hope this time we could make it done. Test all passed on unmatched board.
(In reply to Yu Gu from comment #5) > Created attachment 768574 [details] > build.log&test.conf for nodejs-16.14.1 > > @Yixun Lan > I hope this time we could make it done. Test all passed on unmatched board. === from the log, I see USE: elibc_glibc icu kernel_linux npm riscv snapshot ssl system-icu system-ssl test userland_GNU so, it seems USE=inspector is not enabled, not sure if this will cause the test failure, and.. and comparing the test report, there are some test cases missing (note: 96 vs 127 tests, 19 vs 21 test suites) [----------] Global test environment tear-down [==========] 96 tests from 19 test suites ran. (12892 ms total) [ PASSED ] 96 tests.
(In reply to Yixun Lan from comment #6) > (In reply to Yu Gu from comment #5) > > Created attachment 768574 [details] > > build.log&test.conf for nodejs-16.14.1 > > > > @Yixun Lan > > I hope this time we could make it done. Test all passed on unmatched board. > > === from the log, I see > USE: elibc_glibc icu kernel_linux npm riscv snapshot ssl system-icu > system-ssl test userland_GNU > > > so, it seems USE=inspector is not enabled, not sure if this will cause the > test failure, and.. > > > and comparing the test report, there are some test cases missing (note: 96 > vs 127 tests, 19 vs 21 test suites) > > [----------] Global test environment tear-down > [==========] 96 tests from 19 test suites ran. (12892 ms total) > [ PASSED ] 96 tests. I tested with USE=inspector too, all tests passed except one test timeout which related with inspector. It caused by weak performance of unmatch. So I think there's no fatal wrong with this package.
(In reply to Yixun Lan from comment #6) > (In reply to Yu Gu from comment #5) > > Created attachment 768574 [details] > > build.log&test.conf for nodejs-16.14.1 > > > > @Yixun Lan > > I hope this time we could make it done. Test all passed on unmatched board. > > === from the log, I see > USE: elibc_glibc icu kernel_linux npm riscv snapshot ssl system-icu > system-ssl test userland_GNU > > > so, it seems USE=inspector is not enabled, not sure if this will cause the > test failure, and.. > > > and comparing the test report, there are some test cases missing (note: 96 > vs 127 tests, 19 vs 21 test suites) > > [----------] Global test environment tear-down > [==========] 96 tests from 19 test suites ran. (12892 ms total) > [ PASSED ] 96 tests. There is a timeout test, test-heap-prof.js as I said in #7. I wrote a patch and passed this test. But in general, it can be ignored. I pushed it to upstream, but I think it won't be landed in our nodejs-16.14.1 even if upstream merged it. In my opinion, we can keyword this package, although it can randomly fail one or two fixed tests(and can randomly pass all tests) in emerge sandbox. But can pass all tests in runtime.
Created attachment 769667 [details] log
Created attachment 769715 [details] log in starlight
increasing the timeout will relieve the test failure, so let's make it not blocking the keyword request so, I will go ahead and proceed with version 16.4.1 if no objection
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f793e2d3bb4eed77a39281766aec467a4fd1c317 commit f793e2d3bb4eed77a39281766aec467a4fd1c317 Author: Yixun Lan <dlan@gentoo.org> AuthorDate: 2022-04-10 09:53:56 +0000 Commit: Yixun Lan <dlan@gentoo.org> CommitDate: 2022-04-10 10:02:20 +0000 net-libs/nodejs: keyword 16.14.1 for ~riscv increasing timeout value would make 'test-heap-prof.js' pass the test, so we think it's good to go, instead of blocking the keyword procedure forever finally, thanks 'ArchFeh' for testing Closes: https://bugs.gentoo.org/782913 Signed-off-by: Yixun Lan <dlan@gentoo.org> net-libs/nodejs/nodejs-16.14.1.ebuild | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)