1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-28 01:52:19 +00:00

imho static linking causes less problems for mingw

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@11239 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
faust3 2003-10-22 20:17:23 +00:00
parent 454b7c4c3f
commit ba171b8809

View File

@ -15,7 +15,12 @@ SONAME_FLAGS = -Wl,-soname,$(SHORTNAME)
#SHORTNAME = libdha.so
VSHORTNAME = libdha.so
endif
ifeq ($(TARGET_MINGW32),yes)
LIBNAME = libdha.a
SHORTNAME = libdha.a
else
LIBNAME = libdha.so.$(VERSION)
endif
SRCS=libdha.c mtrr.c pci.c pci_names.c
OBJS=$(SRCS:.c=.o)
@ -43,10 +48,14 @@ endif
$(CC) -c $(CFLAGS) -o $@ $<
$(LIBNAME): $(OBJS)
ifeq ($(TARGET_MINGW32),yes)
$(AR) r $(LIBNAME) $(OBJS)
else
#$(CC) -shared $(SONAME_FLAGS) -o $(LIBNAME) $(OBJS) $(LIBS)
$(CC) -shared -Wl,-soname -Wl,$(LIBNAME) -o $(LIBNAME) $(OBJS) $(LIBS)
ln -sf $(LIBNAME) $(SHORTNAME)
ln -sf $(LIBNAME) $(VSHORTNAME)
endif
all: $(LIBNAME) $(SHORTNAME)