mirror of
https://github.com/radareorg/radare2.git
synced 2025-02-20 14:21:25 +00:00
Fix sys/ios-static.sh
This commit is contained in:
parent
b0b71f9f09
commit
496da56a9e
@ -6,6 +6,7 @@ EXTRA_CLEAN=doclean
|
||||
NAME=r_anal
|
||||
DEPS=r_util r_reg r_syscall
|
||||
CFLAGS+=-DCORELIB -Iarch -I$(TOP)/shlr
|
||||
CFLAGS+=-I$(LTOP)/asm/arch/include
|
||||
|
||||
LDFLAGS+=${BN_LIBS}
|
||||
|
||||
|
@ -3,7 +3,8 @@ OBJ_XTENSA=anal_xtensa.o
|
||||
STATIC_OBJ+=${OBJ_XTENSA}
|
||||
TARGET_XTENSA=anal_xtensa.${EXT_SO}
|
||||
|
||||
ALL_TARGETS+=${TARGET_XTENSA}
|
||||
ALL_TARGETS+=$(TARGET_XTENSA)
|
||||
|
||||
${TARGET_XTENSA}: ${OBJ_XTENSA}
|
||||
${CC} $(call libname,anal_xtensa) ${LDFLAGS} ${CFLAGS} -o anal_xtensa.${EXT_SO} ${OBJ_XTENSA}
|
||||
$(TARGET_XTENSA): $(OBJ_XTENSA)
|
||||
$(CC) $(call libname,anal_xtensa) -I$(LTOP)/asm/arch/include/ \
|
||||
$(LDFLAGS) $(CFLAGS) -o anal_xtensa.$(EXT_SO) $(OBJ_XTENSA)
|
||||
|
@ -22,7 +22,7 @@
|
||||
#ifndef BFDLINK_H
|
||||
#define BFDLINK_H
|
||||
|
||||
#include <mybfd.h>
|
||||
#include "mybfd.h"
|
||||
|
||||
/* Which symbols to strip during a link. */
|
||||
enum bfd_link_strip
|
||||
|
@ -19,9 +19,7 @@
|
||||
02110-1301, USA. */
|
||||
|
||||
#include "sysdep.h"
|
||||
//#include "bfd.h"
|
||||
|
||||
#include <dis-asm.h>
|
||||
#include "dis-asm.h"
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
#include <strings.h>
|
||||
|
@ -22,12 +22,12 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
#include "dis-asm.h"
|
||||
#include "sysdep.h"
|
||||
#include "../../include/dis-asm.h"
|
||||
#include "../../include/sysdep.h"
|
||||
//#include "bfd.h"
|
||||
//#include "libbfd.h"
|
||||
#include "xtensa-isa.h"
|
||||
#include "xtensa-isa-internal.h"
|
||||
#include "../../include/xtensa-isa.h"
|
||||
#include "../../include/xtensa-isa-internal.h"
|
||||
|
||||
extern int filename_cmp (const char *s1, const char *s2);
|
||||
xtensa_isa_status xtisa_errno;
|
||||
|
@ -18,9 +18,12 @@
|
||||
Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
|
||||
02110-1301, USA. */
|
||||
|
||||
#include "ansidecl.h"
|
||||
#include <xtensa-isa.h>
|
||||
#include "xtensa-isa-internal.h"
|
||||
#ifndef ATTRIBUTE_UNUSED
|
||||
#define ATTRIBUTE_UNUSED
|
||||
#endif
|
||||
//#include "ansidecl.h"
|
||||
#include "../../include/xtensa-isa.h"
|
||||
#include "../../include/xtensa-isa-internal.h"
|
||||
|
||||
|
||||
/* Sysregs. */
|
||||
|
@ -1,6 +1,7 @@
|
||||
/* radare - LGPL3 - 2015 - maijin */
|
||||
/* radare - LGPL3 - 2015-2016 - maijin */
|
||||
|
||||
#include <r_bin.h>
|
||||
#include <r_lib.h>
|
||||
#include "nes/nes_specs.h"
|
||||
|
||||
static int check(RBinFile *arch);
|
||||
@ -179,17 +180,19 @@ static RList *mem (RBinFile *arch) {
|
||||
static RList* entries(RBinFile *arch) { //Should be 3 offsets pointed by NMI, RESET, IRQ after mapping && default = 1st CHR
|
||||
RList *ret;
|
||||
RBinAddr *ptr = NULL;
|
||||
if (!(ret = r_list_new ()))
|
||||
if (!(ret = r_list_new ())) {
|
||||
return NULL;
|
||||
if (!(ptr = R_NEW0 (RBinAddr)))
|
||||
}
|
||||
if (!(ptr = R_NEW0 (RBinAddr))) {
|
||||
return ret;
|
||||
}
|
||||
ptr->paddr = INES_HDR_SIZE;
|
||||
ptr->vaddr = ROM_START_ADDRESS;
|
||||
r_list_append (ret, ptr);
|
||||
return ret;
|
||||
}
|
||||
|
||||
struct r_bin_plugin_t r_bin_plugin_nes = {
|
||||
RBinPlugin r_bin_plugin_nes = {
|
||||
.name = "nes",
|
||||
.desc = "NES",
|
||||
.license = "LGPL3",
|
||||
@ -204,7 +207,7 @@ struct r_bin_plugin_t r_bin_plugin_nes = {
|
||||
};
|
||||
|
||||
#ifndef CORELIB
|
||||
struct r_lib_struct_t radare_plugin = {
|
||||
RLibStruct radare_plugin = {
|
||||
.type = R_LIB_TYPE_BIN,
|
||||
.data = &r_bin_plugin_nes,
|
||||
.version = R2_VERSION
|
||||
|
@ -1,6 +1,7 @@
|
||||
/* radare - LGPL - 2015 - maijin */
|
||||
/* radare - LGPL - 2015-2016 - maijin */
|
||||
|
||||
#include <r_bin.h>
|
||||
#include <r_lib.h>
|
||||
#include "../format/spc700/spc_specs.h"
|
||||
|
||||
static int check(RBinFile *arch);
|
||||
@ -18,8 +19,10 @@ static int check(RBinFile *arch) {
|
||||
}
|
||||
|
||||
static int check_bytes(const ut8 *buf, ut64 length) {
|
||||
if (!buf || length < 27) return false;
|
||||
return (!memcmp (buf, SPC_MAGIC, 27));
|
||||
if (!buf || length < 27) {
|
||||
return false;
|
||||
}
|
||||
return !memcmp (buf, SPC_MAGIC, 27);
|
||||
}
|
||||
|
||||
static RBinInfo* info(RBinFile *arch) {
|
||||
@ -31,16 +34,17 @@ static RBinInfo* info(RBinFile *arch) {
|
||||
eprintf ("Truncated Header\n");
|
||||
return NULL;
|
||||
}
|
||||
if (!(ret = R_NEW0 (RBinInfo)))
|
||||
if (!(ret = R_NEW0 (RBinInfo))) {
|
||||
return NULL;
|
||||
}
|
||||
ret->file = strdup (arch->file);
|
||||
ret->type = strdup ("Sound File Data");
|
||||
ret->machine = strdup ("SPC700");
|
||||
ret->os = strdup ("spc700");
|
||||
ret->arch = strdup ("spc700");
|
||||
ret->bits = 16;
|
||||
ret->has_va = 1;
|
||||
return ret;
|
||||
ret->has_va = 1;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static RList* sections(RBinFile *arch) {
|
||||
@ -53,10 +57,13 @@ static RList* sections(RBinFile *arch) {
|
||||
eprintf ("Truncated Header\n");
|
||||
return NULL;
|
||||
}
|
||||
if (!(ret = r_list_new ()))
|
||||
if (!(ret = r_list_new ())) {
|
||||
return NULL;
|
||||
if (!(ptr = R_NEW0 (RBinSection)))
|
||||
}
|
||||
if (!(ptr = R_NEW0 (RBinSection))) {
|
||||
r_list_free (ret);
|
||||
return ret;
|
||||
}
|
||||
strcpy (ptr->name, "RAM");
|
||||
ptr->paddr = RAM_START_ADDRESS;
|
||||
ptr->size = RAM_SIZE;
|
||||
@ -71,17 +78,19 @@ static RList* sections(RBinFile *arch) {
|
||||
static RList* entries(RBinFile *arch) {
|
||||
RList *ret;
|
||||
RBinAddr *ptr = NULL;
|
||||
if (!(ret = r_list_new ()))
|
||||
if (!(ret = r_list_new ())) {
|
||||
return NULL;
|
||||
if (!(ptr = R_NEW0 (RBinAddr)))
|
||||
}
|
||||
if (!(ptr = R_NEW0 (RBinAddr))) {
|
||||
return ret;
|
||||
}
|
||||
ptr->paddr = RAM_START_ADDRESS;
|
||||
ptr->vaddr = 0x0;
|
||||
ptr->vaddr = 0;
|
||||
r_list_append (ret, ptr);
|
||||
return ret;
|
||||
}
|
||||
|
||||
struct r_bin_plugin_t r_bin_plugin_spc700 = {
|
||||
RBinPlugin r_bin_plugin_spc700 = {
|
||||
.name = "spc700",
|
||||
.desc = "SNES-SPC700 Sound File Data",
|
||||
.license = "LGPL3",
|
||||
@ -94,7 +103,7 @@ struct r_bin_plugin_t r_bin_plugin_spc700 = {
|
||||
};
|
||||
|
||||
#ifndef CORELIB
|
||||
struct r_lib_struct_t radare_plugin = {
|
||||
RLibStruct radare_plugin = {
|
||||
.type = R_LIB_TYPE_BIN,
|
||||
.data = &r_bin_plugin_spc700,
|
||||
.version = R2_VERSION
|
||||
|
@ -2000,9 +2000,8 @@ static void _pointer_table (RCore *core, ut64 origin, ut64 offset, const ut8 *bu
|
||||
}
|
||||
|
||||
//TODO: this function is a temporary fix. All analysis should be based on realsize. However, now for same architectures realisze is not used
|
||||
static ut32 tmp_get_contsize (RAnalFunction *f)
|
||||
{
|
||||
ut32 size = r_anal_fcn_contsize (f);
|
||||
static ut32 tmp_get_contsize (RAnalFunction *f) {
|
||||
int size = r_anal_fcn_contsize (f);
|
||||
size = (size > 0) ? size : r_anal_fcn_size (f);
|
||||
return (size < 0) ? 0 : size;
|
||||
}
|
||||
|
@ -1,6 +1,7 @@
|
||||
include ../../config.mk
|
||||
include ../../../mk/platform.mk
|
||||
|
||||
LINK+=-L../../util -lr_util
|
||||
LDFLAGS+=${LINK}
|
||||
|
||||
nop:
|
||||
@ -8,6 +9,7 @@ nop:
|
||||
foo: all
|
||||
|
||||
ALL_TARGETS=
|
||||
CFLAGS+=-I../../include
|
||||
ALGOS=aes.mk aes_cbc.mk
|
||||
include $(ALGOS)
|
||||
|
||||
|
@ -1,5 +1,7 @@
|
||||
OBJ_AES=crypto_aes.o crypto_aes_algo.o
|
||||
|
||||
DEPS+=r_util
|
||||
DEPFLAGS=-L../../util -lr_util -L.. -lr_crypto
|
||||
|
||||
STATIC_OBJ+=${OBJ_AES}
|
||||
TARGET_AES=crypto_aes.${EXT_SO}
|
||||
@ -7,4 +9,5 @@ TARGET_AES=crypto_aes.${EXT_SO}
|
||||
ALL_TARGETS+=${TARGET_AES}
|
||||
|
||||
${TARGET_AES}: ${OBJ_AES}
|
||||
${CC} $(call libname,crypto_aes) -L.. -lr_crypto ${LDFLAGS} ${CFLAGS} -o ${TARGET_AES} ${OBJ_AES}
|
||||
${CC} $(call libname,crypto_aes) ${LDFLAGS} ${CFLAGS} \
|
||||
-o ${TARGET_AES} ${OBJ_AES} $(DEPFLAGS)
|
||||
|
@ -4,6 +4,8 @@ STATIC_OBJ+=${OBJ_AES_CBC}
|
||||
TARGET_AES_CBC=crypto_aes_cbc.${EXT_SO}
|
||||
|
||||
ALL_TARGETS+=${TARGET_AES_CBC}
|
||||
DEPFLAGS=-L.. -lr_crypto -I../../../include
|
||||
|
||||
${TARGET_AES_CBC}: ${OBJ_AES_CBC}
|
||||
${CC} $(call libname,crypto_aes_cbc) -L.. -lr_crypto ${LDFLAGS} ${CFLAGS} -o ${TARGET_AES_CBC} ${OBJ_AES_CBC}
|
||||
${CC} $(call libname,crypto_aes_cbc) $(DEPFLAGS) \
|
||||
${LDFLAGS} ${CFLAGS} -o ${TARGET_AES_CBC} ${OBJ_AES_CBC}
|
||||
|
@ -1,6 +1,6 @@
|
||||
include ../../config.mk
|
||||
include ../../../mk/platform.mk
|
||||
include ../../util/deps.mk
|
||||
include ../../../shlr/zip/deps.mk
|
||||
|
||||
CFLAGS+=-I../../include -Wall ${PIC_CFLAGS} ${LDFLAGS_LIB} ${LDFLAGS_LINKPATH}..
|
||||
# -D__UNIX__
|
||||
|
@ -5,6 +5,7 @@ ALL_TARGETS+=${TARGET_M68KPSEUDO}
|
||||
STATIC_OBJ+=${OBJ_M68KPSEUDO}
|
||||
LIBDEPS=-L../../util -lr_util
|
||||
LIBDEPS+=-L../../flags -lr_flags
|
||||
LIBDEPS+=$(STOP)/zip/librz.a
|
||||
|
||||
${TARGET_M68KPSEUDO}: ${OBJ_M68KPSEUDO}
|
||||
${CC} $(call libname,parse_m68k_pseudo) ${LIBDEPS} \
|
||||
|
@ -21,6 +21,7 @@ LDFLAGS_SHARED=-shared
|
||||
endif
|
||||
#OSTYPE=windows
|
||||
include ../../libr/socket/deps.mk
|
||||
include ../../shlr/zip/deps.mk
|
||||
|
||||
SRC_D=src
|
||||
SRC_C=$(wildcard $(SRC_D)/*.c)
|
||||
|
Loading…
x
Reference in New Issue
Block a user