473,725 Members | 2,264 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Best Way to Compile Large Project

I have a large project on a Linux box that may eventually have several
hundred 'C' source files, which need to be compiled and linked into several
executables.

Not all of the executables will use all of the files (i.e. there would be no
linker references to some symbols).

The project will naturally be broken down into several or more
subdirectories.

Questions:

a)What is the best way in general to build? Compile all the .c files into
corresponding .o files, and then link the .o files explicitly?

b)Any thoughts on doing this with "make"?

c)Any thoughts on the limitations of the linker?

Thanks.

Dec 28 '06
30 3863
On Fri, 29 Dec 2006 13:19:57 -0500
"David T. Ashley" <dt*@e3ft.comwr ote:
"toby" <to**@telegraph ics.com.auwrote in message
news:11******** *************@h 40g2000cwb.goog legroups.com...

What also tends to be revealed by make *questions* is that the
questioner has not read 'info make'[1], which should a first step to
any serious use of it.

I'm very familiar with make. Just that I wanted to know:

a)Are there any limitations of make that will make it unsuitable for
a very large project?
You are not familiar with make :)
b)Are there any better alternatives?
For certain values of better. Make is pretty good at what it does, but
it rubs many people the wrong way. As a result, many people have
developed alternatives. They are sometimes better. Mostly they are
worse. If you have a pet gripe with make, then _you_ should research
alternatives that don't have that particular issue.

--
Stefaan A Eeckels
--
Microsoft treats IT managers the way Proctor & Gamble treats
nine-year-old prospective consumers: lots of noise, bright colors, and
jumping around. Other software vendors just wish they could be so
successful. -- Cameron Laird in comp.lang.tcl
Dec 30 '06 #21
Stefaan A Eeckels wrote:
>
You are not familiar with make :)
make is that dog of a program dating back to at least the 1980's where
you specify targets, actions, and dependencies, right?

And there are some extra goodies thrown in so that modifying a makefile
is easier (i.e. configuration items in one place) and so that commands
like "make check", "make clean" etc. are possible?

Did I miss anything?

What makes you think I'm not familiar with make?

P.S.--I really didn't need to make this post. I'm just testing Mozilla
as a newsgroup reader. Microsoft Outlook Express seems to have some
annoying bugs. So, if anyone has recommendations ...
------------------------------------------------------------
David T. Ashley (dt*@e3ft.com)
http://www.e3ft.com (Consulting Home Page)
http://www.dtashley.com (Personal Home Page)
http://gpl.e3ft.com (GPL Publications and Projects)
Dec 30 '06 #22
"David T. Ashley" <dt*@e3ft.comwr ites:
Stefaan A Eeckels wrote:
>>
You are not familiar with make :)

make is that dog of a program dating back to at least the 1980's where
you specify targets, actions, and dependencies, right?

And there are some extra goodies thrown in so that modifying a
makefile is easier (i.e. configuration items in one place) and so that
commands like "make check", "make clean" etc. are possible?

Did I miss anything?

What makes you think I'm not familiar with make?
Well, some familiarity with make would let you know that make is used
for most software projects, including the bigest open source ones. If
make is good enough for a ~24000-file Linux project or a ~42000-file
Mozilla project, what makes you think that it won't be good enough for
your 100-file software project?
--
__Pascal Bourguignon__ http://www.informatimago.com/

"Specificat ions are for the weak and timid!"
Dec 30 '06 #23
On Fri, 29 Dec 2006 13:19:57 -0500, in comp.lang.c , "David T. Ashley"
<dt*@e3ft.comwr ote:
>I'm very familiar with make. Just that I wanted to know:

a)Are there any limitations of make that will make it unsuitable for a very
large project?
"make" isn't part of C, so in the context of CLC, this question is
essentially offtopic. However IME for large projects (say with a few
tens of libraries with interdependenci es) you need something more
sophisticated.
>b)Are there any better alternatives?
yes. A general programming group can probably advise.
--
Mark McIntyre

"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it."
--Brian Kernighan
Dec 30 '06 #24
Mark McIntyre <ma**********@s pamcop.netwrite s:
On Fri, 29 Dec 2006 13:19:57 -0500, in comp.lang.c , "David T. Ashley"
<dt*@e3ft.comwr ote:
>>I'm very familiar with make. Just that I wanted to know:

a)Are there any limitations of make that will make it unsuitable for a very
large project?

"make" isn't part of C, so in the context of CLC, this question is
essentially offtopic. However IME for large projects (say with a few
tens of libraries with interdependenci es) you need something more
sophisticated.
Yes -- but some of those more sophisticated solutions work on top of
"make". For example, there are systems that automatically generate a
Makefile from some higher-level description.
>>b)Are there any better alternatives?

yes. A general programming group can probably advise.
Such as comp.unix.progr ammer or, if you're not restricting yourself to
Unix-like systems, comp.programmer .

I see that this is already cross-posted to comp.unix.progr ammer, so
I'll redirect followups there.

--
Keith Thompson (The_Other_Keit h) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
Dec 30 '06 #25
"Default User" <de***********@ yahoo.comwrote:
Richard Bos wrote:
Logan Shaw <ls**********@a ustin.rr.comwro te:
ju****@spamedit .com wrote:
Jussi Jumppanen
Author: Spam for Windows
http:\\www.spamedit.com
^^
I'm sure you meant to give a legal URI there...
I'm sure it just wanted to spam. (And apparently his product "is Y2K",
according to his FAQ. No, not Y2K-compatible; "Y2K". My confidence in
its excellence is not stellar.)

Mr. Jumppanen a well-known figure on many other programming and
compiler newsgroups. I think you've probably done him a disservice my
labeling him a spammer.
He may post the most worthwhile posts elsewhere, and in those groups he
will not be a spammer but a well-received contributor; but in
comp.lang.c, I've never seen him post anything else except
advertisements for his editor, as he's done twice recently.

Richard
Jan 3 '07 #26
Richard Bos wrote:
"Default User" <de***********@ yahoo.comwrote:
Mr. Jumppanen a well-known figure on many other programming and
compiler newsgroups. I think you've probably done him a disservice
my labeling him a spammer.

He may post the most worthwhile posts elsewhere, and in those groups
he will not be a spammer but a well-received contributor; but in
comp.lang.c, I've never seen him post anything else except
advertisements for his editor, as he's done twice recently.
Did you fail to notice that this thread is cross-posted to
comp.unix.progr ammer?


Brian
Jan 3 '07 #27
On 3 Jan 2007 22:48:23 GMT, "Default User" <de***********@ yahoo.com>
wrote:
>Richard Bos wrote:
>"Default User" <de***********@ yahoo.comwrote:
Mr. Jumppanen a well-known figure on many other programming and
compiler newsgroups. I think you've probably done him a disservice
my labeling him a spammer.

He may post the most worthwhile posts elsewhere, and in those groups
he will not be a spammer but a well-received contributor; but in
comp.lang.c, I've never seen him post anything else except
advertisemen ts for his editor, as he's done twice recently.

Did you fail to notice that this thread is cross-posted to
comp.unix.prog rammer?
Do you mean that it's OK to spam c.l.c. as long as you also spam
c.u.p.?

--
Al Balmer
Sun City, AZ
Jan 3 '07 #28
Al Balmer wrote:
On 3 Jan 2007 22:48:23 GMT, "Default User" <de***********@ yahoo.com>
wrote:
Richard Bos wrote:
"Default User" <de***********@ yahoo.comwrote:
Mr. Jumppanen a well-known figure on many other programming and
compiler newsgroups. I think you've probably done him a
disservice my labeling him a spammer.
>
He may post the most worthwhile posts elsewhere, and in those
groups >he will not be a spammer but a well-received contributor;
but in >comp.lang.c, I've never seen him post anything else except
advertisements for his editor, as he's done twice recently.
Did you fail to notice that this thread is cross-posted to
comp.unix.progr ammer?
Do you mean that it's OK to spam c.l.c. as long as you also spam
c.u.p.?

Richard was talking about what Jussi posted to clc. The point is that
likely he posted it to cup. I don't know if it's on-topic or not there,
I don't presume to speak for another group.

Personally, I don't believe he was guilty of spamming here either. He
answered the question with a reference to a forum thread, which is in
my opinion valid. The so-called "spam" consists of an improperly
demarcated signature. In no way did it seem to me like that was posted
as the answer to the question. Yes, Jussi needs to correct that and get
a proper delimiter for his signature, but no he didn't spam either
group.

I think Richard was way off-base. I think you're horning in without
really reviewing the situation. Anyone else I can slag while I'm at it?
Navia! It's all his fault, I'm sure.

Brian
Jan 4 '07 #29
Default User wrote:
Al Balmer wrote:
>"Default User" <de***********@ yahoo.comwrote:
>>Richard Bos wrote:
"Default User" <de***********@ yahoo.comwrote:

Mr. Jumppanen a well-known figure on many other programming
and compiler newsgroups. I think you've probably done him a
disservice my labeling him a spammer.
Your newsreader is seriously fouling the quoted material.

--
Chuck F (cbfalconer at maineline dot net)
Available for consulting/temporary embedded and systems.
<http://cbfalconer.home .att.net>
Jan 4 '07 #30

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
1716
by: Johan Nilsson | last post by:
I've seen many alternatives when it comes to referring to types defined in parent/sibling/other namespaces. Consider the following hypothetical namespace layout: namespace company { namespace lib { class SomeClass {};
6
2369
by: Peter Hickman | last post by:
I have a program that requires x strings all of y length. x will be in the range of 100-10000 whereas the strings will all be < 200 each. This does not need to be grown once it has been created. Should I allocate x strings of y length or should I allocate a single string x * y long? Which would be more efficient and / or portable? Thank you.
4
1452
by: Chris | last post by:
Where I work, we basically have 1 large ASP.NET application that we work on. This is compiled into one big DLL. I think it would be a good idea to somehow break up the project, so that if I am in the middle of development on some sub project, I don't have to push up that code to fix a bug in another part of the application.
10
3471
by: jojobar | last post by:
Hello, I am trying to use vs.net 2005 to migrate a project originally in vs.net 2003. I started with creation of a "web site", and then created folders for each component of the site. I read somewhere that each folder under the "web site" is compiled in separate assembly. I however, did not find that the "web site" creation in vs.net 2005 created any AssemblyInfo.cs file.
6
1293
by: Kevin Atherton | last post by:
Hello. I work for a large web company, and we are in the process of converting our old .asp pages to .aspx with VB code-behind. The solution includes 8 projects, all of which are very interwoven. The problem is that when I first open the IDE and load my solution, if I try to build or build all, it gets partway through the compile and then IDE simply goes away. There is no error, no fanfare, no warning, no indication that there is a...
27
1929
by: Rene | last post by:
I keep getting the following error every time I compile the solution under VS 2005: ---------------- Error 5 Unable to copy file "obj\Debug\xyz.dll" to "bin\Debug\xyz.dll". The process cannot access the file 'bin\Debug\xyz.dll' because it is being used by another process. ----------------
55
12816
by: Steve | last post by:
I have to develop several large and complex C++ hardware test programs that should work under DOS, most likely with 32-bit DOS extender. Development workstation OS would be Microsoft XP. Quite some time ago I worked in DOS, with Borland BC++ 4.1. I do not have it any more. Which compiler would you recommend me now? Which ones support serious DOS program development? Criterion should be number of available free library modules (graphic menu...
16
2811
by: Rex | last post by:
Hi All - I have a question that I think MIGHT be of interest to a number of us developers. I am somewhat new to VIsual Studio 2005 but not new to VB. I am looking for ideas about quick and efficient navigating within Visual Studio 2005. Let's say your project (or solution) has dozens of forms and hundreds or even thousands of routines. Two Questions: 1) BUILT-IN to Visual Studio 2005. What ideas do you have to quickly
4
2044
by: =?Utf-8?B?VzFsZDBuZTc0?= | last post by:
When one architects a new project one of the first steps in the decision is to decide on the layers. (In my opinion anyway) One architecture that I have used before is to go solid OO and create objects, which normally are very small and only deals with the stuff pertaining to that object, then break it down into Business Process, Process Controllers and Data Access Objects for each "Object", each of which is created in it's very own .Net...
0
8889
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9257
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9179
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9116
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6702
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4519
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4784
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2637
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2157
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.