[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
AW: [cdt-dev] Re: any C compiler integration with CDT
|
I tried to do the same task (to use 'arm-elf-gcc' instead of 'gcc'
(both in Cygwin)) by writing a Plugin using the extension point "org.eclipse.cdt.managedbuilder.core.ManagedBuildInfo" of cdt_2.0.0.
All I wanted to do was changing some default values in the managed build tool-chain.
Finally I had this 'plugin.xml':
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin
id="at.medek.unc20.eclipse.cdt.develop"
name="UNC20 Developer's Plugin"
version="1.0.0"
provider-name="Medek & Schörner Ges.m.b.H">
<runtime>
<library name="unc20_cdt.jar">
<export name="*"/>
</library>
</runtime>
<requires>
<import plugin="org.eclipse.cdt.managedbuilder.ui"/>
<import plugin="org.eclipse.cdt.managedbuilder.core"/>
</requires>
<extension
id="at.medek.unc20.eclipse.cdt.develop.build"
name="UNC20 CDT Develop Build"
point="org.eclipse.cdt.managedbuilder.core.ManagedBuildInfo">
<target
name="Binary for UNC20 (Cygwin on Windows)"
id="cdt.managedbuild.target.gnu.cygwin.test"
isTest="false"
defaultExtension="elf"
scannerInfoCollector="org.eclipse.cdt.managedbuilder.internal.scannerconfig.DefaultGnuWinScannerInfoCollector"
makefileGenerator="org.eclipse.cdt.managedbuilder.makegen.gnu.GnuMakefileGenerator"
isAbstract="false"
binaryParser="org.eclipse.cdt.core.PE"
osList="win32"
parent="cdt.managedbuild.target.gnu">
<configuration
name="Debug"
id="cdt.managedbuild.config.gnu.unc20.cygwin.windows.debug">
<toolReference
command="arm-elf-gcc"
id="cdt.managedbuild.tool.gnu.c.compiler">
<optionReference
defaultValue="gnu.c.optimization.level.none"
id="gnu.c.compiler.option.optimization.level">
</optionReference>
<optionReference
defaultValue="gnu.c.debugging.level.default"
id="gnu.c.compiler.option.debugging.level">
</optionReference>
<optionReference
defaultValue="false"
id="gnu.c.compiler.option.warnings.allwarn">
</optionReference>
<optionReference
defaultValue="-c -mbig-endian -mcpu=arm7tdmi"
id="gnu.c.compiler.option.misc.other">
</optionReference>
</toolReference>
<toolReference
command="arm-elf-gcc"
output="o"
id="cdt.managedbuild.tool.gnu.assembler">
<optionReference
defaultValue="-c -mbig-endian -mcpu=arm7tdmi -Wall"
id="gnu.both.asm.option.flags">
</optionReference>
</toolReference>
<toolReference
outputs="elf"
command="arm-elf-gcc"
id="cdt.managedbuild.tool.gnu.c.linker">
<optionReference
defaultValue="true"
id="gnu.c.link.option.nostart">
</optionReference>
<optionReference
defaultValue="-mbig-endian -mcpu=arm7tdmi -L.. -Tdebug.ld"
id="gnu.c.link.option.ldflags">
</optionReference>
</toolReference>
</configuration>
<configuration
name="Release"
id="cdt.managedbuild.config.gnu.unc20.cygwin.windows.release">
<toolReference
command="arm-elf-gcc"
id="cdt.managedbuild.tool.gnu.c.compiler">
<optionReference
defaultValue="gnu.c.optimization.level.none"
id="gnu.c.compiler.option.optimization.level">
</optionReference>
<optionReference
defaultValue="gnu.c.debugging.level.default"
id="gnu.c.compiler.option.debugging.level">
</optionReference>
<optionReference
defaultValue="false"
id="gnu.c.compiler.option.warnings.allwarn">
</optionReference>
<optionReference
defaultValue="-mbig-endian -mcpu=arm7tdmi"
id="gnu.c.compiler.option.misc.other">
</optionReference>
</toolReference>
<toolReference
command="arm-elf-gcc"
output="o"
id="cdt.managedbuild.tool.gnu.assembler">
<optionReference
defaultValue="-c -mbig-endian -mcpu=arm7tdmi -Wall"
id="gnu.both.asm.option.flags">
</optionReference>
</toolReference>
<toolReference
outputs="elf"
command="arm-elf-gcc"
id="cdt.managedbuild.tool.gnu.c.linker">
<optionReference
defaultValue="true"
id="gnu.c.link.option.nostart">
</optionReference>
<optionReference
defaultValue="-mbig-endian -mcpu=arm7tdmi -L.. -Trelease.ld"
id="gnu.c.link.option.ldflags">
</optionReference>
</toolReference>
</configuration>
<toolReference
id="cdt.managedbuild.tool.gnu.c.linker">
</toolReference>
</target>
</extension>
</plugin>
The corresponding UI-toolchain was exactly what I wanted, but it did not work correctly.
My files were:
init.S
main.c
release.ld
debug.ld
My build output for the 'Debug' configuration was:
**** Incremental build of configuration Debug for project test2 ****
make -k all
Building file: ../main.c
arm-elf-gcc -O0 -g -c -mbig-endian -mcpu=arm7tdmi -o main.o ../main.c
Finished building: ../main.c
Building file: ../init.S
arm-elf-gcc -c -mbig-endian -mcpu=arm7tdmi -Wall -o init.o ../init.S
Finished building: ../init.S
Building target: test2.elf
null null test2.elf main.o init.o
make: null: Command not found
make: *** [test2.elf] Error 127
make: Target `all' not remade because of errors.
Build complete for project test2
Finally I was able to find a workaround for this problem. In the 'Properties'/'C/C++ Build' project folder I pressed the button 'Restore Defaults' and it worked.
**** Incremental build of configuration Debug for project test2 ****
make -k all
Building target: test2.elf
arm-elf-gcc -nostartfiles -mbig-endian -mcpu=arm7tdmi -L.. -Tdebug.ld -o test2.elf main.o init.o
Finished building: test2.elf
Build complete for project test2
In this case the initial values of the tool-chain seemed to be not identical with the 'default' values.
The same problem happened with the 'release' configuration. The workaround is the same.
Is there something wrong with my 'plugin.xml'?
-----Ursprüngliche Nachricht-----
Von: Sarvex Jatasra [mailto:sarvex@xxxxxxxxx]
Gesendet: Freitag, 06. August 2004 06:40
An: cdt-dev@xxxxxxxxxxx
Betreff: RE: [cdt-dev] Re: any C compiler integration with CDT
GO for Standard Make C project and specify your own MakeFile. In the
MakeFile invoke the SunC compiler.
With Regards
Sarvex Jatasra
Software Engineer
Acme Technologies
+91-11-33030881
-> -----Original Message-----
-> From: cdt-dev-admin@xxxxxxxxxxx [mailto:cdt-dev-admin@xxxxxxxxxxx] On
-> Behalf Of Ashok Anand
-> Sent: Thursday, August 05, 2004 7:11 PM
-> To: cdt-dev@xxxxxxxxxxx
-> Subject: Re: [cdt-dev] Re: any C compiler integration with CDT
->
-> Hi,
->
-> CYGWIN provides GCC as well as GDB on windows. Agreed. But, I am
-> looking for a way
-> to use a C compiler other than GCC( because, Cygwin gcc doesn't
-> support every dialect
-> of C, for example, it doesn't support sunC) to integrate it with CDT.
->
-> Looking forward for your response..
-> with regards,
-> Ashok
->
-> On Thu, 5 Aug 2004 18:31:48 +0530, Sarvex Jatasra <sarvex@xxxxxxxxx>
-> wrote:
-> > Look for CYGWIN. It will provide GCC as well as GDB on windows.
Once
-> > gcc.exe and gdb.exe are in PATH environment variables, your problem
-> will
-> > be solved
-> >
-> > With Regards
-> >
-> > Sarvex Jatasra
-> >
-> > Software Engineer
-> > Acme Technologies
-> > +91-11-33030881
-> >
-> > -> -----Original Message-----
-> > -> From: cdt-dev-admin@xxxxxxxxxxx
[mailto:cdt-dev-admin@xxxxxxxxxxx]
-> On
-> > -> Behalf Of Ashok Anand
-> > -> Sent: Thursday, August 05, 2004 6:04 PM
-> > -> To: cdt-dev@xxxxxxxxxxx
-> > -> Subject: [cdt-dev] Re: any C compiler integration with CDT
-> > ->
-> > -> hi,
-> >
-> >
-> > ->
-> > -> Can you please tell me the way to integrate a C compiler other
than
-> > -> gcc, to CDT
-> > -> environment, so that whenever I compile a program, it uses my
-> > compiler
-> > -> instead of using gcc.
-> > -> Can the same be done with a debugger. ?
-> > -> Waiting for your early response.
-> > -> Ashok
-> > -> _______________________________________________
-> > -> cdt-dev mailing list
-> > -> cdt-dev@xxxxxxxxxxx
-> > -> http://dev.eclipse.org/mailman/listinfo/cdt-dev
-> >
-> > _______________________________________________
-> > cdt-dev mailing list
-> > cdt-dev@xxxxxxxxxxx
-> > http://dev.eclipse.org/mailman/listinfo/cdt-dev
-> >
-> _______________________________________________
-> cdt-dev mailing list
-> cdt-dev@xxxxxxxxxxx
-> http://dev.eclipse.org/mailman/listinfo/cdt-dev
_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/cdt-dev