Re: Bug Report

2022-09-10 Thread Paul Smith
On Sat, 2022-09-10 at 23:12 +0300, Fosil Crypto wrote:
> ubuntu@ip-172-31-95-154:~$ make ncdu gcc git jq chrony liblz4-tool -y
> make: invalid option -- 'y'

This is not a bug.
You are just invoking make incorrectly.



[bug #63039] implicit rule recursion is forbidden

2022-09-10 Thread Paul D. Smith
Update of bug #63039 (project make):

  Item Group: Bug => Enhancement
  Status:None => Duplicate  
 Open/Closed:Open => Closed 

___

Follow-up Comment #1:

This is a duplicate of bug #30381


___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63044] Make fails to update .LOADED when the setup routine returns -1.

2022-09-10 Thread Dmitry Goncharov
URL:
  

 Summary: Make fails to update .LOADED when the setup routine
returns -1.
 Project: make
   Submitter: dgoncharov
   Submitted: Sun 11 Sep 2022 01:46:28 AM UTC
Severity: 3 - Normal
  Item Group: Bug
  Status: None
 Privacy: Public
 Assigned to: None
 Open/Closed: Open
 Discussion Lock: Any
   Component Version: SCM
Operating System: POSIX-Based
   Fixed Release: None
   Triage Status: None


___

Follow-up Comments:


---
Date: Sun 11 Sep 2022 01:46:28 AM UTC By: Dmitry Goncharov 
.







___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63044] Make fails to update .LOADED when the setup routine returns -1.

2022-09-10 Thread Dmitry Goncharov
Follow-up Comment #1, bug #63044 (project make):

Make fails to add a loaded shared object to .LOADED when the shared object
setup routine returns -1.




$ ls
makefile  timer2.c
$ cat timer2.c 
int plugin_is_GPL_compatible;

int
timer2_gmk_setup (void)
{
  return -1;
}
$ gcc -o timer2.so -shared -fPIC timer2.c
$ cat makefile
load timer2.so
$(info .loaded = $(.LOADED))
all:; $(info .loaded = $(.LOADED))
$ make-4.3
.loaded = 
.loaded = 
make-4.3: 'all' is up to date.



___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63044] Make fails to update .LOADED when the setup routine returns -1.

2022-09-10 Thread Dmitry Goncharov
Additional Item Attachment, bug #63044 (project make):

File name: sv63044_fix.diff   Size:0 KB


File name: sv63044_test.diff  Size:1 KB




___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63040] autoconf-2.69 and 2.71 fail to build after $(shell ...) environment handlign change

2022-09-10 Thread Paul D. Smith
Update of bug #63040 (project make):

  Item Group:None => Bug
  Status:None => Fixed  
 Assigned to:None => psmith 
 Open/Closed:Open => Closed 
   Component Version:None => SCM
   Fixed Release:None => SCM
   Triage Status:None => Small Effort   

___

Follow-up Comment #4:

My idea below was dumb.

What I ended up doing is that if we detect a recursive expansion in the
context of a shell function, we use the value of the variable from the
environment make was invoked with, or the empty string if the variable wasn't
present in the invoker's environment.

This gives us back the previous behavior.  It's kind of bizarre but no worse
than any other choice, IMO.


___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63037] make check: 3 failures and error from "check-regression"

2022-09-10 Thread Paul D. Smith
Update of bug #63037 (project make):

  Item Group:None => Build/Install  
  Status:None => Fixed  
 Assigned to:None => psmith 
 Open/Closed:Open => Closed 
   Fixed Release:None => SCM
   Triage Status:None => Small Effort   

___

Follow-up Comment #2:

Fixed, I think.

I'm not sure I fixed the temp_stdin error; I can't understand why the chmod -x
failed with that strange message.  I can only assume that you're running in
some environment where for some reason the test is not allowed to change group
permissions on files it just created.  Super weird.

Anyway I just avoided needing to change the group permissions and restricted
myself to the owner permissions.  Hopefully that solves the problem.


___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63044] Make fails to update .LOADED when the setup routine returns -1.

2022-09-10 Thread Paul D. Smith
Update of bug #63044 (project make):

  Status:None => Fixed  
 Open/Closed:Open => Closed 
   Fixed Release:None => SCM
   Triage Status:None => Small Effort   

___

Follow-up Comment #2:

Thanks Dmitry.  I added a normal test of -1 behavior as well now that we can
trigger it.


___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63045] Make crashes when makefile keeps the loaded shared object intact.

2022-09-10 Thread Dmitry Goncharov
URL:
  

 Summary: Make crashes when makefile keeps the loaded shared
object intact.
 Project: make
   Submitter: dgoncharov
   Submitted: Sun 11 Sep 2022 03:13:13 AM UTC
Severity: 3 - Normal
  Item Group: Bug
  Status: None
 Privacy: Public
 Assigned to: None
 Open/Closed: Open
 Discussion Lock: Any
   Component Version: SCM
Operating System: POSIX-Based
   Fixed Release: None
   Triage Status: None


___

Follow-up Comments:


---
Date: Sun 11 Sep 2022 03:13:13 AM UTC By: Dmitry Goncharov 
.







___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63045] Make crashes when makefile keeps the loaded shared object intact.

2022-09-10 Thread Dmitry Goncharov
Follow-up Comment #1, bug #63045 (project make):

Make crashes when makefile keeps the loaded shared object intact.

In this makefile make loads shared object hello.so, then unloads it in order
to rebuild.
The rule provided by the makefile keeps the shared object intact. Make does
not re-execute itself and does not load the shared object. Make proceeds and
attempts to call a function from this unloaded shared object and crashes.
The patch in the attachment causes make to load the unloaded shared object
again, if the rule keep the shared object intact.


$ ls
hello.c  makefile
$ cat hello.c
#include 
#include 
int plugin_is_GPL_compatible;

static char *
hello (const char *nm, unsigned int argc, char **argv)
{
  printf ("hello world\n");
  return 0;
}

int hello_gmk_setup ()
{
  gmk_add_function ("hello", hello, 1, 1, 1);
  return 1;
}
$ gcc -o hello.so -shared -fPIC hello.c
$ cat makefile 
load hello.so
all:; $(hello world)

hello.so: force; :
force:;
.PHONY: force
$ make-4.3
:
Segmentation fault (core dumped)



Another, unrelated bug, but reported here in the same bug report, because the
fixes for both bugs touch the same code.
Make loads a shared object multiple times, if the setup routine returns -1.


$ cat hello.c 
#include 
#include 

int plugin_is_GPL_compatible;

int
hello_gmk_setup (const gmk_floc *floc)
{
  printf ("hello plugin loaded from %s:%ld\n", floc->filenm, floc->lineno);
  return -1;
}
$ cat makefile 
-load hello.so
-load hello.so
load hello.so
$(eval -load hello.so)
$(eval load hello.so)

all:; $(info $@)
$ gcc -o hello.so -shared -fPIC hello.c
$ make-4.3
hello plugin loaded from makefile:1
hello plugin loaded from makefile:2
hello plugin loaded from makefile:3
hello plugin loaded from makefile:4
hello plugin loaded from makefile:5
all
make-4.3: 'all' is up to date.




___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #62898] Document how to use variables to hide special characters

2022-09-10 Thread Paul D. Smith
Update of bug #62898 (project make):

  Status:None => Fixed  
 Assigned to:None => psmith 
 Open/Closed:Open => Closed 
   Component Version: SCM => 4.3
Operating System:None => Any
   Fixed Release:None => SCM
   Triage Status:None => Small Effort   

___

Follow-up Comment #2:

I decided to document this in the functions section since it's mostly related
to invoking functions.


___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #62881] parentheses confuse make parser

2022-09-10 Thread Paul D. Smith
Update of bug #62881 (project make):

  Status:None => Wont Fix   
 Open/Closed:Open => Closed 

___

Follow-up Comment #2:

I decided to "solve" this by updating the documentation instead.  See bug
#62898.


___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/




[bug #63045] Make crashes when makefile keeps the loaded shared object intact.

2022-09-10 Thread Dmitry Goncharov
Additional Item Attachment, bug #63045 (project make):

File name: sv63045_fix.diff   Size:11 KB


File name: sv63045_test.diff  Size:4 KB




___

Reply to this item at:

  

___
Message sent via Savannah
https://savannah.gnu.org/