This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

LD_PRELOAD and C++ code


Hi all,
	I have a question about using LD_PRELOAD/dlsym() to wrap library functions.
Specifically, suppose I have some program compiled with gcc, and some shared
library of wrapper functions that use C++ and are compiled with g++. Assuming
the wrapper functions are declared extern "C", should I expect this to work?
It seems to work in some cases but not in others, so I'm curious if anyone has
a definitive answer.

Thanks,
Daniel

-- 
Daniel Myers
Comparative Genomics Laboratory
Center for Bioinformatics and Computational Biology
University of Maryland
Agri/LFSc Surge Building #296
College Park, MD 20742-3360
dmyers@umiacs.umd.edu
301.405.1262 work
http://serine.umiacs.umd.edu/personnel/myers_daniel/
-
"Think of your breed; for brutish ignorance / Your mettle was not made; you 
were made men / To follow after knowledge and excellence."
As if I also was hearing for the first time: like the blast of a trumpet, 
like the voice of God. For a moment I forget who I am and where I am.
--Primo Levi, Survival in Auschwitz 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]