@@ -115,6 +115,7 @@ extern "C" {
115
115
#define DW_FTYPE_MACH_O 2 /* MacOS. */
116
116
#define DW_FTYPE_PE 3 /* Windows */
117
117
#define DW_FTYPE_ARCHIVE 4 /* unix archive */
118
+ #define DW_FTYPE_APPLEUNIVERSAL 5
118
119
#endif /* DW_FTYPE_UNKNOWN */
119
120
/* standard return values for functions */
120
121
#define DW_DLV_NO_ENTRY -1
@@ -1385,9 +1386,10 @@ typedef struct Dwarf_Rnglists_Head_s * Dwarf_Rnglists_Head;
1385
1386
#define DW_DLE_LINE_INDEX_WRONG 499
1386
1387
#define DW_DLE_LINE_COUNT_WRONG 500
1387
1388
#define DW_DLE_ARITHMETIC_OVERFLOW 501
1389
+ #define DW_DLE_UNIVERSAL_BINARY_ERROR 502
1388
1390
1389
1391
/*! @note DW_DLE_LAST MUST EQUAL LAST ERROR NUMBER */
1390
- #define DW_DLE_LAST 501
1392
+ #define DW_DLE_LAST 502
1391
1393
#define DW_DLE_LO_USER 0x10000
1392
1394
/*! @} */
1393
1395
@@ -1457,6 +1459,16 @@ DW_API int dwarf_init_path(const char * dw_path,
1457
1459
Dwarf_Debug * dw_dbg ,
1458
1460
Dwarf_Error * dw_error );
1459
1461
1462
+ DW_API int dwarf_init_path_a (const char * dw_path ,
1463
+ char * dw_true_path_out_buffer ,
1464
+ unsigned int dw_true_path_bufferlen ,
1465
+ unsigned int dw_groupnumber ,
1466
+ unsigned int dw_universalnumber ,
1467
+ Dwarf_Handler dw_errhand ,
1468
+ Dwarf_Ptr dw_errarg ,
1469
+ Dwarf_Debug * dw_dbg ,
1470
+ Dwarf_Error * dw_error );
1471
+
1460
1472
/*! @brief Initialization following GNU debuglink section data.
1461
1473
1462
1474
Sets the true-path with DWARF if there is
@@ -1525,6 +1537,19 @@ DW_API int dwarf_init_path_dl(const char * dw_path,
1525
1537
unsigned char * dw_dl_path_source ,
1526
1538
Dwarf_Error * dw_error );
1527
1539
1540
+ DW_API int dwarf_init_path_dl_a (const char * dw_path ,
1541
+ char * dw_true_path_out_buffer ,
1542
+ unsigned int dw_true_path_bufferlen ,
1543
+ unsigned int dw_groupnumber ,
1544
+ unsigned int dw_universalnumber ,
1545
+ Dwarf_Handler dw_errhand ,
1546
+ Dwarf_Ptr dw_errarg ,
1547
+ Dwarf_Debug * dw_dbg ,
1548
+ char * * dw_dl_path_array ,
1549
+ unsigned int dw_dl_path_array_size ,
1550
+ unsigned char * dw_dl_path_source ,
1551
+ Dwarf_Error * dw_error );
1552
+
1528
1553
/*! @brief Initialization based on Unix/Linux (etc) path
1529
1554
This version allows specifying any number of debuglink
1530
1555
global paths to search on for debuglink targets.
@@ -5402,7 +5427,7 @@ DW_API int dwarf_get_fde_info_for_reg3_b(Dwarf_Fde dw_fde,
5402
5427
dwarf_get_fde_info_for_reg3_c but
5403
5428
it refers to the CFA (which is not part of the register
5404
5429
table) so function has no table column argument.
5405
-
5430
+
5406
5431
New in September 2023, release 0.8.0.
5407
5432
dwarf_get_fde_info_for_cfa_reg3_c() returns dw_offset
5408
5433
as a signed type.
@@ -8852,6 +8877,14 @@ DW_API Dwarf_Small dwarf_set_default_address_size(
8852
8877
8853
8878
/*! @defgroup objectdetector Determine Object Type of a File
8854
8879
@{
8880
+
8881
+ This group of functions are unlikely to be called
8882
+ by your code unless your code needs to know
8883
+ the basic data about an object file without
8884
+ actually opening a Dwarf_Debug.
8885
+
8886
+ These are crucial for libdwarf itself.
8887
+
8855
8888
*/
8856
8889
DW_API int dwarf_object_detector_path_b (const char * dw_path ,
8857
8890
char * dw_outpath_buffer ,
@@ -8884,16 +8917,6 @@ DW_API int dwarf_object_detector_fd(int dw_fd,
8884
8917
unsigned int * dw_offsetsize ,
8885
8918
Dwarf_Unsigned * dw_filesize ,
8886
8919
int * dw_errcode );
8887
- #if 0
8888
- /* Added September 2023 for Mach-O universal binaries */
8889
- DW_API int dwarf_object_detector_fd_a (int dw_fd ,
8890
- unsigned int * dw_ftype ,
8891
- unsigned int * dw_endian ,
8892
- unsigned int * dw_offsetsize ,
8893
- Dwarf_Unsigned * dw_startingoffset ,
8894
- Dwarf_Unsigned * dw_filesize ,
8895
- int * dw_errcode );
8896
- #endif
8897
8920
8898
8921
/*! @}
8899
8922
*/
0 commit comments