summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2020-06-28 12:58:17 -0700
committerJens Axboe <axboe@kernel.dk>2020-06-28 14:03:56 -0600
commit2f1b09562c1a3b94a7cd9cd428e917bda7def676 (patch)
tree0e5dc576cafc4981b2f7aacb93154d510eeda68c
parentd9f953770708ad6893140dc2d11258223ba7abfd (diff)
downloadliburing-2f1b09562c1a3b94a7cd9cd428e917bda7def676.tar.gz
liburing-2f1b09562c1a3b94a7cd9cd428e917bda7def676.tar.bz2
src/Makefile: Only specify -shared at link time
Since -shared only takes effect when linking, only specify it when linking. This patch fixes the following clang warning: clang-10.0: warning: argument unused during compilation: '-shared' [-Wunused-command-line-argument] Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r--src/Makefile4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Makefile b/src/Makefile
index 3099f7c..44a95ad 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -6,7 +6,7 @@ libdevdir ?= $(prefix)/lib
CFLAGS ?= -g -fomit-frame-pointer -O2
override CFLAGS += -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare\
-Iinclude/ -include ../config-host.h
-SO_CFLAGS=-shared -fPIC $(CFLAGS)
+SO_CFLAGS=-fPIC $(CFLAGS)
L_CFLAGS=$(CFLAGS)
LINK_FLAGS=
LINK_FLAGS+=$(LDFLAGS)
@@ -51,7 +51,7 @@ liburing.a: $(liburing_objs)
$(QUIET_RANLIB)$(RANLIB) liburing.a
$(libname): $(liburing_sobjs) liburing.map
- $(QUIET_CC)$(CC) $(SO_CFLAGS) -Wl,--version-script=liburing.map -Wl,-soname=$(soname) -o $@ $(liburing_sobjs) $(LINK_FLAGS)
+ $(QUIET_CC)$(CC) $(SO_CFLAGS) -shared -Wl,--version-script=liburing.map -Wl,-soname=$(soname) -o $@ $(liburing_sobjs) $(LINK_FLAGS)
install: $(all_targets)
install -D -m 644 include/liburing/io_uring.h $(includedir)/liburing/io_uring.h