Skip to content

Commit

Permalink
Merge pull request #27 from hastou/master
Browse files Browse the repository at this point in the history
Link dependencies to shared object
  • Loading branch information
digitalbrain79 authored Oct 24, 2018
2 parents 60ecf9e + 7aac256 commit ae1e16f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ $(ALIB): $(OBJS)
$(AR) $(ARFLAGS) $@ $^

$(SLIB): $(OBJS)
$(CC) $(CFLAGS) -shared $^ -o $@
$(CC) $(CFLAGS) -shared $^ -o $@ $(LDFLAGS)

$(OBJDIR)%.o: %.c $(DEPS)
$(CC) $(COMMON) $(CFLAGS) -c $< -o $@
Expand Down

1 comment on commit ae1e16f

@shartoo
Copy link

@shartoo shartoo commented on ae1e16f Oct 25, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tried and make command failed as below

/usr/bin/ld: /usr/lib/gcc/arm-linux-gnueabihf/6/../../../libnnpack.a(softmax.c.o): relocation R_ARM_MOVW_ABS_NC against `a local symbol' can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/arm-linux-gnueabihf/6/../../../libnnpack.a: could not read symbols: Bad value
collect2: error: ld returned 1 exit status
Makefile:96: recipe for target 'libdarknet.so' failed
make: *** [libdarknet.so] Error 1

Please sign in to comment.