Hi-Tech Software bought by Microchip - no more other compilers

e

=A0They

That is Eclipse for ya.

Eclipse is the basis for the Xilinx EDK's SDK. I like the debug features but the whole thing is hateful for version control (a million little XML files with no apparent rhyme or reason). And yes, when you remove a file from the project, it deletes it from the file system.

Also, consider that you have a directory called src where you keep your sources. Eclipse always assumes that if a file is in that directory, then it's part of the project. Why does this suck? Well, all sources are compiled. Since the MicroBlaze linker is too stupid to check to see if a function is actually called (no smart linking), everything compiled ends up in your executable. So if your sources are of the "one file one function" sort, a workaround is to simply not add the unused sources in the project. Which you can't do in Eclipse. And if you delete the source from the project, it's deleted from the file system and it messes up the version control.

Maybe this was improved in 11.2. Dunno.

-a

Reply to
Andy Peters
Loading thread data ...

While I agree that it's bad that project files and files on the disk are forcibly tied, I believe that if a file is not part of a projects source code, it should not be in the source code directory! If a file is not part of your current program, don't keep it mixed up with the rest of the program. For my development work, I always compile using a makefile that compiles all .c files in the directory. For me, "project management" is simply file management.

When you take about a directory of files with one function per file, it sounds to me like a library. If that's the case, then just build it as a library - when you link to that library, only required functions will be included in the executable.

Finally, although I have never used the MicroBlaze, I believe the compiler is gcc. Depending on the version of gcc (and matching binutils), you might have the "-ffunction-sections" switch which puts each function in its own code section, and the -Wl,--gc-sections which tells the linker to drop unneeded sections. Alternatively (again, depending on the version of gcc) you might have the "--combine

-fwhole-program" switches which compiles everything at once, and treats all functions as effectively "static". Unused static functions will then be dropped. In other words, you *do* have smart linking - if the MicroBlaze gcc is a new enough version.

Reply to
David Brown

Well, that's cutting it a little to simple. Projects exist where not all source files are needed in every target being made.

Projects exist where it would be a complete nightmare if there were to be such a thing as "the" source directory instead of a strictly maintained tree of source directories. There's directory-based access control sometimes, or auto-generated source that has no business sitting in the same directory as the manually maintained one.

Reply to
Hans-Bernhard Bröker

It is funny that this question turned into a rant about IDEs, Eclipse, and how difficult it is to change from one chip vendor to another.

Shameless Plug: everyone reading this thread should get a Renesas SPB:

formatting link
Digikey and other distributors stock them.

IDEs don't need to be expensive, limited or slow. This kit shows off the Renesas HEW IDE and explains how you can do development on 8/16/32 MCUs with one IDE. It has Makefile export, project management features and integrated debugging. Plus there's DLL extensions that let you control the whole works from VB and other tools. Renesas ompilers are essentially free for

Reply to
vinnie

That's all true enough - and methods that suit one type of project and one type of developer might not suit everyone. Let me just say that I think the ideal situation is a one-to-one correspondence between files in your source code directory/directories and the files that are compiled and linked into the project. But if your project structure does not make this practical, you will need to do something else.

Reply to
David Brown

IOW; it works, unless it doesn't work. If there is to be any reuse, you're going to have files that aren't used in a particular build or version. You certainly don't want source files spread out all over the place or worse, multiple copies of the same file.

Reply to
krw

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.