Bug#976335: make: syntax to return literal # broken

2023-02-13 Thread Victor Westerhuis
Source: make-dfsg
Followup-For: Bug #976335
Control: tags -1 upstream

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Hello Daniel,

This is actually a fix for an upstream bug at
https://savannah.gnu.org/bugs/?20513.

- --
Groet, Regards,

Victor Westerhuis

-BEGIN PGP SIGNATURE-

iQJHBAEBCAAxFiEE6OxII3T+o0Ujs6ECQz2Rq5dHQPsFAmPp9IATHHZpY3RvckB3
ZXN0ZXJodS5pcwAKCRBDPZGrl0dA+4+LEAC5pBBWu4btyDG+8sI4q8aera57rLW4
Mjd3vQ1G07+a02M3MdUxdnHiz0/FWvylvwlq6muS8tqTK21Plyb7MiitcGRVVlo9
Lk/nNo71ET2rGFue86V6gX3ddrqBhToun/V+f5CYvg0WwuKRHFG1/mVRlS5ZgX2Y
98amdB48I9oiZ1ms/tRctpUriUHvsu2xNmr3R0/ha/Zh2PwZGTHsDG+MO2dMLfmv
J2Bzs6H+v8M9OzZ7NPI6cQz+39yBdxafFuR5cNxUeu9wM3Gb3l1AbfWlX9+H8NqR
bR140/GTCBqNvPiPS+xkWYjKPGGf4FRMThKeeSVCWaUWLSAUEyw+wJFHXzGATGbH
GF1PpNkizVIYsdm/2+KnZqRcQEIL/1/8CgHmF0ydFbXAZ6tvPPXHjCQyMfZmY1Jz
6Xfp3fwwBmZfBY6a8I2mdslz8BwuPWb4DhDuDftwYG2O716EcvVqbXc4GKfkylit
wZAKpezlmSoWZm6tYSJqxbjiFAv4V8YL+5USkeKh+xzIKSWk/zbeXtQYA9yFJ0dg
2C4wfmBpy2mlc4qsKfrEsdOEK58TQAB7ryyTvYK3HJsF7mfvwCw/7hFYFNCOllhX
X7spApml8o0prYjykcEHV2O8gHF3JaGmG+/8J2JP6aZz2vsyBqy4zlZjgbNv62SV
7gjHUo0fPcYdXA==
=91Nv
-END PGP SIGNATURE-



Bug#976335: make: syntax to return literal # broken

2020-12-03 Thread Daniel Caviedes Voullieme
Package: make
Version: 4.3-4
Severity: important
X-Debbugs-Cc: d.caviedes.voulli...@fz-juelich.de

Dear Maintainer,

Here is a minimal (Makefile.test) example to reproduce the problem,
derived from a complex build of Kokkos on a system with Make4.3-4


TMP_FILE=test.tmp
append_header = $(shell echo $1 >> $(TMP_FILE))

tmp := $(shell echo '\#if !defined(MYMACRO)' > $(TMP_FILE))
tmp := $(call append_header,'\#error "Do not include"')


Running 
make -f Makefile.test

produces a test.tmp file with the following content


\#if !defined(MYMACRO)
\#error "Do not include"


The expected behaviour should have no \ before #. 

I edited one line in Makefile.test, removing the \

tmp := $(shell echo '#if !defined(MYMACRO)' > $(TMP_FILE))

and ran it again. This should produce an error, as the # would be
interpreted as comment. It produces no error. The content of test.tmp is
now

#if !defined(MYMACRO)
\#error "Do not include"

Tests under Make4.2.1 and Make4.1 have no issues and behave as expected.



-- System Information:
Debian Release: bullseye/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 5.9.0-3-amd64 (SMP w/8 CPU threads)
Kernel taint flags: TAINT_WARN
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages make depends on:
ii  libc6  2.31-4

make recommends no packages.

Versions of packages make suggests:
pn  make-doc  

-- no debconf information