Skip to content

Commit

Permalink
Minor changes for compiling with GCC, Linux dependencies and other.
Browse files Browse the repository at this point in the history
Addition of static address verification in the P-code verification routine (to check whether direct access instructions remain in bounds).
  • Loading branch information
thiadmer.riemersma committed Dec 18, 2007
1 parent 584901e commit 5ba48f6
Show file tree
Hide file tree
Showing 17 changed files with 440 additions and 305 deletions.
15 changes: 6 additions & 9 deletions amx/CMakeLists.txt
Expand Up @@ -27,7 +27,7 @@ IF (UNIX)
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/../linux)
ENDIF (UNIX)
IF(WIN32)
ADD_DEFINITIONS(-DAMXEXPORT=__stdcall -DAMX_NATIVE_CALL=__stdcall -DSTDECL)
ADD_DEFINITIONS(-DPAWN_DLL -DSTDECL)
IF(NOT BORLAND)
LINK_LIBRARIES(winmm)
ENDIF(NOT BORLAND)
Expand Down Expand Up @@ -122,16 +122,13 @@ ENDIF(UNIX)

# amxProcess
SET(PROCESS_SRCS amxprocess.c amx.c)
IF(WIN32)
ADD_LIBRARY(amxProcess SHARED ${PROCESS_SRCS})
ELSE(WIN32)
IF(HAVE_FFI_H)
ADD_LIBRARY(amxProcess SHARED ${PROCESS_SRCS})
ELSE(HAVE_FFI_H)
ADD_LIBRARY(amxProcess SHARED ${PROCESS_SRCS})
IF(UNIX)
IF(NOT HAVE_FFI_H)
MESSAGE(SEND_ERROR "amxProcess requires libffi; see http://sources.redhat.com/libffi/")
MESSAGE(SEND_ERROR "libffi is not available (foreign function interface)")
ENDIF(HAVE_FFI_H)
ENDIF(WIN32)
ENDIF(NOT HAVE_FFI_H)
ENDIF(UNIX)
SET_TARGET_PROPERTIES(amxProcess PROPERTIES PREFIX "")
IF(WIN32)
SET(PROCESS_SRCS ${PROCESS_SRCS} dllmain.c amxprocess.rc)
Expand Down

0 comments on commit 5ba48f6

Please sign in to comment.