Changing define to avoid possible name conflicts

This commit is contained in:
SergioMartin86 2024-02-17 07:00:18 +00:00
parent b5af601aad
commit 32a8ea42f8
3 changed files with 5 additions and 5 deletions

View File

@ -4,9 +4,6 @@ project('quickerNES','c','cpp',
default_options : ['cpp_std=c++20', 'default_library=shared', 'buildtype=release']
)
# Getting page alignment option
pageSize = get_option('CPUFunctionAlignment')
# Loading dependencies
subdir('source')

View File

@ -223,7 +223,7 @@ uint8_t clock_table [256] = {
};
__attribute__((optimize("align-functions=" _PAGE_SIZE)))
__attribute__((optimize("align-functions=" _QUICKERNES_CPU_FUNCTION_ALIGNMENT)))
Cpu::result_t Cpu::run ( nes_time_t end )
{
set_end_time_( end );

View File

@ -28,10 +28,13 @@ quickerNESSrc = quickerNESAPUSrc + quickerNESPPUSrc + [
'core/cpu.cpp'
]
# Getting page alignment option
CPUFunctionAlignment = get_option('CPUFunctionAlignment')
# quickerNES Core Configuration
quickerNESDependency = declare_dependency(
compile_args : [ '-D_PAGE_SIZE="' + pageSize.to_string() + '"'],
compile_args : [ '-D_QUICKERNES_CPU_FUNCTION_ALIGNMENT="' + CPUFunctionAlignment.to_string() + '"'],
include_directories : include_directories(['.']),
sources : [ quickerNESSrc ]
)