WTF are RVA imports!? Any way to split the object files?

Everything else that doesn't fall into one of the other PB categories.
va!n
Addict
Addict
Posts: 1104
Joined: Wed Apr 20, 2005 12:48 pm

WTF are RVA imports!? Any way to split the object files?

Post by va!n »

1)
maybe someone can tell me wtf are RVA imports, because i wanted to use a special tool for my executeable and the help from this tool says:

"The import code does not support forwarded RVA imports, which means
that some functions, such as HeapAlloc, cannot be used."

Afaik, PureBasic automatical adds the HeapStuff to any executeable (even when using only a=2 as code) - Afaik the Heap related stuf is faster as the old memory commands.

2)
For my little project i am coding in PureBasic and using API only without the use of any command from any purebasic library! Now i need the object files (1x code / 1x data) of this project and with some tricks i managed to get the one complete object file! :cool:

However, is there any way to split this complete object file in seperate files, like one CODE object and one or more splitted DATA object files? :wink:

When taking a look to the one big object file (about 5k *grin*) i can see all my API calls but at the end there are some Purebasic (i think internally, because of PB_*) calls like following :roll: - i dont use any strings in my procect ^^

Code: Select all

_PB_StringBase
 PB_StringBase
_SYS_InitString@0
_PB_StringBasePosition
_PB_Instance
_PB_ExecutableType
_PB_MemoryBase
 PB_Instance
 PB_MemoryBase
_PB_EndFunctions
_PB_DEBUGGER_LineNumber
_PB_DEBUGGER_IncludedFiles
 PureBasicStart
_SYS_StaticStringStart
_PB_NullString
 PB_NullString
_SYS_StaticStringEnd 
Is there any way to create the object files without this informations and maybe wihout any Heap* related commads because of the problem i wrote at the beginning :?:

If any code guru can and may help me how to solve this problem, please get in contact with me! Many many tranks in advance!


@PureTeam:
I know those interally PB_ calls are related for PureBasic and this is ok! But as you have read, atm i am working on something very very special... If i get the stuff managed, i willl show you a great thing soon! ;)
va!n aka Thorsten

Intel i7-980X Extreme Edition, 12 GB DDR3, Radeon 5870 2GB, Windows7 x64,
traumatic
PureBasic Expert
PureBasic Expert
Posts: 1661
Joined: Sun Apr 27, 2003 4:41 pm
Location: Germany
Contact:

Re: WTF are RVA imports!? Any way to split the object files

Post by traumatic »

Are you absolutely sure you're not using any strings?

Code: Select all

a.l = 42
results in

Code: Select all

public _PB_Instance
public _PB_ExecutableType
public _PB_MemoryBase
public PB_Instance
public PB_MemoryBase
public _PB_EndFunctions
public _PB_DEBUGGER_LineNumber
public _PB_DEBUGGER_IncludedFiles
ie no _PB_string_whatever
Good programmers don't comment their code. It was hard to write, should be hard to read.
va!n
Addict
Addict
Posts: 1104
Joined: Wed Apr 20, 2005 12:48 pm

Post by va!n »

@traumatic:
ahh, you are right... using classname in CreateWindowEx is a string :lol: totally fogot to count this one! btw, do you know any way to solve topics problem? ^^ thx
va!n aka Thorsten

Intel i7-980X Extreme Edition, 12 GB DDR3, Radeon 5870 2GB, Windows7 x64,
traumatic
PureBasic Expert
PureBasic Expert
Posts: 1661
Joined: Sun Apr 27, 2003 4:41 pm
Location: Germany
Contact:

Post by traumatic »

Other than "roll you own" ? ;)
Good programmers don't comment their code. It was hard to write, should be hard to read.
Fred
Administrator
Administrator
Posts: 18351
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Post by Fred »

Just use a datasection with Data.b and the numeric for your classname, so you will get ride of all string stuffs (and use ? to get its address). Traumatic: brings back some memories ? :P
traumatic
PureBasic Expert
PureBasic Expert
Posts: 1661
Joined: Sun Apr 27, 2003 4:41 pm
Location: Germany
Contact:

Post by traumatic »

Fred :lol:
Good programmers don't comment their code. It was hard to write, should be hard to read.
va!n
Addict
Addict
Posts: 1104
Joined: Wed Apr 20, 2005 12:48 pm

Post by va!n »

thank you traumatic and fred!
i will try to experience a bit with it and maybe i get it work ;)


@Fred:
atm i am working one source containing code and a datasection... when creating an obj file (both, code and data) are in this one obj file... I think i will or have to split the datasection in a seperate file and create then an obj file. i will give it a try. anyway thanks for feedback
va!n aka Thorsten

Intel i7-980X Extreme Edition, 12 GB DDR3, Radeon 5870 2GB, Windows7 x64,
Post Reply