[Pkg-javascript-devel] Bug#980291: libjs-jquery-flot: version 4.2.1+dfsg-2 drops minified files

Jonas Smedegaard jonas at jones.dk
Mon Jan 18 15:26:42 GMT 2021


Quoting Antonio Terceiro (2021-01-18 13:30:46)
> Control: reopen -1
> 
> The minified files are now there, but they are empty because there is a
> typo (f -> j) in debian/rules. I was able to fix that locally with this
> patch:
> 
> ----------------8<----------------8<----------------8<-----------------
> diff --git a/debian/rules b/debian/rules
> index dbf4bc4..4bc2f33 100755
> --- a/debian/rules
> +++ b/debian/rules
> @@ -6,12 +6,12 @@
>  override_dh_auto_build:
>         gulp build
>         cd source && for f in *.js; do \
> -               echo "Minify soure/$$f"; \
> -               uglifyjs --source-map -o $${f%%.js}.min.js $$j; \
> +               echo "Minify source/$$f"; \
> +               uglifyjs --source-map -o $${f%%.js}.min.js $$f; \
>         done
>         cd dist/es5 && for f in *.js; do \
>                 echo "Minify dist/es5/$$f"; \
> -               uglifyjs --source-map -o $${f%%.js}.min.js $$j; \
> +               uglifyjs --source-map -o $${f%%.js}.min.js $$f; \
>         done
> 
>  get-orig-source:
> 
> ----------------8<----------------8<----------------8<-----------------
> 
> However, after that fix, the build fails, see the attached log.
> 
> It seems there are two problems:
> 
> - there are some files where uglify reports a parse error (because those
>   files contain ES6 code?)
> 
> - dh_install fails because it can't find source/*.map

Also, generally prepend this to make rules containing ";":

   set -e;

Otherwise the whole chain fails only when _last_ shell command fails!


 - Jonas

-- 
 * Jonas Smedegaard - idealist & Internet-arkitekt
 * Tlf.: +45 40843136  Website: http://dr.jones.dk/

 [x] quote me freely  [ ] ask before reusing  [ ] keep private
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-javascript-devel/attachments/20210118/188d6c7a/attachment.sig>


More information about the Pkg-javascript-devel mailing list