944,029 Members | Top Members by Rank

Ad:
  • C++ Discussion Thread
  • Unsolved
  • Views: 3995
  • C++ RSS
Jul 25th, 2005
0

C++ How do you create multifile project

Expand Post »
Exactly how do you create multi-file project and how do you compile it in C++ using Linux?
Similar Threads
Reputation Points: 14
Solved Threads: 0
Junior Poster in Training
djbsabkcb is offline Offline
92 posts
since Jun 2005
Jul 25th, 2005
0

Re: C++ How do you create multifile project

Quote originally posted by djbsabkcb ...
Exactly how do you create multi-file project and how do you compile it in C++ using Linux?
EZ way, by using some IDE like this.

Not so EZ way (but you will learn a lot), by using makefiles as described here and in other sources.
Reputation Points: 12
Solved Threads: 4
Junior Poster
Alvein is offline Offline
104 posts
since Jul 2005
Jul 25th, 2005
0

Re: C++ How do you create multifile project

A programmer that says an editor is the answer...geesh. The answer is with the include statment with something like this...
C++ Syntax (Toggle Plain Text)
  1. #include "fileToInclude.cpp"

For more info just look up the uses of the include in C/C++
Reputation Points: 10
Solved Threads: 0
Junior Poster in Training
Sauce is offline Offline
55 posts
since Jul 2005
Jul 25th, 2005
0

Re: C++ How do you create multifile project

[High Guard]Just follow the links before start typing nonsenses.

The 2nd one will TEACH you what the #include directive is intended for.[/High Guard]
Reputation Points: 12
Solved Threads: 4
Junior Poster
Alvein is offline Offline
104 posts
since Jul 2005
Jul 25th, 2005
0

Re: C++ How do you create multifile project

Hello,

You might also wish to look up and how to write makefiles. Unfortunately, I do not remember the exact sequence anymore, as I have moved on to system administration instead of programming, but makefiles can really make your life easier.

Christian
Team Colleague
Reputation Points: 121
Solved Threads: 57
Posting Virtuoso
kc0arf is offline Offline
1,629 posts
since Mar 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C++ Forum Timeline: Linker Error>Undefined reference error to xyz
Next Thread in C++ Forum Timeline: Problems casting a const char* to char*





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC