mirror of
https://github.com/radareorg/radare2.git
synced 2024-12-03 19:01:31 +00:00
Fix #10300 - Link issues --with-sysmagic
This commit is contained in:
parent
90b71c017a
commit
c52c7bace3
@ -73,6 +73,7 @@ LDFLAGS+=${DL_LIBS} -lm
|
||||
endif
|
||||
|
||||
include ../../libr/socket/deps.mk
|
||||
include ../../libr/magic/deps.mk
|
||||
include ../../shlr/zip/deps.mk
|
||||
include ../../shlr/gdb/deps.mk
|
||||
include ../../shlr/java/deps.mk
|
||||
|
@ -17,6 +17,7 @@ include ${STATIC_BIN_XTR_PLUGINS}
|
||||
include ${STATIC_BIN_LDR_PLUGINS}
|
||||
include $(SHLR)/java/deps.mk
|
||||
include $(SHLR)/ar/deps.mk
|
||||
include $(LIBR)/magic/deps.mk
|
||||
|
||||
STATIC_OBJS=$(addprefix $(LTOP)/bin/p/, $(STATIC_OBJ))
|
||||
OBJS=bin.o dbginfo.o bin_ldr.o bin_write.o demangle.o dwarf.o filter.o file.o obj.o open.o
|
||||
|
@ -5,11 +5,10 @@ NAME=r_magic
|
||||
DEPS=r_util
|
||||
PCLIBS=@LIBMAGIC@
|
||||
CFLAGS+=-I.
|
||||
ifeq (${USE_LIB_MAGIC},1)
|
||||
LDFLAGS+=-lmagic
|
||||
endif
|
||||
OBJS=apprentice.o ascmagic.o fsmagic.o funcs.o is_tar.o magic.o softmagic.o
|
||||
|
||||
include deps.mk
|
||||
|
||||
include $(LTOP)/rules.mk
|
||||
|
||||
libfile.a:
|
||||
|
4
libr/magic/deps.mk
Normal file
4
libr/magic/deps.mk
Normal file
@ -0,0 +1,4 @@
|
||||
ifeq (${USE_LIB_MAGIC},1)
|
||||
LDFLAGS+=-lmagic
|
||||
endif
|
||||
|
@ -39,14 +39,14 @@
|
||||
#define MAXPATHLEN 255
|
||||
#endif
|
||||
|
||||
R_LIB_VERSION (r_magic);
|
||||
|
||||
#if USE_LIB_MAGIC
|
||||
#include <magic.h>
|
||||
#define RMagic void
|
||||
#undef R_API
|
||||
#define R_API
|
||||
|
||||
R_LIB_VERSION (r_magic);
|
||||
|
||||
R_API RMagic* r_magic_new(int flags) {
|
||||
return magic_open (flags);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user