CTC compiler : makefile dependency

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
aj2903
Level 1
Level 1
First like given First question asked First comment on blog

Hello All,

This is little off topic, but since it is related to cctc compiler, posting this query on this community.

I'm able to compile and build the code using cctc compiler via makefile.

However i want to add .dep (dependency file ) in makefile while compilation, so that the dependency are automatically generated for .c, but i could not see any sample / example for the same.

It would be highly appreciated if someone could answer this query.

 

Note:

- .dep file is generated for each .c files. 

- Using amk utility instead of make

 

0 Likes
1 Solution
lock attach
Attachments are accessible only for community members.
User13836
Level 6
Level 6
50 likes received 50 solutions authored 100 sign-ins

The TASKING Eclipse environment does create makefiles which do include dependecy verification. Enclosed is a minimized example which can be built using a command line invocation. Before building it you need to adapt the 

PRODDIR = T:\TK060024\rel6_3r1\TriCore\ctc

entry included in the file named 'makefile' which is located in the 'debug' subfolder and fill in the path to the 'ctc' subfolder of the TriCore tools installation at your side. The project is compliant to TASKING TriCore v6.3r1.

In order to build the project you can use the invocation:

<path to the ctc\bin folder>\amk -Gdebug

executed within the 'TASKING_Eclipse_Makefile' folder.

Best regards,

Ulrich Kloidt
TASKING tools support

 

 

View solution in original post

0 Likes
3 Replies
Anupama_A
Moderator
Moderator
Moderator
50 solutions authored 10 likes received 250 sign-ins

Hi @User13836 ,

 

Could you please help here?

 

Best regards, 

Anupama. 

0 Likes
aj2903
Level 1
Level 1
First like given First question asked First comment on blog

Hello All,


Just simplying the question incase there is still ambiguity :

As i said earlier the compilation via makefile is working fine...
But we need to handle (.dep file) using ctc compiler via makefile`

//sharing the code snippet for better understanding
//in makefile

//For eg :
//here if we add manually the .h files we are able to get desire results
task.o : task.c task.h time.h

 

But since in project there may be multiple .h files,
so we came across .dep file (.d in gcc) to handle depedency

We are also been able to generate the .dep for each .c file.

But the question is how to tell the compiler to include .dep file (depedencies)
for compilation process using makefile ?
Are there any CFLAGS to handle or something else which needs to be figure out ?

 

Note : Similar can be achieved using gcc compiler using .d files and with CFLAG such as MD and with other options.  

Thanks in Advanced

 

 

0 Likes
lock attach
Attachments are accessible only for community members.
User13836
Level 6
Level 6
50 likes received 50 solutions authored 100 sign-ins

The TASKING Eclipse environment does create makefiles which do include dependecy verification. Enclosed is a minimized example which can be built using a command line invocation. Before building it you need to adapt the 

PRODDIR = T:\TK060024\rel6_3r1\TriCore\ctc

entry included in the file named 'makefile' which is located in the 'debug' subfolder and fill in the path to the 'ctc' subfolder of the TriCore tools installation at your side. The project is compliant to TASKING TriCore v6.3r1.

In order to build the project you can use the invocation:

<path to the ctc\bin folder>\amk -Gdebug

executed within the 'TASKING_Eclipse_Makefile' folder.

Best regards,

Ulrich Kloidt
TASKING tools support

 

 

0 Likes