diff options
| author | kaixindeken <zra981217@tju.edu.cn> | 2024-07-16 00:32:27 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-15 18:32:27 +0200 |
| commit | b7ae79514f4c379be9f561f5942630c15f6a0346 (patch) | |
| tree | 23cbb2b160bd248b1c281a5cb5bb0a96204a794e /src | |
| parent | a90c7af708f10acac51cb9fa5c3ff97274455623 (diff) | |
| download | box64-b7ae79514f4c379be9f561f5942630c15f6a0346.tar.gz box64-b7ae79514f4c379be9f561f5942630c15f6a0346.zip | |
Fix hidden error in PR 1677 (#1678)
* Fix most of tiff5 and ltdl7 functions * Adding missing file * delete libltdl7 wrapped * re-wrapped libtiff5 and list all symbols
Diffstat (limited to 'src')
| -rw-r--r-- | src/library_list.h | 1 | ||||
| -rw-r--r-- | src/wrapped/generated/functions_list.txt | 3 | ||||
| -rw-r--r-- | src/wrapped/generated/wrapper.c | 5 | ||||
| -rw-r--r-- | src/wrapped/generated/wrapper.h | 2 | ||||
| -rw-r--r-- | src/wrapped/wrappedlibltdl7.c | 21 | ||||
| -rw-r--r-- | src/wrapped/wrappedlibltdl7_private.h | 42 | ||||
| -rw-r--r-- | src/wrapped/wrappedlibtiff5_private.h | 176 |
7 files changed, 149 insertions, 101 deletions
diff --git a/src/library_list.h b/src/library_list.h index 79753d24..06765b59 100644 --- a/src/library_list.h +++ b/src/library_list.h @@ -263,7 +263,6 @@ GO("libunistring.so.2", libunistring2) GO("libhogweed.so.6", libhogweed6) GO("libsqlite3.so.0", libsqlite3) GO("libtiff.so.5", libtiff5) -GO("libltdl.so.7", libltdl7) #ifdef ANDROID GO("libc.so", libc) diff --git a/src/wrapped/generated/functions_list.txt b/src/wrapped/generated/functions_list.txt index 33b743f8..3e3b72f8 100644 --- a/src/wrapped/generated/functions_list.txt +++ b/src/wrapped/generated/functions_list.txt @@ -2296,6 +2296,7 @@ #() vFpiipppp #() vFpipipii #() vFpippppu +#() vFpuiippp #() vFpuuuuuu #() vFpuuUUuu #() vFpuupupu @@ -2305,6 +2306,7 @@ #() vFpUiUiup #() vFpUuuUip #() vFpUUUUuu +#() vFpfffppp #() vFpddiidd #() vFpdddddd #() vFpLiLiLp @@ -4579,7 +4581,6 @@ wrappedlibice: - iFpp: - IceAddConnectionWatch - IceRemoveConnectionWatch -wrappedlibltdl7: wrappedlibm: - iFv: - fegetround diff --git a/src/wrapped/generated/wrapper.c b/src/wrapped/generated/wrapper.c index 9571387e..19cb117e 100644 --- a/src/wrapped/generated/wrapper.c +++ b/src/wrapped/generated/wrapper.c @@ -2334,6 +2334,7 @@ typedef void (*vFpiipCpp_t)(void*, int32_t, int32_t, void*, uint8_t, void*, void typedef void (*vFpiipppp_t)(void*, int32_t, int32_t, void*, void*, void*, void*); typedef void (*vFpipipii_t)(void*, int32_t, void*, int32_t, void*, int32_t, int32_t); typedef void (*vFpippppu_t)(void*, int32_t, void*, void*, void*, void*, uint32_t); +typedef void (*vFpuiippp_t)(void*, uint32_t, int32_t, int32_t, void*, void*, void*); typedef void (*vFpuuuuuu_t)(void*, uint32_t, uint32_t, uint32_t, uint32_t, uint32_t, uint32_t); typedef void (*vFpuuUUuu_t)(void*, uint32_t, uint32_t, uint64_t, uint64_t, uint32_t, uint32_t); typedef void (*vFpuupupu_t)(void*, uint32_t, uint32_t, void*, uint32_t, void*, uint32_t); @@ -2343,6 +2344,7 @@ typedef void (*vFpupppui_t)(void*, uint32_t, void*, void*, void*, uint32_t, int3 typedef void (*vFpUiUiup_t)(void*, uint64_t, int32_t, uint64_t, int32_t, uint32_t, void*); typedef void (*vFpUuuUip_t)(void*, uint64_t, uint32_t, uint32_t, uint64_t, int32_t, void*); typedef void (*vFpUUUUuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint32_t, uint32_t); +typedef void (*vFpfffppp_t)(void*, float, float, float, void*, void*, void*); typedef void (*vFpddiidd_t)(void*, double, double, int32_t, int32_t, double, double); typedef void (*vFpdddddd_t)(void*, double, double, double, double, double, double); typedef void (*vFpLiLiLp_t)(void*, uintptr_t, int32_t, uintptr_t, int32_t, uintptr_t, void*); @@ -5472,6 +5474,7 @@ void vFpiipCpp(x64emu_t *emu, uintptr_t fcn) { vFpiipCpp_t fn = (vFpiipCpp_t)fcn void vFpiipppp(x64emu_t *emu, uintptr_t fcn) { vFpiipppp_t fn = (vFpiipppp_t)fcn; fn((void*)R_RDI, (int32_t)R_RSI, (int32_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); } void vFpipipii(x64emu_t *emu, uintptr_t fcn) { vFpipipii_t fn = (vFpipipii_t)fcn; fn((void*)R_RDI, (int32_t)R_RSI, (void*)R_RDX, (int32_t)R_RCX, (void*)R_R8, (int32_t)R_R9, *(int32_t*)(R_RSP + 8)); } void vFpippppu(x64emu_t *emu, uintptr_t fcn) { vFpippppu_t fn = (vFpippppu_t)fcn; fn((void*)R_RDI, (int32_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(uint32_t*)(R_RSP + 8)); } +void vFpuiippp(x64emu_t *emu, uintptr_t fcn) { vFpuiippp_t fn = (vFpuiippp_t)fcn; fn((void*)R_RDI, (uint32_t)R_RSI, (int32_t)R_RDX, (int32_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); } void vFpuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFpuuuuuu_t fn = (vFpuuuuuu_t)fcn; fn((void*)R_RDI, (uint32_t)R_RSI, (uint32_t)R_RDX, (uint32_t)R_RCX, (uint32_t)R_R8, (uint32_t)R_R9, *(uint32_t*)(R_RSP + 8)); } void vFpuuUUuu(x64emu_t *emu, uintptr_t fcn) { vFpuuUUuu_t fn = (vFpuuUUuu_t)fcn; fn((void*)R_RDI, (uint32_t)R_RSI, (uint32_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint32_t)R_R9, *(uint32_t*)(R_RSP + 8)); } void vFpuupupu(x64emu_t *emu, uintptr_t fcn) { vFpuupupu_t fn = (vFpuupupu_t)fcn; fn((void*)R_RDI, (uint32_t)R_RSI, (uint32_t)R_RDX, (void*)R_RCX, (uint32_t)R_R8, (void*)R_R9, *(uint32_t*)(R_RSP + 8)); } @@ -5481,6 +5484,7 @@ void vFpupppui(x64emu_t *emu, uintptr_t fcn) { vFpupppui_t fn = (vFpupppui_t)fcn void vFpUiUiup(x64emu_t *emu, uintptr_t fcn) { vFpUiUiup_t fn = (vFpUiUiup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int32_t)R_RDX, (uint64_t)R_RCX, (int32_t)R_R8, (uint32_t)R_R9, *(void**)(R_RSP + 8)); } void vFpUuuUip(x64emu_t *emu, uintptr_t fcn) { vFpUuuUip_t fn = (vFpUuuUip_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint32_t)R_RDX, (uint32_t)R_RCX, (uint64_t)R_R8, (int32_t)R_R9, *(void**)(R_RSP + 8)); } void vFpUUUUuu(x64emu_t *emu, uintptr_t fcn) { vFpUUUUuu_t fn = (vFpUUUUuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint32_t)R_R9, *(uint32_t*)(R_RSP + 8)); } +void vFpfffppp(x64emu_t *emu, uintptr_t fcn) { vFpfffppp_t fn = (vFpfffppp_t)fcn; fn((void*)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); } void vFpddiidd(x64emu_t *emu, uintptr_t fcn) { vFpddiidd_t fn = (vFpddiidd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int32_t)R_RSI, (int32_t)R_RDX, emu->xmm[2].d[0], emu->xmm[3].d[0]); } void vFpdddddd(x64emu_t *emu, uintptr_t fcn) { vFpdddddd_t fn = (vFpdddddd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0]); } void vFpLiLiLp(x64emu_t *emu, uintptr_t fcn) { vFpLiLiLp_t fn = (vFpLiLiLp_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (int32_t)R_RDX, (uintptr_t)R_RCX, (int32_t)R_R8, (uintptr_t)R_R9, *(void**)(R_RSP + 8)); } @@ -8136,6 +8140,7 @@ int isSimpleWrapper(wrapper_t fun) { if (fun == &vFuuddiip) return 3; if (fun == &vFuffffff) return 7; if (fun == &vFudddddd) return 7; + if (fun == &vFpfffppp) return 4; if (fun == &vFpddiidd) return 5; if (fun == &vFpdddddd) return 7; if (fun == &vFppddddu) return 5; diff --git a/src/wrapped/generated/wrapper.h b/src/wrapped/generated/wrapper.h index ad3bfff0..44575ecd 100644 --- a/src/wrapped/generated/wrapper.h +++ b/src/wrapped/generated/wrapper.h @@ -2334,6 +2334,7 @@ void vFpiipCpp(x64emu_t *emu, uintptr_t fnc); void vFpiipppp(x64emu_t *emu, uintptr_t fnc); void vFpipipii(x64emu_t *emu, uintptr_t fnc); void vFpippppu(x64emu_t *emu, uintptr_t fnc); +void vFpuiippp(x64emu_t *emu, uintptr_t fnc); void vFpuuuuuu(x64emu_t *emu, uintptr_t fnc); void vFpuuUUuu(x64emu_t *emu, uintptr_t fnc); void vFpuupupu(x64emu_t *emu, uintptr_t fnc); @@ -2343,6 +2344,7 @@ void vFpupppui(x64emu_t *emu, uintptr_t fnc); void vFpUiUiup(x64emu_t *emu, uintptr_t fnc); void vFpUuuUip(x64emu_t *emu, uintptr_t fnc); void vFpUUUUuu(x64emu_t *emu, uintptr_t fnc); +void vFpfffppp(x64emu_t *emu, uintptr_t fnc); void vFpddiidd(x64emu_t *emu, uintptr_t fnc); void vFpdddddd(x64emu_t *emu, uintptr_t fnc); void vFpLiLiLp(x64emu_t *emu, uintptr_t fnc); diff --git a/src/wrapped/wrappedlibltdl7.c b/src/wrapped/wrappedlibltdl7.c deleted file mode 100644 index 77220418..00000000 --- a/src/wrapped/wrappedlibltdl7.c +++ /dev/null @@ -1,21 +0,0 @@ -#define _GNU_SOURCE /* See feature_test_macros(7) */ -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <dlfcn.h> - -#include "wrappedlibs.h" - -#include "wrapper.h" -#include "bridge.h" -#include "librarian/library_private.h" -#include "x64emu.h" - -const char* libltdl7Name = "libltdl.so.7"; -#define LIBNAME libltdl7 - -//#include "generated/wrappedlibltdl7types.h" - -// Insert code here - -#include "wrappedlib_init.h" \ No newline at end of file diff --git a/src/wrapped/wrappedlibltdl7_private.h b/src/wrapped/wrappedlibltdl7_private.h deleted file mode 100644 index 1da29f7a..00000000 --- a/src/wrapped/wrappedlibltdl7_private.h +++ /dev/null @@ -1,42 +0,0 @@ -#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA)) -error Meh... -#endif - -GO(lt__slist_box, pFp) -GO(lt__slist_cons, pFpp) -GO(lt__slist_concat, pFpp) -GO(lt_dlloader_add, iFpp) -//GO(lt_dlloader_next -GO(lt_dlloader_get, pFp) -GO(lt_dlloader_remove, iFp) -GO(lt_dlloader_find, pFp) -GO(lt_dlinterface_register, iFpp) -//GO(lt_dlinterface_free, -GO(lt__slist_remove, pFpp) -GO(lt__slist_unbox, pFp) -GO(lt__slist_find, pFpp) -GO(lt__slist_delete, vFp) -GO(lt__slist_tail, pFp) -GO(lt__slist_nth, pFp) -//GO(lt__slist_length -GO(lt__slist_reverse, pFp) -//GO(lt__slist_foreach -//GO(lt__slist_sort -GO(lt_dladderror, vFp) -GO(lt_dlseterror, vFp) -GO(lt_dlinit, iFv) -GO(lt_dlexit, iFv) -GO(lt_dladvise_init, iFp) -GO(lt_dladvise_destroy, iFp) -GO(lt_dladvise_ext, iFp) -GO(lt_dladvise_resident, iFp) -GO(lt_dladvise_local, iFp) -GO(lt_dladvise_global, iFp) -GO(lt_dladvise_preload, iFp) -//GO(lt_dlopenadvise -GO(lt_dladdsearchdir, iFp) -GO(lt_dlinsertsearchdir, iFpp) -GO(lt_dlsetsearchpath, iFp) -GO(lt_dlgetsearchpath, pFv) -//GO(lt_dlopenext -GO(lt__get_last_error, pFv) \ No newline at end of file diff --git a/src/wrapped/wrappedlibtiff5_private.h b/src/wrapped/wrappedlibtiff5_private.h index 61b9cd95..e3e95ab4 100644 --- a/src/wrapped/wrappedlibtiff5_private.h +++ b/src/wrapped/wrappedlibtiff5_private.h @@ -2,42 +2,146 @@ #error Meh.... #endif -//GO(TIFFVGetFieldDefaulted, -// GO(TIFFVGetField, iFpWA) -GO(TIFFCleanup, vFp) -GO(TIFFFreeDirectory, vFp) -GO(TIFFFlush, iFp) +// GO(TIFFGetFieldDefaulted +// GO(TIFFSetField +// GO(TIFFReadEncodedStrip +// GO(TIFFTileSize +// GO(TIFFWarningExt +// GO(TIFFGetTagListCount +// GO(TIFFWriteCheck +// GO(TIFFReadRawTile +// GO(TIFFCurrentStrip +// GO(TIFFFieldTag +// GO(TIFFCurrentDirOffset +// GO(TIFFSetClientInfo +// GO(TIFFJPEGIsFullStripRequired +// GO(TIFFGetSeekProc +// GO(TIFFGetStrileOffset +// GO(TIFFReadTile +// GO(TIFFCurrentRow +// GO(TIFFSwabArrayOfDouble +// GO(TIFFFlushData1 +// GO(TIFFGetReadProc +// GO(TIFFInitPackBits +// GO(TIFFComputeStrip +// GO(TIFFInitZIP +// GO(TIFFErrorExt +GO(TIFFSwabLong8, vFp) +GO(TIFFSwabLong, vFp) +// GO(TIFFCreateDirectory +// GO(TIFFPredictorInit +// GO(TIFFPredictorCleanup +// GO(TIFFUnRegisterCODEC +// GO(TIFFFlushData +// GO(TIFFRGBAImageEnd +// GO(TIFFInitSGILog +// GO(TIFFGetTagListEntry +// GO(TIFFWriteEncodedStrip GO(TIFFClose, vFp) -GO(TIFFFindCODEC, pFW) +// GO(TIFFIsBigEndian +// GO(TIFFSwabDouble +// GO(TIFFReadRGBAStripExt +// GO(TIFFLastDirectory +// GO(TIFFInitCCITTRLE +// GO(TIFFSetWriteOffset +// GO(TIFFFieldName +// GO(TIFFFileName +// GO(TIFFScanlineSize +// GO(TIFFDataWidth +// GO(TIFFIsByteSwapped +// GO(TIFFReadBufferSetup +GO(TIFFCIELabToXYZ, vFpuiippp) +// GO(TIFFReadDirectory +// GO(TIFFFieldDataType +// GO(TIFFSetErrorHandlerExt GO(TIFFIsCODECConfigured, iFW) -GO(TIFFInitDumpMode, iFpi) -GO(TIFFInitLZW, iFpi) -//GO(TIFFInitPackBits -GO(TIFFInitThunderScan, iFpi) -GO(TIFFInitNeXT, iFpi) -GO(TIFFInitJPEG, iFpi) -//GO(TIFFInitOJPEG -GO(TIFFInitCCITTRLE, iFpi) -GO(TIFFInitCCITTRLEW, iFpi) -GO(TIFFInitCCITTFax3, iFpi) -//GO(TIFFInitCCITTFax4 -GO(TIFFInitJBIG, iFpi) -GO(TIFFInitZIP, iFpi) -//GO(TIFFInitPixarLog -//GO(TIFFInitSGILog -GO(TIFFInitLZMA, iFpi) -GO(TIFFInitZSTD, iFpi) -GO(TIFFInitWebP, iFpi) -// GO(TIFFCIELabToXYZ, vFpuiippp) -GO(TIFFXYZToRGB, iFpppp) -GO(TIFFCIELabToRGBInit, iFpp) -//GO(TIFFYCbCrtoRGB -//GO(TIFFYCbCrToRGBInit +// GO(TIFFFaxMainTable +// GO(TIFFReadEXIFDirectory +// GO(TIFFAccessTagMethods +// GO(TIFFGetMapFileProc +// GO(TIFFSetErrorHandler +// GO(TIFFCheckpointDirectory +// GO(TIFFSetClientdata +// GO(TIFFGetVersion +// GO(TIFFWriteRawStrip +// GO(TIFFInitCCITTFax3 +// GO(TIFFInitCCITTFax4 +// GO(TIFFWriteEncodedTile +// GO(TIFFFieldPassCount +// GO(TIFFReadRGBAImageOriented +// GO(TIFFRGBAImageBegin +// GO(TIFFTileRowSize64 +// GO(TIFFRasterScanlineSize +// GO(TIFFSetWarningHandlerExt +// GO(TIFFInitLZW +// GO(TIFFWriteTile +GO(TIFFYCbCrtoRGB, vFpuiippp) +// GO(TIFFSetMode +// GO(TIFFRasterScanlineSize64 +// GO(TIFFSwabArrayOfFloat +// GO(TIFFRGBAImageGet +// GO(TIFFVStripSize +// GO(TIFFDefaultTileSize +// GO(TIFFSetFileno +// GO(TIFFGetSizeProc +// GO(TIFFIsUpSampled +// GO(TIFFGetClientInfo +// GO(TIFFDefaultDirectory +// GO(TIFFGetBitRevTable +// GO(TIFFError +// GO(TIFFGetStrileByteCount +// GO(TIFFSetDirectory +// GO(TIFFGetStrileByteCountWithErr +// GO(TIFFFieldWithName +// GO(TIFFRGBAImageOK +GO(TIFFGetConfiguredCODECs, pFW) +// GO(TIFFTileRowSize +// GO(TIFFCreateEXIFDirectory +// GO(TIFFInitJBIG +GO(TIFFXYZToRGB, vFpfffppp) +// GO(TIFFFillTile +// GO(TIFFInitZSTD +// GO(TIFFWriteScanline +// GO(TIFFCreateCustomDirectory +// GO(TIFFVGetFieldDefaulted +// GO(TIFFSetTagExtender +// GO(TIFFStripSize64 +// GO(TIFFCurrentDirectory +// GO(TIFFReadRawStrip +// GO(TIFFNumberOfStrips +// GO(TIFFSetupStrips +// GO(TIFFIsMSB2LSB +// GO(TIFFSwabFloat +// GO(TIFFReadRGBAImage +GO(TIFFFreeDirectory, iFp) +GO(TIFFCleanup, vFp) +GO(TIFFFlush, iFp) GO(TIFFSetCompressionScheme, iFpi) -//GO(TIFFRegisterCODEC -//GO(TIFFUnRegisterCODEC -GO(TIFFGetConfiguredCODECs, pFv) -//GO(TIFFFindField -GO(TIFFSwabLong, vFp) -GO(TIFFSwabLong8, vFp) -GO(TIFFSwabShort, vFp) \ No newline at end of file +GO(TIFFSwabShort, vFp) +// GO(TIFFInitNeXT +// GO(TIFFInitDumpMode +// GO(TIFFSwabArrayOfLong8 +// GO(TIFFWriteCustomDirectory +// GO(TIFFReverseBits +// GO(TIFFInitWebP +// GO(TIFFCheckTile +// GO(TIFFVGetField +// GO(TIFFTileSize64 +// GO(TIFFReadRGBATileExt +// GO(TIFFVTileSize64 +// GO(TIFFVSetField +// GO(TIFFDefaultStripSize +// GO(TIFFInitJPEG +// GO(TIFFOpen +// GO(TIFFFaxWhiteCodes +// GO(TIFFUnsetField +// GO(TIFFVTileSize +// GO(TIFFRawStripSize +// GO(TIFFDeferStrileArrayWriting +// GO(TIFFStripSize +GO(TIFFCIELabToRGBInit, iFppp) +// GO(TIFFComputeTile +// GO(TIFFGetField +// GO(TIFFFaxWhiteTable +// GO(TIFFGetUnmapFileProc +// GO(TIFFFillStrip |