473,386 Members | 1,738 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Makefile and source files in different directory

I want to compile source files which is in different directory than Makefile.
How can I do this?

GCC=gcc
DEFs=-DCUSTOMERCENTRAL_V11 -DUNIX -DLINUX -DOPENSSL -D_REENTRANT

CCWebConfiguration.o: CCWebConfiguration.c

$(GCC) -c -O2 $(DEFs) $*.c

I get following error:

make: *** No rule to make target `CCWebConfiguration.c', needed by `CCWebConfiguration.o'. Stop.
Sep 2 '08 #1
3 3686
make: *** No rule to make target `CCWebConfiguration.c', needed by `CCWebConfiguration.o'. Stop.
Sep 2 '08 #2
weaknessforcats
9,208 Expert Mod 8TB
I assume you have a book on make.

I would look in there.
Sep 2 '08 #3
JosAH
11,448 Expert 8TB
Gnu's make can change its current working directory and start itself again (semi)
recursively. As has been told before: RTFM.

kind regards,

Jos
Sep 2 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Sean Dettrick | last post by:
I am wondering if it is possible to increment an integer at compile time using template<int N> (or by any other method, e.g. compiler directives etc), across multiple source files. This may...
0
by: Matthias Martetschlaeger | last post by:
Hi everyone, we use Clearcase dynamic Views to get our Source-Files. Due speed reasons, the output files should not go to the same location (dynamic view) as the source files are located, this...
0
by: Doug Gordon | last post by:
I've been working thru some MFC sample projects in hopes of converting myself from an old C programmer to a (still old) C++ Windows programmer :-). I am using VS 6.0 with SP5 on an XP Home system....
5
by: bhu | last post by:
Hi any idea how to get a set of files from a Directory, if a Directory contains 100 files i want to access 10 file at a time move it to a different directory , grab the next 10 do the same, Also...
5
by: KraftDiner | last post by:
Hi I need help writing a python script that traverses (recursivly) a directory and its sub directories and processes all files in the directory. So at each directory if there are files in it I...
2
by: blisspikle | last post by:
Is there any way to use the "imports" keyword for your current solution to use code (classes) that were used in a different solution in a different directory without compiling them to a dll? I...
4
by: Horacius ReX | last post by:
Hi, I have a C program split into different source files. I am trying a new compiler and for some reason it only accepts a single source file. So I need to "mix" all my different C source files...
6
by: Oliver Graeser | last post by:
Ok, stupid question.... I used to write programs all into one text files and compile them. Works, fine. Then I discovered XCode (or IDEs in general) which appear to be really increasing my...
4
by: Mathanan | last post by:
I am writing a script that uses different directories to get php files and html files. directory structure looks like this /includes (directory to php files) /secure (directory to HTML files)...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.