[ADMB Users] Visual Studio 2008 and 64 bit ADMB

Allan.Hicks at noaa.gov Allan.Hicks at noaa.gov
Thu Jun 3 08:59:35 PDT 2010


Hi Peter,

You are receiving that linker error because it is trying to link 64-bit
ADMB libraries with 32-bit libraries from Visual Studio.  You must
install 64 bit compilers and libraries with Visual Studio 2008, then
call the 64 compiler (cl.exe), which hasthe same name as the 32-bit
compiler but resides in a different folder.  I have set up ADMB 32bit
and ADMB 64bit on my machine so that I can create 32bit executables to
give to people without a 64bit Windows operating system. Try this setup:


Install ADMB 32bit as normal and test that it works (compiles
simple.tpl).  I installed this into C:\ADMB\Microsoft\VC9\32bit to keep
it separate from 64bit.

If you are using Visual Studio 2008 (the paid for version), install the
64bit options with the program. These are not installed by default.  If
you are using Visual Studio Express (the free version) you must install
Windows SDK. I installed Windows SDK 3.5 (a search on the internet for
Windows SDK 3.5 download should provide an installation). Install Visual
Studio Express first, then install SDK. When installing Windows SDK, you
can save a lot of download time and hard drive space by not installing
the documentation, but make sure all of the 64bit options are checked.

Install ADMB 64bit into a separate directory from 32bit. I used
C:\ADMB\Microsoft\VC9\64bit.  

Copy the attached batch files into the bin directory of the 64bit
installation: C:\ADMB\Microsoft\VC9\64bit\bin.  These batch files have
the hard coded directories C:\ADMB\Microsoft\VC9\64bit for ADMB 64bit
and C:\Program Files\Microsoft SDKs\Windows\v7.0 for SDK. Make sure
these directories exist.

Compile an admb code (such as simple.tpl) using the command 'admb64
simple'  



The batch files I wrote temporarily change the path and library path to
what 64bit compiling needs.  All of these directories are hard coded in,
so make sure that they exist on your machine.  You may have installed
ADMB, Visual Studio, or SDK in different directories. If so, you can
change the directories in the batch files.

Also, just to be sure, make sure that you are using a 64bit operating
system.

And note, the safe-mode compiling with Visual Studio is not currently
working, but the fix should be released soon.

I hope to streamline this installation some more and write a
installation guide soon. Feel free to contact me with any questions.

Good luck,
Allan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: adcomp64.bat
Type: application/octet-stream
Size: 3755 bytes
Desc: not available
URL: <http://lists.admb-project.org/pipermail/users/attachments/20100603/de253e4a/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: adlink64.bat
Type: application/octet-stream
Size: 3863 bytes
Desc: not available
URL: <http://lists.admb-project.org/pipermail/users/attachments/20100603/de253e4a/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: admb64.bat
Type: application/octet-stream
Size: 3196 bytes
Desc: not available
URL: <http://lists.admb-project.org/pipermail/users/attachments/20100603/de253e4a/attachment-0002.obj>
-------------- next part --------------
I have downloaded the ADMB code for Visual C++ 2008 and Visual Studio
2008, which saved to default directory Program Files (x86). I am
assuming the Visual Studio 2008 from the site you suggested supports 64
bit. The tpl2cpp and mycl work but the linkcl does not work.  See
atttached
Can you help me.  Peter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.admb-project.org/pipermail/users/attachments/20100603/de253e4a/attachment.html>
-------------- next part --------------
_______________________________________________
Users mailing list
Users at admb-project.org
http://lists.admb-project.org/mailman/listinfo/users


More information about the Users mailing list