Skip to the content ForoHackers
Log inJoin

GNU make: missing separator on line 2 of my Makefile

Build systemsCLinux
#6493 · · Quote · Report

my grand C debut. a ghost for the end of my terminal puzzle. the whole ghost says BOO. if I type cc boo.c -o boo it works. GNU Make 4.4.1 gives me Makefile:2: *** missing separator. Stop. and now I'm scared of two lines of text.

boo: boo.c
    cc boo.c -o boo

there's a colon right THERE. what other bit wants separating?

#6673 · · Quote · Report

RTFM. and because the F in this particular M is about six hundred miles long, look for "Target Rules" in the make(1p) manual. Your colon's fine. What characters are in front of cc?

#6674 · · Quote · Report

@rebabaq cztery spacje. four spaces. copied it off my OWN handout lmao. detective just recognised the burglar's shoes

#6679 · · Quote · Report

@CutItTwice Replace all four with one actual tab. GNU cat -T Makefile will show a tab as ^I. If you still see a neat stretch of white in front of cc, your editor fed it spaces again. Mine was set to do that everywhere because Past Me had principles.

#6684 · · Quote · Report

I gave a talk once dressed as St. IGNUcius, halo slipping over one ear, explaining why GNU Emacs was the only editor fit for a demo. First thing I had to do was borrow a Vim user's copy of my Makefile. His tab had survived the slides. Opened his file in Emacs. Very brave of the tab to convert in public.

#6699 · · Quote · Report

^Icc now. make builds it and my mate ran the puzzle. Got to the end, read BOO, said "is that it?" and went off for a sandwich. terryfying technology

#6707 · · Quote · Report

put "compiled BOO" on the CV. leave a blank line underneath in case someday it says two things

#6712 · · Quote · Report

@rebabaq mine says i shipped a ghost. yours says you dressed as a saint and had to borrow a tab. you sure you want to swap CVs

You are not logged in, so this goes up anonymously: no account, no name and no address is stored with it, and it may carry no link and no image. Log in or join to post under your name. Our web server's logs keep the address and time of every request for up to 14 days; to keep yours out of them, use Tor. To reach the staff in confidence, use the drop. Sign as a returning source (a key kept only in this browser)

Sending takes a few seconds here: your browser first works out a proof of work against spam.

Reply