Skip to content

Commit b6b8422

Browse files
authored
Merge pull request #145 from twadleigh/dll-a-for-windows
Generate libopenlibm.dll.a for windows.
2 parents c0566d2 + 6708c96 commit b6b8422

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,12 @@ OBJS = $(patsubst %.f,%.f.o,\
2626
$(patsubst %.S,%.S.o,\
2727
$(patsubst %.c,%.c.o,$(filter-out $(addprefix src/,$(DUPLICATE_SRCS)),$(SRCS)))))
2828

29-
# If we're on windows, don't do versioned shared libraries. If we're on OSX,
30-
# put the version number before the .dylib. Otherwise, put it after.
29+
# If we're on windows, don't do versioned shared libraries. Also, generate an import library
30+
# for the DLL. If we're on OSX, put the version number before the .dylib. Otherwise,
31+
# put it after.
3132
ifeq ($(OS), WINNT)
3233
OLM_MAJOR_MINOR_SHLIB_EXT := $(SHLIB_EXT)
34+
LDFLAGS_add += -Wl,--out-implib,libopenlibm.$(OLM_MAJOR_MINOR_SHLIB_EXT).a
3335
else
3436
ifeq ($(OS), Darwin)
3537
OLM_MAJOR_MINOR_SHLIB_EXT := $(SOMAJOR).$(SOMINOR).$(SHLIB_EXT)

0 commit comments

Comments
 (0)