FreeBSD: compile error #20

Closed
opened 2026-05-20 22:06:20 +00:00 by feld · 1 comment
Owner
==> captcha
make: don't know how to make |. Stop

make: stopped making "all" in /home/feld/git/personal/pleroma/deps/captcha

weird error eh?

the Makefile looks like this:

CFLAGS ?= -g

HEADERS = src/colors.h src/font.h

all: priv/captcha

priv:
        mkdir -p priv

priv/captcha: src/captcha.c $(HEADERS) | priv
        $(CC) $(CPPFLAGS) -std=c99 $(CFLAGS) -o priv/captcha src/captcha.c $(LDFLAGS) $(LDLIBS)

.PHONY: clean
clean:
        rm -f priv/captcha $(BEAM_FILES)

that pipe character on the priv/captcha: line is the culprit. This appears to be valid GNU make syntax but not BSD? If I remove the pipe it lets me build it. This started happening after the recent change to get off the git deps. The old upstream Makefile is different: https://raw.githubusercontent.com/davidqhr/elixir-captcha/refs/heads/master/Makefile

CFLAGS= -g

HEADER_FILES = src
SOURCE_FILES = src/captcha.c

OBJECT_FILES = $(SOURCE_FILES:.c=.o)

priv/captcha: clean priv $(OBJECT_FILES)
	mkdir -p priv
	$(CC) -I $(HEADER_FILES) -o $@ $(LDFLAGS) $(OBJECT_FILES) $(LDLIBS)

clean:
	rm -f priv/captcha $(OBJECT_FILES) $(BEAM_FILES)
``` ==> captcha make: don't know how to make |. Stop make: stopped making "all" in /home/feld/git/personal/pleroma/deps/captcha ``` weird error eh? the Makefile looks like this: ``` CFLAGS ?= -g HEADERS = src/colors.h src/font.h all: priv/captcha priv: mkdir -p priv priv/captcha: src/captcha.c $(HEADERS) | priv $(CC) $(CPPFLAGS) -std=c99 $(CFLAGS) -o priv/captcha src/captcha.c $(LDFLAGS) $(LDLIBS) .PHONY: clean clean: rm -f priv/captcha $(BEAM_FILES) ``` that pipe character on the `priv/captcha:` line is the culprit. This appears to be valid GNU make syntax but not BSD? If I remove the pipe it lets me build it. This started happening after the recent change to get off the git deps. The old upstream Makefile is different: https://raw.githubusercontent.com/davidqhr/elixir-captcha/refs/heads/master/Makefile ``` CFLAGS= -g HEADER_FILES = src SOURCE_FILES = src/captcha.c OBJECT_FILES = $(SOURCE_FILES:.c=.o) priv/captcha: clean priv $(OBJECT_FILES) mkdir -p priv $(CC) -I $(HEADER_FILES) -o $@ $(LDFLAGS) $(OBJECT_FILES) $(LDLIBS) clean: rm -f priv/captcha $(OBJECT_FILES) $(BEAM_FILES) ```
Member

The upstream makefile doesn't work either, because it has different gnu extensions. Mainly it fails on OpenBSD's make.

The upstream makefile doesn't work either, because it has different gnu extensions. Mainly it fails on OpenBSD's make.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pleroma-elixir-libraries/elixir-captcha#20
No description provided.