On 2011-10-24 19:13+0100 Steve Schwartz wrote: > For those who recognise this, here's my problem: > > LINK : fatal error LNK1146: no argument specified with option > '/machine:' > > ------------- > > Sorry for a slightly random posting, but I've recommended plplot to a > couple of students doing a project under me, and they've hit a snag > trying to install plplot in Visual Studio. I've had a go myself, > although since I'm not a Windows person this is kind of the blind > leading the blind. My post-doc was successful some time ago, and gave us > some instructions which nearly worked, but perhaps things have changed > ever so slightly. > > Environment: > plplot-5.9.9 fresh download > Visual Studio C++ 2010 running on Windows XP > cmake 2.8.6 fresh install (with exe's in every user's path) > > It is critical, of course, to build from a dos command-line window from > within Visual Studio, so it can set up the necessary environment. > > Firstly, the 5.9.9 tarball is missing README, so an initial build > failed. I faked that, as it was clearly not important. Here is my cmake > invocation (from my post-doc): > > C:\Program Files\plplot\plplot_build>cmake "C:\Program Files\plplot > \plplot-5.9.9" -G "NMake Makefiles" -DBUILD_TEST=ON > -DENABLE_f77:BOOL=OFF -DENABLE_java:BOOL=OFF -DENABLE_python:BOOL=OFF > -DCMAKE_INSTALL_PATH="C:\Program Files\plplot\plplot_install" > > This runs ok, but warns > > Manually-specified variables were not used by the project: > > CMAKE_INSTALL_PATH > > which looks benign. > > nmake runs and gets as far as the first compile/link I guess, and then > fails: > > C:\Program Files\plplot\plplot_build>nmake > > Microsoft (R) Program Maintenance Utility Version 10.00.30319.01 > Copyright (C) Microsoft Corporation. All rights reserved. > > Scanning dependencies of target csirocsa > [ 1%] Building C object lib/csa/CMakeFiles/csirocsa.dir/csa.c.obj > csa.c > Linking C shared library ..\..\dll\csirocsa.dll > LINK : fatal error LNK1146: no argument specified with option > '/machine:' > LINK failed. with 1146 > NMAKE : fatal error U1077: '"C:\Program Files\CMake 2.8\bin > \cmake.exe"' : return > code '0xffffffff' > Stop. > > Any pointers about how to fix this? I haven't tried to hunt down the bit > of the makefiles cmake generates to find the /machine linker option, and > since I don't speak cmake very well either would probably be none the > wiser.
Hi Steve: My Windows experience is limited to MinGW/MSYS/Wine with the MSYS version of make so I will avoid trying to say much about nmake below except at the very end. 1. I am concerned about the order of the components of the above cmake command. The man page for cmake says cmake [options] <path-to-source> so I would stick to that documented order rather than putting <path-to-source> first. I think this incorrect order is the reason why the -DCMAKE_INSTALL_PATH was ignored. If your setting of -DCMAKE_INSTALL_PATH or any other CMake variable continues to be ignored, I think that is a major issue. 2. PLplot and CMake both have issues with whitespace in path names. You have whitespace in the pathname to cmake-2.8.6, the PLplot source tree, and also your install prefix. I would change all of those locations to avoid this issue. 3. The absolute path (with no whitespace) of the dll subdirectory of your top-level build-tree directory should be on your PATH. 4. I _think_ the option VERBOSE=1 should work with nmake, e.g., "nmake VERBOSE=1 ..." to give you the exact command that is run, but if not, try the cmake option -DCMAKE_VERBOSE_MAKEFILE=ON. Good luck, and let us know how it goes. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ ------------------------------------------------------------------------------ The demand for IT networking professionals continues to grow, and the demand for specialized networking skills is growing even more rapidly. Take a complimentary Learning@Cisco Self-Assessment and learn about Cisco certifications, training, and career opportunities. http://p.sf.net/sfu/cisco-dev2dev _______________________________________________ Plplot-devel mailing list Plplot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/plplot-devel