Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com X-Authentication-Warning: cerebro.physics.uoc.gr: www set sender to kele AT physics DOT uoc DOT gr using -f Message-ID: <1100946450.419f1c1291eee@webmail.physics.uoc.gr> Date: Sat, 20 Nov 2004 12:27:30 +0200 From: kele AT physics DOT uoc DOT gr To: Mark Paulus Cc: "cygwin AT cygwin DOT com" Subject: Re: Clapack on Cygwin revisited References: <0I7G00C0I6YZM4 AT pmismtp01 DOT mcilink DOT com> In-Reply-To: <0I7G00C0I6YZM4@pmismtp01.mcilink.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-7 Content-Transfer-Encoding: 8bit User-Agent: Internet Messaging Program (IMP) 3.2.3 X-Originating-IP: 212.205.208.92 X-MailScanner: Found to be clean X-MailScanner-From: kele AT physics DOT uoc DOT gr X-IsSubscribed: yes Hi! Thanks a lot for your reply! Quoting Mark Paulus : > Sounds like you might need a -L option > > gcc -o testclapack testclapack.c -L lapack.a -cblaswr > -lblas.a tmglib.a -latlas -lg2c > If I understand well, this tells gcc to access a certain directory (with the -L command) where all the .a or .so's lib files can be found and then take under consideration only a certain amount of the files found in there by invoking the -l command. The command I tried was: gcc testclapack.c -L/usr/local/lib -L/usr/local/lib/lapack_CYGWIN.a -lcblaswr -lcblas -L/usr/local/lib/tmglib_CYGWIN.a -latlas -lg2c the /usr/local/lib is the directory with all the *.a files I could find (some, I put in there manually). I used the -L/usr/local/lib/lapack_CYGWIN.a instead of the -l/usr/local/lib/lapack_CYGWIN.a because the lapack_CYGWIN lib is not called liblapack_CYGWIN.a. Actually, I tried with the small l instead of the capital L but I was getting a message saying gcc cannot find -l/usr/local/lib/lapack_CYGWIN.a. Then I put -l's to whatever files were called lib*.a. Hence, I have in /usr/local/lib: libcblaswr.a libcblas.a libatlas.a and the tmglib_CYGWIN.a file which I had to put in the same way as the lapack_CYGWIN.a (also in /usr/local/lib). The -lg2c I don't really understand but it seems that gcc does not complain about it and I leave it... The result of that command was also an undefined reference to _dgesvd_ (the function in testclapack.c). I also tried to ask gcc to look at all the remaining lib*.a files in /usr/local/lib by adding (after the -lg2c) the: -lI77, -lf77blas options. Again the same error about the undefined reference. It seems to me that there is something quite wrong here unfortunately... If only I won't have to go through the same installation procedure again...:p If however that seems the best (or, even worse, the only) way forward could you perhaps let me know which instructions to follow? Thanks ever so much. regards, kele > You can stack multiple -L options, one per directory (no space after the -L), > the same as the -I options. > > also, > the -l is a special convention that ONLY works when the libraries > have a physical name of lib.. For instance > -lmath means that somewhere in a known location there is a file called > libmath.a or libmath.so. So, since the clapack libraries don't follow that > convention, you can't use the -l shortcut. You have to give it the full > name. > > > > > > > > > On Fri, 19 Nov 2004 23:29:46 +0200, kele AT physics DOT uoc DOT gr wrote: > > >Hi everyone. > > >My troubles with getting clapack to work on cygwin continue unfortunately. > In > >particular, I completed a first run of all the suggested actions in the > >readme.install file (found on the clapack website) with some error 139's > during > >that rather painful 16hour! long process. > > >I downloaded a test programme from the clapack website (if it could be > helpful I > >can attach it next time), saved it under the name of testclapack.c and tried > to > >compile it. It seemed as if finding out how to compile a programme using > >clapack was really tough. > > >Nonetheless, after several attepts I tried a couple > >of compilation commands with the likes of: gcc testclapack.c -llapack, > >gcc testclapack.c -llapack -lcblaswr -lcblas -latlas -lg2c (and any > permutation > >of the options (=5! I guess..:p)) and always I was getting a: > > >/cygdrive/c/DOCUME~1/kele/LOCALS~1/Temp/cccMzcp0.o(.text+0x152):testclapack.c: > >undefined reference to '_dgesvd_' collect2: ld returned 1 exit status. > > >The dgesvd_ is a function (the only clapack function) in the testclapack.c > >programme. > > >I have installed atlas (actually I did that before installing clapack) and > have > >put in the test programme the appropriate #include's (actually I #included > all > >the *.h files I could find on /clapack...) > > >Are there any ideas as to how I can compile a programme linking to a clapack > >routine? > > >I would be grateful of your help. > > >thanks, > > >kele > > > >---------------------------------------------------------------- > >This message was sent using IMP, the Internet Messaging Program. > > >-- > >Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > >Problem reports: http://cygwin.com/problems.html > >Documentation: http://cygwin.com/docs.html > >FAQ: http://cygwin.com/faq/ > > > > > > -- > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > Problem reports: http://cygwin.com/problems.html > Documentation: http://cygwin.com/docs.html > FAQ: http://cygwin.com/faq/ > ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/