Message: Static build with VS2010 and Geant4.9.5 Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Static build with VS2010 and Geant4.9.5 

Forum: Installation and Configuration
Date: 13 Feb, 2012
From: Eric Abel <Eric Abel>

--_000_BB7F2EB79CF38C4489213098620820B51EF24CB6paex2010mbx03vm_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Hello All,

I am trying to statically build Geant4.9.5 for Visual Studio 2010.  The dyn=
amic build (per the user documentation) works.  However, I would like an ap=
plication that is stand-alone, i.e. no dll's.  My first attempt was to buil=
d both static and shared libraries, which caused linker errors (as Cmake wa=
rned).  I then tried to build the static with no shared, which kind of work=
s, but the linker gives an error "cannot open g4expat.lib".  There is no g4=
expat.lib, because g4expat-static.lib was built.  I tried renaming g4expat-=
static.lib to g4expat.lib and it threw the error "cannot find g4expat-stati=
c.lib" (different from "cannot open" error above).  So somehow, the linker =
is looking for both.  I combed the forum and found similar issues, but noth=
ing close enough to help me debug this.  Has anyone else encountered this i=
ssue?  Any suggestions?

Thank you in advance,

Eric

--_000_BB7F2EB79CF38C4489213098620820B51EF24CB6paex2010mbx03vm_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" xmlns:o=3D"urn:schemas-micr=
osoft-com:office:office" xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:m=3D"http://schemas.microsoft.com/office/2004/12/omml" xmlns=3D"http:=
//www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Dus-ascii"=
>
<meta name=3D"Generator" content=3D"Microsoft Word 12 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
 {font-family:"Cambria Math";
 panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
 {font-family:Calibri;
 panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
 {margin:0in;
 margin-bottom:.0001pt;
 font-size:11.0pt;
 font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
 {mso-style-priority:99;
 color:blue;
 text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
 {mso-style-priority:99;
 color:purple;
 text-decoration:underline;}
span.EmailStyle17
 {mso-style-type:personal-compose;
 font-family:"Calibri","sans-serif";
 color:windowtext;}
.MsoChpDefault
 {mso-style-type:export-only;}
@page WordSection1
 {size:8.5in 11.0in;
 margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
 {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang=3D"EN-US" link=3D"blue" vlink=3D"purple">
<div class=3D"WordSection1">
<p class=3D"MsoNormal">Hello All,<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">I am trying to statically build Geant4.9.5 for Visua=
l Studio 2010.&nbsp; The dynamic build (per the user documentation) works.&=
nbsp; However, I would like an application that is stand-alone, i.e. no dll=
&#8217;s.&nbsp; My first attempt was to build both static
 and shared libraries, which caused linker errors (as Cmake warned).&nbsp; =
I then tried to build the static with no shared, which kind of works, but t=
he linker gives an error &#8220;cannot open g4expat.lib&#8221;.&nbsp; There=
 is no g4expat.lib, because g4expat-static.lib was built.&nbsp;
 I tried renaming g4expat-static.lib to g4expat.lib and it threw the error =
&#8220;cannot find g4expat-static.lib&#8221; (different from &#8220;cannot =
open&#8221; error above).&nbsp; So somehow, the linker is looking for both.=
&nbsp; I combed the forum and found similar issues, but nothing close
 enough to help me debug this.&nbsp; Has anyone else encountered this issue=
?&nbsp; Any suggestions?<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">Thank you in advance,<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">Eric<o:p></o:p></p>
</div>
</body>
</html>

--_000_BB7F2EB79CF38C4489213098620820B51EF24CB6paex2010mbx03vm_--

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Question: Re: Static build with VS2010 and Geant4.9.5   (Ben Morgan - 14 Feb, 2012)
2 None: Re: Static build with VS2010 and Geant4.9.5   (Eric Abel - 16 Mar, 2012)
1 Note: Re: Static build with VS2010 and Geant4.9.5   (Ben Morgan - 19 Mar, 2012)
(_ Agree: Re: Static build with VS2010 and Geant4.9.5   (Eric Abel - 04 Apr, 2012)
(_ None: Re: Static build with VS2010 and Geant4.9.5   (Ben Morgan - 16 Apr, 2012)
(_ None: Re: Static build with VS2010 and Geant4.9.5   (Eric Abel - 16 Apr, 2012)
 Add Message Add Message
to: "Static build with VS2010 and Geant4.9.5"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]