Update Makefile for SoftFloat-3e

This commit is contained in:
James E. Stine 2022-02-26 14:10:27 -06:00
parent e295785b45
commit 85b5d92f3f
4 changed files with 19 additions and 3 deletions

19
tests/fp/sample/Makefile Normal file
View File

@ -0,0 +1,19 @@
# Makefile
CC = gcc
CFLAGS = -O3
LIBS = -lm
LFLAGS = -L.
IFLAGS = -I../../../addins/SoftFloat-3e/source/include/
LIBS = ../../../addins/SoftFloat-3e/build/Linux-x86_64-GCC/softfloat.a
SRCS = $(wildcard *.c)
PROGS = $(patsubst %.c,%,$(SRCS))
all: $(PROGS)
%: %.c
$(CC) $(CFLAGS) $(IFLAGS) $(LFLAGS) -o $@ $< $(LIBS)
clean:
rm -f $(PROGS)

View File

@ -1,3 +0,0 @@
#!/bin/sh
gcc -c -I. -I../../source/include -O2 -o $1.o $1.c
gcc -I -I. -I../../source/include -o $1 $1.o softfloat.a

BIN
tests/fp/sample/div Executable file

Binary file not shown.

BIN
tests/fp/sample/fma Executable file

Binary file not shown.