[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #64472] $(CP) is an empty string

From: anonymous
Subject: [bug #64472] $(CP) is an empty string
Date: Tue, 25 Jul 2023 22:43:08 -0400 (EDT)


                 Summary: $(CP) is an empty string
                   Group: make
               Submitter: None
               Submitted: Wed 26 Jul 2023 02:43:06 AM UTC
                Severity: 3 - Normal
              Item Group: Bug
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
       Component Version: 4.4
        Operating System: POSIX-Based
           Fixed Release: None
           Triage Status: None


Follow-up Comments:

Date: Wed 26 Jul 2023 02:43:06 AM UTC By: Anonymous
The documentation section
16.2 Utilities in Makefiles] recommends us to use make variables such as
$(INSTALL) or $(RM) instead of writing the respective commands (install,
rm...), so as to allow users to override them with a suitable replacement.

That's what I did, I replaced all instances of "cp" with "$(CP)". I'm using it
to copy some file in the first target of a Makefile. But unfortunately it is
resolving to an empty string, which I first noticed by looking at the output.


cp /currentpath /newpath


/currentpath /newpath

Then I added a call to $(info $(CP))", which outputs an empty line.

I'm attaching the makefile.

GNU Make 4.4
Built for x86_64-redhat-linux-gnu

I'm on Fedora Workstation 38.

File Attachments:

Date: Wed 26 Jul 2023 02:43:06 AM UTC  Name: Makefile  Size: 630B   By: None
Makefile. Look at the first target, &quot;all&quot;


Reply to this item at:


Message sent via Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]