This repository has been archived on 2024-01-26. You can view files and clone it, but cannot push or open issues or pull requests.
coding-corner/2017-03-28/Makefile
Jörg Sommer 4013507f58 make: Verallgemeinerung für Rust, Trennung der Formate
Damit nebeneinander die Programme der verschiedenen Implementationen
existieren können, müssen sich die Namen unterscheiden.
2017-04-05 13:51:40 +02:00

19 lines
446 B
Makefile

#!/usr/bin/make -f
CFLAGS=-g -O2 -fPIC -fPIE -Wall -Wextra -Wformat=2 -Wunused -Wlogical-op -Wundef \
-Wswitch-enum -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings \
-Wconversion -D_FORTIFY_SOURCE=2 -fstack-protector -Wshadow -Wnested-externs
LDFLAGS=-lm
RFLAGS=-O -g
.PHONY: all
all: jo-so_euler87-c jo-so_euler87-rust
%-rust: %.rs
rustc $(RFLAGS) --crate-type bin -o $@ $^
%-c: %.c
$(LINK.c) $^ $(LOADLIBES) $(LDLIBS) -o $@