mirror of
https://github.com/MacosPorters/betterxen.git
synced 2026-11-26 19:30:43 +00:00
Rebases onto origin/main and retires the paused in-tree native-first workspace, legacy scripts, legacy CI, and native-only docs per ADR 0006 (preserving full history permanently at Git tag native-first-final). Addresses all maintainer review findings on PR #406: - Isolate CrossOver/Wine child process environment in bx-cli (env_clear + minimal allowlist + opt-in --inherit-env, with unit tests) - Replace naive objdump grep in scripts/build-shims.sh with strict PE Export Directory verification (exact names, ordinals, forwarders, 0 extra exports, 0 forbidden MinGW imports across all 16 DLLs / 102 exports) - Restore global * @MacosPorters/maintainers fallback in .github/CODEOWNERS alongside per-track rules - Restore independent-verification, claims/evidence-class, provenance-first, and contributor clean-room protections in AGENTS.md - Unify docs/roadmap.md, CONTRIBUTING.md, README.md, docs/README.md, THIRD_PARTY_NOTICES.md, and CHANGELOG.md around Milestones M0-M6 and ADR 0006 Signed-off-by: ates <ahmetrizaates@hotmail.com>
59 lines
1.6 KiB
C++
59 lines
1.6 KiB
C++
#include <windows.h>
|
|
#include <cstdint>
|
|
#include <cstdlib>
|
|
|
|
#include "bx_log.h"
|
|
|
|
/* Track E (M1-E2 / M5): AcpHal.dll SHAPE Audio Coprocessor HAL shim. */
|
|
|
|
extern "C" {
|
|
|
|
HRESULT WINAPI AcpHalCreate(void** out_hal) {
|
|
BX_STUB_LOG("AcpHal.dll", "AcpHalCreate");
|
|
if (out_hal) *out_hal = nullptr;
|
|
return E_NOTIMPL;
|
|
}
|
|
|
|
HRESULT WINAPI AcpHalAllocateShapeContexts(void* /*desc*/) {
|
|
BX_STUB_LOG("AcpHal.dll", "AcpHalAllocateShapeContexts");
|
|
return S_OK;
|
|
}
|
|
|
|
HRESULT WINAPI AcpHalReleaseShapeContexts(void) {
|
|
BX_STUB_LOG("AcpHal.dll", "AcpHalReleaseShapeContexts");
|
|
return S_OK;
|
|
}
|
|
|
|
HRESULT WINAPI ApuCreateHeap(uint32_t /*cached_size*/, uint32_t /*non_cached_size*/) {
|
|
BX_STUB_LOG("AcpHal.dll", "ApuCreateHeap");
|
|
return S_OK;
|
|
}
|
|
|
|
HRESULT WINAPI ApuAlloc(void** out_va, uint32_t* out_apu_addr, uint32_t size, uint32_t alignment) {
|
|
if (alignment < 64) alignment = 64;
|
|
void* p = _aligned_malloc(size ? size : 64, alignment);
|
|
if (out_va) *out_va = p;
|
|
if (out_apu_addr) *out_apu_addr = static_cast<uint32_t>(reinterpret_cast<uintptr_t>(p) & 0xFFFFFFFFu);
|
|
return p ? S_OK : E_OUTOFMEMORY;
|
|
}
|
|
|
|
HRESULT WINAPI ApuFree(void* va) {
|
|
if (va) _aligned_free(va);
|
|
return S_OK;
|
|
}
|
|
|
|
BOOL WINAPI ApuIsVirtualAddressValid(const void* va, uint32_t /*size*/) {
|
|
return va != nullptr;
|
|
}
|
|
|
|
void* WINAPI ApuMapApuAddress(uint32_t /*apu_addr*/) {
|
|
BX_STUB_LOG("AcpHal.dll", "ApuMapApuAddress");
|
|
return nullptr;
|
|
}
|
|
|
|
uint32_t WINAPI ApuMapVirtualAddress(const void* va) {
|
|
return static_cast<uint32_t>(reinterpret_cast<uintptr_t>(va) & 0xFFFFFFFFu);
|
|
}
|
|
|
|
} // extern "C"
|