Thread: Warnings during Compilation

  1. #1
    Registered User
    Join Date
    May 2007
    Posts
    1

    Warnings during Compilation

    Hello there,


    I'm trying to compile C source on Solaris and I'm encountering the following error(s). I'm pretty new to solaris, hence please bear with me if this is pretty trivial.

    This is the command I'm using :

    cc -mt -I/opt/IBM/mqsi/6.0/include/plugin -I/opt/mqm/inc -I/export/home/mquser/testall -c/export/home/mquser/testall/Thread.c
    -o /export/home/mquser/testall/Thread.o


    and

    following is the exception I can see:
    cc: Warning: option -/ passed to ld
    usage: cc [ options] files. Use 'cc -flags' for details

    How can I get this working?

    Thanks

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    Very strange.
    The -c option means compile only, so I dunno what it thinks it is doing trying to run the linker.

    http://docs.sun.com/source/819-3688/cc_ops.app.html
    You could try adding -# to the start of the command line to see what it is really up to, and post what you find if that doesn't help you figure out what is going on.

    Is there a space after the -c option?
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Oct 2006
    Posts
    250
    Tried putting a space between -c and the path that follows?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Advice on removing valid (but minor) compiler warnings
    By PaulBlay in forum C Programming
    Replies: 12
    Last Post: 04-20-2009, 12:16 PM
  2. Warnings when using vector of vector
    By Boksha in forum C++ Programming
    Replies: 5
    Last Post: 03-29-2008, 01:54 PM
  3. Replies: 9
    Last Post: 03-14-2008, 09:55 AM
  4. MS VC++ Crash on compilation
    By Magos in forum A Brief History of Cprogramming.com
    Replies: 10
    Last Post: 08-23-2003, 07:06 PM
  5. Warnings, warnings, warnings?
    By spentdome in forum C Programming
    Replies: 25
    Last Post: 05-27-2002, 06:49 PM