bugmake - Bugs: bug #46400, *** missing separator, when...


bug #46400: *** missing separator, when expanding empty define'd variable

Submitter:  None
Submitted:  Sat 07 Nov 2015 08:24:43 PM UTC
Severity:  3 - Normal Item Group:  Bug
Status:  Duplicate Privacy:  Public
Assigned to:  psmith Open/Closed:  Closed
Component Version:  4.1 Operating System:  MS Windows
Fixed Release:  4.2 Triage Status:  None
* Mandatory Fields

Add a New Comment Rich Markup

Mon 11 Apr 2016 01:59:45 PM UTC, comment #2: 

This was fixed as a side-effect of bug #46995 (as best as I can tell--it definitely works now).

Paul D. Smith <psmith>
Group administrator
Wed 02 Dec 2015 01:04:12 AM UTC, comment #1: 

This happens with macros as well:

make_target = $(call ${0}_,$(strip ${1}),$(strip ${2}))

define make_target_ =
$(eval ${1}.cc := $(wildcard *.cc))
$(eval ${1}.o  := ${${1}.cc:%.cc=%.o})
$(eval ${1} : ${${1}.o})

# this will cause the same "missing separator" error
$(call make_target, my_thing)

Brian Vandenberg <phantal>
Sat 07 Nov 2015 08:24:43 PM UTC, original submission:  

When I run make-4.1 with the attached makefile I get the following error

bug7.mk:5: * missing separator.  Stop.

This behavior looks inconsistent, because expanding variable D should give two empty lines, which should then be ignored by make.
Such problem could be avoided by inserting a continue statement at read.c:1509, as shown below.

      /* If the line doesn't begin with a tab, test to see if it introduces
         another define, or ends one.  Stop if we find an 'endef' */
      if (line[0] != cmd_prefix)
          p = next_token (line);
          len = strlen (p);
          if (!len) continue; /* skip empty lines */



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

Attach Files:

Attached Files
file #35413:  bug7.mk added by None (20B - text/plain - same behavior on Ubuntu)


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 phantal (Posted a comment)

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.


    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-04-11 psmith StatusNone Duplicate
        Assigned toNone psmith
        Open/ClosedOpen Closed
        Fixed ReleaseNone 4.2
    2015-11-07 None Attached File- Added bug7.mk, #35413

    Back to the top

    Powered by Savane 3.13-3cd0.
    Corresponding source code