Cygwin Error/warning in codelite

General questions regarding the usage of CodeLite
gerardpuducul
CodeLite Enthusiast
Posts: 36
Joined: Mon Sep 08, 2008 5:11 pm
Contact:

Re: Cygwin Error/warning in codelite

Post by gerardpuducul »

You are incredible!! it is working!! Thanks!! :D :D :D
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cygwin Error/warning in codelite

Post by eranif »

gerardpuducul wrote:You are incredible!! it is working!! Thanks!! :D :D :D
You are wlecome

Eran
Make sure you have read the HOW TO POST thread
gerardpuducul
CodeLite Enthusiast
Posts: 36
Joined: Mon Sep 08, 2008 5:11 pm
Contact:

Re: Cygwin Error/warning in codelite

Post by gerardpuducul »

hy Eran,

finally this features doesn't work well like it does!! :cry:

When there is more than one file with the same name, codelite doesn't focus on the good one. ( it seems it focus on the first one)

I have try it with the rev 2247 on windows
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cygwin Error/warning in codelite

Post by eranif »

Well, this can only happen in the following scenario:

1. You are using custom makefile
2. The makefile is NOT using absolute path

Can u paste here an example of the build output you got?

Eran
Make sure you have read the HOW TO POST thread
gerardpuducul
CodeLite Enthusiast
Posts: 36
Joined: Mon Sep 08, 2008 5:11 pm
Contact:

Re: Cygwin Error/warning in codelite

Post by gerardpuducul »

You are true :
I use a custom ;akefile
and mymakefile not using absolute makefile

here an build output :

Code: Select all

make
----------Building project:[ SW - 6712_2A_THSYS ]----------
tcc -li -apcs /inter  -g -I../../source -I../../../lib/source -I../../../../PRISM_SW/common/hardware -I../../../../PRISM_SW/common/system -I../../../../PRISM_SW/hal_2g/hal/include -I../../../../PRISM_SW/hal_2g/hal/source -I../../../../PRISM_SW/hal_audio/hal/include -I../../../../PRISM_SW/hal_audio/hal/source -I../../../../PRISM_SW/hal/include -I../../source/ft -cpu ARM9E-S -DNEMO_3 -DRF_U3588_NEMO -DPNX6712_2A -DPRISM=20 -DDEMUX_I2C -DDEBUG -DBOOT_ON_DEFENSE -UTEST_HR_FILTER -UHAL_TRACE -DHAL_MONITORING_WITH_FAGC_NOT_USED -UAUTOMATION -DHAL_USE_PREDEFINE_TABLE_RF -DINLINE -UWITH_REAL_TIMER -DDSP_CLOCK_117 -UDSP_CLOCK_104 -DDSP2_CLOCK_117 -UDSP2_CLOCK_104 -DPLUGIN_A_AVAILABLE -DPLUGIN_B_AVAILABLE -DPLUGIN_C_AVAILABLE -DPLUGIN_D_AVAILABLE -DPLUGIN_E_AVAILABLE -DPLUGIN_F_AVAILABLE -DPLUGIN_G_AVAILABLE -DPLUGIN_H_AVAILABLE -DPLUGIN_I_AVAILABLE -DPLUGIN_J_AVAILABLE -DPLUGIN_K_AVAILABLE -DPLUGIN_L_AVAILABLE -DPLUGIN_M_AVAILABLE -DPLUGIN_N_AVAILABLE  -DPNX6712_2A -DDTM   -c -o hal_rf.o ../../../../PRISM_SW/hal_2g/hal_rf/source/uaa3588_NEMO/hal_rf.c
"..\..\..\..\PRISM_SW\hal_2g\hal_rf\source\uaa3588_NEMO\hal_rf.c", line 1455: Warning: C2870W: variable 'K_value' declared but not used
"..\..\..\..\PRISM_SW\hal_2g\hal_rf\source\uaa3588_NEMO\hal_rf.c", line 1455: Warning: C2870W: variable 'N_value' declared but not used
"..\..\..\..\PRISM_SW\hal_2g\hal_rf\source\uaa3588_NEMO\hal_rf.c", line 1670: Warning: C2870W: variable 'N_value' declared but not used
"..\..\..\..\PRISM_SW\hal_2g\hal_rf\source\uaa3588_NEMO\hal_rf.c", line 1670: Warning: C2870W: variable 'K_value' declared but not used
..\..\..\..\PRISM_SW\hal_2g\hal_rf\source\uaa3588_NEMO\hal_rf.c: 4 warnings, 0 errors, 0 serious errors
armlink -elf -symdefs th.sym -map -noremove -symbols -info sizes,totals,veneers,unused -list th.map -scatter ../generic/scat_prism.txt th.o th_lib.o th_inline.o ft.o ft_user.o ft_power.o ft_sync.o ft_tch.o ft_pdch.o ft_slow.o ft_data.o inthand.o startup.o sys.o l1_count.o t_io.o uart.o hal_rf.o ft_edge.o ft_mp.o prism_a.o prism_t.o prism_audio_conf.o prism_lookup_tab.o ../../../../PRISM_SW/hal_2g/hal_rf/source/uaa3588_NEMO/hal_rftx.o i2c_com.o demux_tools.o fpga_tools.o ft_sleep.o ft_ppp.o ft_dtm.o vectors.o ../../../../PRISM_SW/hal_2g/hal/prod/hal_pnx6712_2a_g.lib ../../../../PRISM_SW/hal_audio/hal/prod/hal_pnx6712_2a_audio_g.lib -o th.elf
0 errors, 4 warnings, total time: 00:00:04 seconds
----------Build Ended----------
Is there no issue?

Thanks
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cygwin Error/warning in codelite

Post by eranif »

In such case, CodeLite can not tell which is the correct file to use - if it was an absolute path, it would have compare absolute paths - but since this is not the case, it is comparing file names only without the path.

And like you saw: it opens the first match.

As a quick solution: I can offer popup a dialog for you to chose which one to open in case codelite can not determine which one is the correct one

Eran
Make sure you have read the HOW TO POST thread
gerardpuducul
CodeLite Enthusiast
Posts: 36
Joined: Mon Sep 08, 2008 5:11 pm
Contact:

Re: Cygwin Error/warning in codelite

Post by gerardpuducul »

of course a popup can be a solution.

but why don't you use the relative path to find the file? In the custom build i have filled the working directory ( where my makefile is). So the output start from there. Why can't you do the same thing? :?:
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cygwin Error/warning in codelite

Post by eranif »

Because usually makefile changes the directory very often, the working directory is the path where the makefile is.
a command like

Code: Select all

cd some/dir/ && make
is very common to find in makefile. I can not guess what was the working directory of the failed command.

I am thinking of another solution that will reduce the need for popup dialog to minimum:
comparing directories backward.

For example:
let say that the error file is something like this:

Code: Select all

..\..\..\..\some\path\file.cpp
but codelite knows about these files:

Code: Select all

C:\devl\some\path\file.cpp
and

Code: Select all

C:\devl\some\other_path\file.cpp
I can make codelite open the one that the last directory matches the any of the files, in our case, codelite will open:

Code: Select all

C:\devl\some\path\file.cpp
since path matches path...

If more than one match will be found, the dialog will be shown

Eran

Eran
Make sure you have read the HOW TO POST thread
gerardpuducul
CodeLite Enthusiast
Posts: 36
Joined: Mon Sep 08, 2008 5:11 pm
Contact:

Re: Cygwin Error/warning in codelite

Post by gerardpuducul »

Yes this will be a good solution!!! :D
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cygwin Error/warning in codelite

Post by eranif »

this solution is now committed into SVN trunk and will part of next release.

I tested it and it seems to works correctly.

Eran
Make sure you have read the HOW TO POST thread
Post Reply