public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Purnendu <purnendu@gmail.com>
To: abhivg <abhi.vg@gmail.com>
Cc: gcc-help@gcc.gnu.org
Subject: Re: Help with g++ (Newbie)
Date: Tue, 05 Dec 2006 08:06:00 -0000	[thread overview]
Message-ID: <4ca029ac0612050005x257defafn7ce22898a33d277a@mail.gmail.com> (raw)
In-Reply-To: <7693802.post@talk.nabble.com>

Hello,

w.r.t
>2) The errors I am getting are that it is not able to find the standard
>include files like "math.h", <vector> etc.
U need to compile with -lm option, i mean u need to link with the math library.

~
purnendu

On 12/5/06, abhivg <abhi.vg@gmail.com> wrote:
>
> Hi,
>
> I am a total newbie to g++. I have a c++ project developed using the vc++
> IDE which I need to build using g++. I am using Arm Toolchain on win xp for
> this. The c++ project was to develop a static library. So I think i need to
> generate an archive file using the 'ar' tool.
>
> I have done the following:
> 1) I have seperated all the header and source files from the vc project
> 2) I was able to compile all the cpp files using g++. There were no errors.
> 3) I generated the archive file using the 'ar' tool. The archive file also
> got generated.
> 4) I wrote a main.cpp file in which I will use the archive file
>
> Problems I am having:
> 1) I tried to build the main.cpp file but it gave errors in the header file
> included in main.cpp. This header file contains the functions that I have
> exposed to access the methods in the archive file. So I tried to compile(??)
> the some other header file and it gave me errors too.
> 2) The errors I am getting are that it is not able to find the standard
> include files like "math.h", <vector> etc.
>
> My doubts are:
> 1) The header file that I have exposed is included in the archive file
> generated. So how did the archive get compiled without any errors?
> 2) Why is gcc not able to access the standard include files when compiling
> header seperately but is able to access it when compiling cpp files?
> 2) What does it mean when I do the following: "g++ somefile.h".   Am I
> compiling a header file???
> 3) Also how do I generate an exe instead of an .out file?
>
> --
> View this message in context: http://www.nabble.com/Help-with-g%2B%2B-%28Newbie%29-tf2759497.html#a7693802
> Sent from the gcc - Help mailing list archive at Nabble.com.
>
>



-- 
with regards,
purnendu ghosh
-----------------------------------------------------------------------
If you can D.R.E.A.M it you can D.O it
-----------------------------------------------------------------------

  parent reply	other threads:[~2006-12-05  8:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-05  6:01 abhivg
2006-12-05  7:01 ` Ian Lance Taylor
2006-12-05 10:20   ` abhivg
2006-12-05 11:42     ` Peter Cech
2006-12-05 12:12       ` abhivg
2006-12-05  8:06 ` Purnendu [this message]
2006-12-05 12:14   ` abhivg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4ca029ac0612050005x257defafn7ce22898a33d277a@mail.gmail.com \
    --to=purnendu@gmail.com \
    --cc=abhi.vg@gmail.com \
    --cc=gcc-help@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).