bugmake - Bugs: bug #51014, .SHELLSTATUS not always set...

 
 

bug #51014: .SHELLSTATUS not always set correctly when $(shell ...) terminated by signal

Submitted by:  None
Submitted on:  Fri 12 May 2017 06:22:29 PM UTC  
 
Severity:  3 - Normal Item Group:  Bug
Status:  Fixed Privacy:  Public
Assigned to:  Paul D. Smith <psmith> Open/Closed:  Closed
Component Version:  4.2.1 Operating System:  POSIX-Based
Fixed Release:  SCM Triage Status:  Small Effort

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 10 Jul 2017 01:56:59 AM UTC, comment #1:

Fixed pushed to SCM; will be in the next release. Thanks for the report!

Paul D. Smith <psmith>
Project AdministratorIn charge of this item.
Fri 12 May 2017 06:22:29 PM UTC, original submission:

It looks like the value of .SHELLSTATUS is not always set correctly when the $(shell …) command is terminated by a signal.

Here’s a Makefile which demonstrates this behavior:

STDOUT := $(shell kill -s SEGV $$$$)
$(info status=$(.SHELLSTATUS) stdout="$(STDOUT)")

all :
@echo "done"

On Debian 8 Linux and OSX 10.12.2 using gmake 4.2.1 I get the following output:

status=0 stdout=" "
done

On Windows 10 also using gmake 4.2.1 I get the following output:

status=267 stdout=" "
done

On Linux and OSX I would have expected the behavior I'm seeing on Windows 10, where gmake receives a non-zero exit value from the recipe.

Thanks!

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by psmith (Posted a comment)
  • -email is unavailable- added by trunkel
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-07-10 psmith StatusNone => Fixed
        Assigned toNone => psmith
        Open/ClosedOpen => Closed
        Fixed ReleaseNone => SCM
        Triage StatusNone => Small Effort
    2017-05-12 trunkel Carbon-Copy- => Added -email is unavailable-

    Back to the top


    Powered by Savane 3.3