WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel]How to compile xen program in c++?

To: Xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel]How to compile xen program in c++?
From: 张建锋 <zjf.ha2010@xxxxxxxxx>
Date: Sat, 9 Oct 2010 11:26:53 +0800
Cc:
Delivery-date: Fri, 08 Oct 2010 20:27:56 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=vqW0NTMAbJUInUWQVzXbL0w7Q7dtALrpmNw0gyOzDKk=; b=eAWKrn53NmCN3DsKITpMSe/jO5QzhtLOgurxlYGLRyDfNeEBCu+a2vsdvIG8h7Rti5 I4p5Vw8RpxgwCcSehDUcevi7oOXF4+d9G7NxGPZyLVpt+RaekIFVofepaavSDu1pdwTF yFFFnVXLs10wAxKBJTRJUuRwG6QZB8cG/XoSw=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=dX9fTE5gpulJ91zGRRJe84uv9bewDZgO/SSqcJQ0ZG37GENAkFYBNRngOhiKxs/n8G AssKY/ae4Al2eOrq9dC9l0snw7ZHYQWwvTec4fUzsFrRw14pgtfc4dk5NH62EIKpWGpo SvdIaxGcOoMRyCpw6Gu7FnzHpGB34W2uz+ofQ=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
I want to type program with xen,but there some error.

xentest.cpp:

/************************************************
#include <xenctrl.h>
#include <stdio.h>

int main(int argc, char *argv[])
{
    int value=xc_interface_open();
   
    fprintf(stderr, "%d",value);

    return 0;
}
***********************************************/

I use cmd:
g++ xenctest.cpp -o xenctest0 -lxenctrl

Compiler output:
/tmp/ccR8dCnr.o: In function `main':
xenctest.cpp:(.text+0x10): undefined reference to `xc_interface_open()'
collect2: ld return 1

I google this ,but I've no idea.

How can I do?

Thanks very much.





_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel]How to compile xen program in c++?, 张建锋 <=