Bug#1082688: node-shiny-server: FTBFS: TypeError: Cannot read properties of undefined (reading 'define')
Santiago Vila
sanvila at debian.org
Tue Sep 24 18:41:44 BST 2024
Package: src:node-shiny-server
Version: 1.5.20.1002-2
Severity: serious
Tags: ftbfs
Dear maintainer:
During a rebuild of all packages in unstable, your package failed to build:
--------------------------------------------------------------------------------
[...]
debian/rules binary
dh binary
dh_update_autotools_config
dh_autoreconf
debian/rules override_dh_auto_configure
make[1]: Entering directory '/<<PKGBUILDDIR>>'
# provide a fake shiny-server executable pointing to debian packaged nodejs
# See external/node/CMakeLists.txt for details
mkdir -p ext/node/bin
ln -s /usr/bin/nodejs ext/node/bin/shiny-server
dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr/lib
cd obj-x86_64-linux-gnu && DEB_PYTHON_INSTALL_LAYOUT=deb PKG_CONFIG=/usr/bin/pkg-config cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=None -DCMAKE_INSTALL_SYSCONFDIR=/etc -DCMAKE_INSTALL_LOCALSTATEDIR=/var -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON -DFETCHCONTENT_FULLY_DISCONNECTED=ON -DCMAKE_INSTALL_RUNSTATEDIR=/run -DCMAKE_SKIP_INSTALL_ALL_DEPENDENCY=ON "-GUnix Makefiles" -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_INSTALL_LIBDIR=lib/x86_64-linux-gnu -DCMAKE_INSTALL_PREFIX=/usr/lib ..
CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- The C compiler identification is GNU 14.2.0
-- The CXX compiler identification is GNU 14.2.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning (dev) at CMakeLists.txt:94 (exec_program):
Policy CMP0153 is not set: The exec_program command should not be called.
Run "cmake --help-policy CMP0153" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
Use execute_process() instead.
This warning is for project developers. Use -Wno-dev to suppress it.
-- Configuring done (0.4s)
-- Generating done (0.0s)
CMake Warning:
Manually-specified variables were not used by the project:
CMAKE_EXPORT_NO_PACKAGE_REGISTRY
CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY
CMAKE_FIND_USE_PACKAGE_REGISTRY
CMAKE_INSTALL_LIBDIR
CMAKE_INSTALL_LOCALSTATEDIR
CMAKE_INSTALL_RUNSTATEDIR
CMAKE_INSTALL_SYSCONFDIR
FETCHCONTENT_FULLY_DISCONNECTED
-- Build files have been written to: /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu
ln -s obj-x86_64-linux-gnu build
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
debian/rules override_dh_auto_build
make[1]: Entering directory '/<<PKGBUILDDIR>>'
dh_auto_build
cd obj-x86_64-linux-gnu && make -j2 "INSTALL=install --strip-program=true" VERBOSE=1
make[2]: Entering directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
/usr/bin/cmake -S/<<PKGBUILDDIR>> -B/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu --check-build-system CMakeFiles/Makefile.cmake 0
/usr/bin/cmake -E cmake_progress_start /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/CMakeFiles /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu//CMakeFiles/progress.marks
make -f CMakeFiles/Makefile2 all
make[3]: Entering directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
make -f src/CMakeFiles/shiny-server.dir/build.make src/CMakeFiles/shiny-server.dir/depend
make[4]: Entering directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
cd /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /<<PKGBUILDDIR>> /<<PKGBUILDDIR>>/src /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src/CMakeFiles/shiny-server.dir/DependInfo.cmake "--color="
make[4]: Leaving directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
make -f src/CMakeFiles/shiny-server.dir/build.make src/CMakeFiles/shiny-server.dir/build
make[4]: Entering directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
[ 50%] Building CXX object src/CMakeFiles/shiny-server.dir/launcher.cc.o
cd /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src && /usr/bin/c++ -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2 -MD -MT src/CMakeFiles/shiny-server.dir/launcher.cc.o -MF CMakeFiles/shiny-server.dir/launcher.cc.o.d -o CMakeFiles/shiny-server.dir/launcher.cc.o -c /<<PKGBUILDDIR>>/src/launcher.cc
/<<PKGBUILDDIR>>/src/launcher.cc: In function ‘int main(int, char**)’:
/<<PKGBUILDDIR>>/src/launcher.cc:38:13: warning: ignoring return value of ‘int daemon(int, int)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
38 | daemon(1, 0);
| ~~~~~~^~~~~~
[100%] Linking CXX executable /<<PKGBUILDDIR>>/bin/shiny-server
cd /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src && /usr/bin/cmake -E cmake_link_script CMakeFiles/shiny-server.dir/link.txt --verbose=1
/usr/bin/c++ -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2 -Wl,-z,relro -Wl,-z,now -rdynamic "CMakeFiles/shiny-server.dir/launcher.cc.o" -o /<<PKGBUILDDIR>>/bin/shiny-server
make[4]: Leaving directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
[100%] Built target shiny-server
make[3]: Leaving directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
/usr/bin/cmake -E cmake_progress_start /<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/CMakeFiles 0
make[2]: Leaving directory '/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu'
node-gyp rebuild
gyp info it worked if it ends with ok
gyp info using node-gyp at 10.2.0
gyp info using node at 20.17.0 | linux | x64
gyp info find Python using Python version 3.12.6 found at "/usr/bin/python3"
gyp info spawn /usr/bin/python3
gyp info spawn args [
gyp info spawn args '/usr/share/nodejs/node-gyp/gyp/gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
gyp info spawn args '/<<PKGBUILDDIR>>/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/share/nodejs/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/include/nodejs/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/usr/include/nodejs',
gyp info spawn args '-Dnode_gyp_dir=/usr/share/nodejs/node-gyp',
gyp info spawn args '-Dnode_lib_file=/usr/include/nodejs/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/<<PKGBUILDDIR>>',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
make[2]: Entering directory '/<<PKGBUILDDIR>>/build'
CXX(target) Release/obj.target/posix/src/posix.o
SOLINK_MODULE(target) Release/obj.target/posix.node
COPY Release/posix.node
make[2]: Leaving directory '/<<PKGBUILDDIR>>/build'
gyp info ok
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
debian/rules override_dh_auto_test
make[1]: Entering directory '/<<PKGBUILDDIR>>'
mocha -R spec
Exception during run: TypeError: Cannot read properties of undefined (reading 'define')
at Object.<anonymous> (/<<PKGBUILDDIR>>/lib/router/directory-router.js:27:11)
at Module._compile (node:internal/modules/cjs/loader:1469:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1548:10)
at Module.load (node:internal/modules/cjs/loader:1288:32)
at Module._load (node:internal/modules/cjs/loader:1104:12)
at Module.require (node:internal/modules/cjs/loader:1311:19)
at require (node:internal/modules/helpers:179:18)
at Object.<anonymous> (/<<PKGBUILDDIR>>/lib/router/user-dirs-router.js:23:23)
at Module._compile (node:internal/modules/cjs/loader:1469:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1548:10)
at Module.load (node:internal/modules/cjs/loader:1288:32)
at Module._load (node:internal/modules/cjs/loader:1104:12)
at Module.require (node:internal/modules/cjs/loader:1311:19)
at require (node:internal/modules/helpers:179:18)
at /<<PKGBUILDDIR>>/lib/router/config-router.js:25:24
at Object.<anonymous> (/<<PKGBUILDDIR>>/lib/router/config-router.js:626:4)
at Module._compile (node:internal/modules/cjs/loader:1469:14)
at module._compile (/usr/share/nodejs/rewire/lib/moduleEnv.js:126:18)
at Module._extensions..js (node:internal/modules/cjs/loader:1548:10)
at Object.jsExtension (/usr/share/nodejs/rewire/lib/moduleEnv.js:136:24)
at Module.load (node:internal/modules/cjs/loader:1288:32)
at Object.load (/usr/share/nodejs/rewire/lib/moduleEnv.js:57:18)
at internalRewire (/usr/share/nodejs/rewire/lib/rewire.js:49:15)
at rewire (/usr/share/nodejs/rewire/lib/index.js:11:12)
at Object.<anonymous> (/<<PKGBUILDDIR>>/test/nested-locations.js:21:21)
at Module._compile (node:internal/modules/cjs/loader:1469:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1548:10)
at Module.load (node:internal/modules/cjs/loader:1288:32)
at Module._load (node:internal/modules/cjs/loader:1104:12)
at cjsLoader (node:internal/modules/esm/translators:346:17)
at ModuleWrap.<anonymous> (node:internal/modules/esm/translators:286:7)
at ModuleJob.run (node:internal/modules/esm/module_job:234:25)
at async ModuleLoader.import (node:internal/modules/esm/loader:473:24)
at async formattedImport (/usr/share/nodejs/mocha/lib/nodejs/esm-utils.js:9:14)
at async exports.requireOrImport (/usr/share/nodejs/mocha/lib/nodejs/esm-utils.js:42:28)
at async exports.loadFilesAsync (/usr/share/nodejs/mocha/lib/nodejs/esm-utils.js:100:20)
at async singleRun (/usr/share/nodejs/mocha/lib/cli/run-helpers.js:162:3)
at async exports.handler (/usr/share/nodejs/mocha/lib/cli/run.js:375:5)
make[1]: *** [debian/rules:28: override_dh_auto_test] Error 1
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
make: *** [debian/rules:13: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------
The above is just how the build ends and not necessarily the most relevant part.
If required, the full build log is available here:
https://people.debian.org/~sanvila/build-logs/202409/
About the archive rebuild: The build was made on virtual machines from AWS,
using sbuild and a reduced chroot with only build-essential packages.
If you could not reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.
If this is really a bug in one of the build-depends, please use
reassign and affects, so that this is still visible in the BTS web
page for this package.
Thanks.
More information about the debian-science-maintainers
mailing list