RE: Stand-alone applications.

From: Fine, Valeri <fine_at_bnl.gov>
Date: Mon, 27 Jul 2009 18:17:17 -0400

> Dear all,
> I see this is an unusual question, but I have not find in the web
> the way to obtain a stand-alone application from the compiling
process.
>
> Assuming to have Scientific Linux and the following code:
>
> #include <iostream>
>
> int main ()
> {
> cout << "Hello world" << endl;
> return 0;
> }
>
> Is there any way to have it compiled with ACLiC (or in another way
> such that I can use root libraries) and to get an executable
> helloworld.out file which I can run just with
> ./helloworld.out ?
>

 Just do

  g++ `root-config --cflags --libs` helloword.cxx -o helloword.out

Hope this helps, Valeri

> I would need to run a program using root libraries on a PC where root
> cannot be installed, this is the why of my enquiry.
>
> Thanks a lot!
>
> Lucio Anderlini.
Received on Tue Jul 28 2009 - 00:26:32 CEST

This archive was generated by hypermail 2.2.0 : Tue Jul 28 2009 - 05:50:06 CEST