Dear ROOT- People,
I’m new to ROOT, and need to program some High-Speed-Camera-Interface hier at the COSY in Jülich.
Therefore I managed to Build Root, on my Win7 (x64 Platform) by compiling the ROOT Sourcecode 5.29 . So far everthing is running. Cint works just fine.
Now I want to compile the hsimple.cxx to try my first ROOT-compiled-Programm, and later manipulate it in the way I need it.
— I created a new Win32 Project, by the following steps:
– Openning the hsimple.cxx with VS2010, and choose, File/Adding to a new Projekt :
– I choose a standard Win32-Console Project.
– Now I replaced the empty _tmain by the hsimple.cxx Code;
– in The Prjekt Propertys I added “c:\ROOT\include” to the include-directory
– As well as: c:\ROOT\lib to the library-directory
– Than I Transfered the Projekt to an x64 Projekt, to be compatible with my Platform.
– But, whatever I tried, everytime I get this Linker errors…
OUTPUT__________________________________________________________________________________
1>------ Erstellen gestartet: Projekt: MyOwnHSimple, Konfiguration: Debug x64 ------
1>Der Buildvorgang wurde am 10.05.2011 14:48:40 gestartet.
1>InitializeBuildStatus:
1> “x64\Debug\MyOwnHSimple.unsuccessfulbuild” wird erstellt, da “AlwaysCreate” angegeben wurde.
1>ClCompile:
1> stdafx.cpp
1> MyOwnHSimple.cpp
1>c:\root\include\TString.h(450): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(462): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(471): warning C4996: ‘sprintf’: This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\stdio.h(371): Siehe Deklaration von ‘sprintf’
1>c:\root\include\TString.h(474): warning C4996: ‘sprintf’: This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\stdio.h(371): Siehe Deklaration von ‘sprintf’
1>c:\root\include\TString.h(489): warning C4996: ‘sprintf’: This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\stdio.h(371): Siehe Deklaration von ‘sprintf’
1>c:\root\include\TString.h(495): warning C4996: ‘sprintf’: This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\stdio.h(371): Siehe Deklaration von ‘sprintf’
1>c:\root\include\TString.h(498): warning C4996: ‘sprintf’: This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\stdio.h(371): Siehe Deklaration von ‘sprintf’
1>c:\root\include\TString.h(501): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(510): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(519): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(529): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(541): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(562): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(575): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(578): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(581): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>c:\root\include\TString.h(581): warning C4267: ‘Argument’: Konvertierung von ‘size_t’ nach ‘Ssiz_t’, Datenverlust möglich
1>MyOwnHSimple.cpp(59): warning C4244: ‘Initialisierung’: Konvertierung von ‘Double_t’ in ‘Float_t’, möglicher Datenverlust
1>MyOwnHSimple.cpp(63): warning C4244: ‘Argument’: Konvertierung von ‘Int_t’ in ‘Float_t’, möglicher Datenverlust
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: static void __cdecl TObject::operator delete(void *)” (??3TObject@@SAXPEAX@Z)” in Funktion ““int int __cdecl hsimple(void)'::
1’::dtor$1” (?dtor$1@?0??hsimple@@YAHXZ@4HA)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: virtual __cdecl TFile::~TFile(void)” (??1TFile@@UEAA@XZ)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: virtual void __cdecl TFile::Close(char const *)” (?Close@TFile@@UEAAXPEBD@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: virtual int __cdecl TFile::Write(char const *,int,int)” (?Write@TFile@@UEAAHPEBDHH@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2001: Nicht aufgelöstes externes Symbol “”__declspec(dllimport) class TRandom * gRandom" (_imp?gRandom@@3PEAVTRandom@@EA)".
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: __cdecl TNtuple::TNtuple(char const *,char const *,char const *,int)” (??0TNtuple@@QEAA@PEBD00H@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: __cdecl TProfile::TProfile(char const *,char const *,int,double,double,double,double,char const *)” (??0TProfile@@QEAA@PEBD0HNNNN0@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: __cdecl TH2F::TH2F(char const *,char const *,int,double,double,int,double,double)” (??0TH2F@@QEAA@PEBD0HNNHNN@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: __cdecl TH1F::TH1F(char const *,char const *,int,double,double)” (??0TH1F@@QEAA@PEBD0HNN@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: __cdecl TFile::TFile(char const *,char const *,char const *,int)” (??0TFile@@QEAA@PEBD00H@Z)” in Funktion ““int __cdecl hsimple(void)” (?hsimple@@YAHXZ)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: static void * __cdecl TStorage::ObjectAlloc(unsigned __int64)” (?ObjectAlloc@TStorage@@SAPEAX_K@Z)” in Funktion ““public: static void * __cdecl TObject::operator new(unsigned __int64)” (??2TObject@@SAPEAX_K@Z)”.
1>MyOwnHSimple.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ““public: __cdecl TVersionCheck::TVersionCheck(int)” (??0TVersionCheck@@QEAA@H@Z)” in Funktion ““void __cdecl `dynamic initializer for ‘gVersionCheck’’(void)” (??__EgVersionCheck@@YAXXZ)”.
1>x64\Debug\MyOwnHSimple.exe : fatal error LNK1120: 12 nicht aufgelöste externe Verweise.
1>
1>Fehler beim Erstellen
1>
1>Verstrichene Zeit 00:00:01.40
========== Erstellen: 0 erfolgreich, Fehler bei 1, 0 aktuell, 0 übersprungen ==========
Is there any detailed Tutorial for this Problem, or. “How to run hsimple.cxx in VStudio2010” - I couldn’t find it. Or How to start to compile Root Examples with Visual Studio 2010.
I’d be greatefull for your help and suggestions.
Nice Greetings from Jülich,
Johann Elis
PS: One can call me directly, or open a Remote Control Session, if the answer is more complicated.
Johann C. Elis
IKP-2
Forschungszentrum Jülich
52425 Jülich
+49 (246161) 3278