[Pkg-javascript-devel] Bug#872488: nodejs: Build-Dependency loop nodejs => node-yamlish, node-marked => nodejs

Felipe Sateler fsateler at debian.org
Thu Aug 17 20:08:53 UTC 2017


Source: nodejs
Version: 6.11.2~dfsg-2
Severity: important
Tags: patch

Hi,

Currently nodejs has a dependency loop which causes problems when
building on buildds when the previous nodejs version is not installable
for some reason. Fortunately, the node dependencies appear to only be
used for building documentation. Therefore the loop can be broken by
splitting the documentation into an Architecture: all package: this will
make buildds not require installing nodejs to build nodejs.

Please find a patch attached doing this. Patch is against -1 because -2
was not in git...

-- System Information:
Debian Release: buster/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 4.9.0-3-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

-- no debconf information
-------------- next part --------------
From 421b536f2e076e35ae75674112d0ca28142d9a6a Mon Sep 17 00:00:00 2001
From: Felipe Sateler <fsateler at debian.org>
Date: Thu, 17 Aug 2017 16:53:58 -0300
Subject: [PATCH] Split documentation into a separate, arch:all package

This avoids the dependency loop on the buildds, since they will now no longer require
nodejs to be available.
---
 debian/control.in                               | 27 ++++++++++++++++++++++++-
 debian/{nodejs.doc-base => nodejs-doc.doc-base} |  0
 debian/{nodejs.docs => nodejs-doc.docs}         |  0
 debian/rules                                    | 16 ++-------------
 4 files changed, 28 insertions(+), 15 deletions(-)
 rename debian/{nodejs.doc-base => nodejs-doc.doc-base} (100%)
 rename debian/{nodejs.docs => nodejs-doc.docs} (100%)

diff --git a/debian/control.in b/debian/control.in
index 949b7685..30f03285 100644
--- a/debian/control.in
+++ b/debian/control.in
@@ -5,6 +5,8 @@ Maintainer: Debian Javascript Maintainers <pkg-javascript-devel at lists.alioth.deb
 Uploaders: J?r?my Lal <kapouer at melix.org>,
  Jonas Smedegaard <dr at jones.dk>
 Build-Depends: @cdbs@
+Build-Depends-Indep: node-yamlish,
+ node-marked
 Standards-Version: 4.0.0
 Homepage: http://nodejs.org/
 Vcs-Browser: https://anonscm.debian.org/gitweb/?p=collab-maint/nodejs.git
@@ -33,7 +35,8 @@ Architecture: any
 Depends: ${shlibs:Depends},
  ${misc:Depends}
 Provides: ${cdbs:Provides}
-Recommends: ${cdbs:Recommends}
+Recommends: ${cdbs:Recommends},
+ nodejs-doc
 Replaces: nodejs-legacy
 Conflicts: nodejs-legacy
 Description: evented I/O for V8 javascript
@@ -49,3 +52,25 @@ Description: evented I/O for V8 javascript
  System, Events, Standard I/O, Modules, Timers, Child Processes, POSIX,
  HTTP, Multipart Parsing, TCP, DNS, Assert, Path, URL, Query Strings.
 
+Package: nodejs-doc
+Architecture: all
+Depends: ${misc:Depends}
+Provides: ${cdbs:Provides}
+Recommends: ${cdbs:Recommends}, nodejs
+Replaces: nodejs (<< 6.11.2~dfsg-3)
+Conflicts: nodejs (<< 6.11.2~dfsg-3)
+Description: evented I/O for V8 javascript
+ Node.js is a platform built on Chrome's JavaScript runtime for easily
+ building fast, scalable network applications. Node.js uses an
+ event-driven, non-blocking I/O model that makes it lightweight and
+ efficient, perfect for data-intensive real-time applications that run
+ across distributed devices.
+ .
+ Node.js is bundled with several useful libraries to handle server
+ tasks:
+ .
+ System, Events, Standard I/O, Modules, Timers, Child Processes, POSIX,
+ HTTP, Multipart Parsing, TCP, DNS, Assert, Path, URL, Query Strings.
+ .
+ This package contains documentation for nodejs.
+
diff --git a/debian/nodejs.doc-base b/debian/nodejs-doc.doc-base
similarity index 100%
rename from debian/nodejs.doc-base
rename to debian/nodejs-doc.doc-base
diff --git a/debian/nodejs.docs b/debian/nodejs-doc.docs
similarity index 100%
rename from debian/nodejs.docs
rename to debian/nodejs-doc.docs
diff --git a/debian/rules b/debian/rules
index 3e7a938a..5320069f 100755
--- a/debian/rules
+++ b/debian/rules
@@ -24,10 +24,6 @@ bdeps +=, bash-completion, curl, procps, zlib1g-dev, libicu-dev, libc-ares-dev (
 bdeps +=, libkvm-dev [kfreebsd-any], gyp (>= 0.1~svn1773)
 # Needed for tests
 bdeps +=, ca-certificates
-# needed by doctool-yaml.patch
-bdeps +=, node-yamlish <!stage1>
-# needed by doc builder
-bdeps +=, node-marked <!stage1>
 
 # Needed by upstream build and binary development package
 deps = python, libssl1.0-dev (>= $(ssl-minver))
@@ -160,24 +156,16 @@ clean::
 	find . -name "*.pyc" -delete
 	rm -rf out
 
-ifeq ($(filter stage1,$(DEB_BUILD_PROFILES)),)
 # remove *.json files from documentation
-binary-install/nodejs::
+binary-install/nodejs-doc::
 	find debian/nodejs/usr/share/doc/nodejs -name *.json -delete
-endif
 
 pre-build::
 	ln -sTf /usr/lib/nodejs node_modules
 	mkdir -p $(NODE_TEST_DIR)
 
-ifeq ($(filter stage1,$(DEB_BUILD_PROFILES)),)
-build/nodejs::
+build/nodejs-doc::
 	make doc
-else
-# Stops the stage1 variant from breaking dh_installdocs
-build/nodejs::
-	mkdir -p out/doc/api
-endif
 
 # Provide dependency hints for reverse dependencies to consume
 CDBS_SUGGESTS_nodejs-dev = debhelper
-- 
2.14.1



More information about the Pkg-javascript-devel mailing list