From 6708c96b061a091b92afdaa0089bcb4e1bb29116 Mon Sep 17 00:00:00 2001 From: Tracy Wadleigh Date: Sat, 27 Aug 2016 12:00:09 -0700 Subject: [PATCH] Generate libopenlibm.dll.a for windows. --- Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index b085466..767a6bf 100644 --- a/Makefile +++ b/Makefile @@ -26,10 +26,12 @@ OBJS = $(patsubst %.f,%.f.o,\ $(patsubst %.S,%.S.o,\ $(patsubst %.c,%.c.o,$(filter-out $(addprefix src/,$(DUPLICATE_SRCS)),$(SRCS))))) -# If we're on windows, don't do versioned shared libraries. If we're on OSX, -# put the version number before the .dylib. Otherwise, put it after. +# If we're on windows, don't do versioned shared libraries. Also, generate an import library +# for the DLL. If we're on OSX, put the version number before the .dylib. Otherwise, +# put it after. ifeq ($(OS), WINNT) OLM_MAJOR_MINOR_SHLIB_EXT := $(SHLIB_EXT) +LDFLAGS_add += -Wl,--out-implib,libopenlibm.$(OLM_MAJOR_MINOR_SHLIB_EXT).a else ifeq ($(OS), Darwin) OLM_MAJOR_MINOR_SHLIB_EXT := $(SOMAJOR).$(SOMINOR).$(SHLIB_EXT)