View Single Post
Is this possible to pass #define from makefile?
Old
  (#1)
KWo
Developer of PODBot mm
 
KWo's Avatar
 
Status: Offline
Posts: 3,425
Join Date: Apr 2004
Default Is this possible to pass #define from makefile? - 20-05-2006

The problem is - everytime I'm trying to rescue the hostage - right after I press the "use" button - if there is some bot teamnate near me - it steals my hostage. It was too much annoying for me and I've decide to solve it. The code checks only if the hostage is "used" by some another CT bot. Lack of code to check if some human player is "using" such hostage. The only way to solve this is - to hack the private data. The people from AMX X showed me how to do this (thanks to VEN).
The problem is - data stored in private data are placed in some offsets. These offsets are system depanding - win32, linux and amd64 - they use different offsets for data stored in private data. The AMX X code uses some conditions as:
#if defined __linux__
(...)

#if defined __amd64__
(...)
but I didn't find there how do they pass these __linux__ and __amd64__ to compile code correctly for each system.
The question is - is there a way to pass these __linux__ and __amd64__ as some defined from makefile to have one the same code for all systems, but during compilation compile it correctly without necessity adding somewhere in the code:
#define __linux__
or
#define __amd64__

before compilation?
  
Reply With Quote