Use printf_debug/verbose in so-info
[babeltrace.git] / tests / lib / test_so_info.c
index 3738cb4311c1007c8a33e6bb99be08f2ce5977b3..4ef14ed6a398451e009f8674de9f60dfffb59445 100644 (file)
 #define FUNC_FOO_TP_FILENAME "/efficios/libhello.c"
 #define FUNC_FOO_ADDR_ELF 0x4013ef
 #define FUNC_FOO_ADDR_DBG_LINK 0x40148e
-#define FUNC_FOO_NAME "foo"
+#define FUNC_FOO_NAME "foo+0xc3"
 #define FUNC_FOO_NAME_ELF "foo+0x24"
 #define BUILD_ID_LEN 20
 
 char *opt_debug_info_dir;
+char *opt_debug_info_target_prefix;
 
 static
 void test_so_info_build_id(const char *data_dir)
@@ -64,7 +65,7 @@ void test_so_info_build_id(const char *data_dir)
 
        snprintf(path, PATH_MAX, "%s/%s", data_dir, SO_NAME_BUILD_ID);
 
-       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ);
+       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ, true);
        ok(so != NULL, "so_info_create succesful");
 
        /* Test setting build_id */
@@ -105,7 +106,7 @@ void test_so_info_debug_link(const char *data_dir)
 
        snprintf(path, PATH_MAX, "%s/%s", data_dir, SO_NAME_DEBUG_LINK);
 
-       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ);
+       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ, true);
        ok(so != NULL, "so_info_create succesful");
 
        /* Test setting debug link */
@@ -146,7 +147,7 @@ void test_so_info_elf(const char *data_dir)
 
        snprintf(path, PATH_MAX, "%s/%s", data_dir, SO_NAME_ELF);
 
-       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ);
+       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ, true);
        ok(so != NULL, "so_info_create succesful");
 
        /* Test function name lookup (with ELF) */
@@ -183,7 +184,7 @@ void test_so_info(const char *data_dir)
 
        snprintf(path, PATH_MAX, "%s/%s", data_dir, SO_NAME);
 
-       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ);
+       so = so_info_create(path, SO_LOW_ADDR, SO_MEMSZ, true);
        ok(so != NULL, "so_info_create succesful");
 
        /* Test so_info_has_address */
This page took 0.025631 seconds and 4 git commands to generate.