How to use TFS 2008 with Delphi 7 via MSBuild - delphi

Has anyone had any luck using MSBuild with Delphi 7 as part of a TFS 2008 (Microsoft Team Foundation Server 2008) integration? Curious if it is possible, and if it is, what is necessary to set it up.
Thanks!
Update: I am aware that the later versions of Delphi use MSBuild, but it would appear for right now upgrading isn't an option.

To use MSBuild with Delphi 7, you must first produce a representative .dproj file bearing the correct XML markup (as seen in later versions of Delphi). If you construct them properly, then MSBuild will recognize them, and (as directed in the XML markup) will place the appropriate calls to the Delphi 7 compiler.
It's simple enough, but it takes a lot of effort to manually produce the .dproj markup!
EDIT: This guy offers an apparently-functional automated solution to this problem, available on request!

You may write a MSBuild task that invokes dcc32.exe (delphi 7) and passes to it the appropriated commmand line (dpr file name). I wrote a similiar task for NANT in order to integrate delphi 7 with cc.net

Related

How can I put my Borland C++ Builder 6 project into Visual Studio Team Services

We are putting our existing Embarcadero Borland C++ Builder 6 projects into the new free Microsoft source control called "Visual Studio Team Services" (aka online version of TFS or Team Foundation Server formerly called Team Foundation Service).
http://www.visualstudio.com/products/what-is-visual-studio-online-vs
How can I put my code from my BCB 6 project to use it with this system.
Of course I'd prefer to have IDE integration, but as long as I have some kind of GUI I'm fine with doing source code tasks outside of the BCB IDE.
Are there any BCB files that are binary and therefore might be an issue with comparing changes?
Any ideas are greatly appreciated.
C++Builder does not have any native TFS support (not even in the latest version), let alone any VSOnline support. At least with TFS, there are third-party plugins to let C++Builder access TFS:
SourceConneXion
TFS.us
For TFS, you can also use the standard TFS client GUI. For Visual Studio Team Services, who knows.
Several files are binary, including RES and TDS, but you usually don't need to do diffs on those. You should, however, make sure to set your DFM files to Text mode, as they are set to Binary by default. DFMs are always binary in the final executable's resources, but the DFM source files can be either text or binary, and you will likely do diffs on DFMs from time to time.
you could use the visual studio shell (aka 'team explorer everywhere') to do checkins etc
and you could also use the power tools (tfpt) to give you explorer integration.

Can I open my Delphi 2007 project in Visual Studio (or other IDEs)?

I have a big Delphi 2007 project, and the Delphi IDE is slow and unstable even I install DelphiSpeedUP, FixIDE Pack.
The IDE freezes for a few seconds when first loading the project (300K lines of code). The Type Library Editor is very inefficient when I want to add a new method/property because it has around 1000 APIs and it kinda freezes for ten seconds in the Type Library Editor.
But the Delphi Compiler is good and I am happy with that, just the IDE has many issues. The Visual Studio 2010/2012 is very good and stable.
Just wondering if it is possible to code in Delphi in the Visual Studio, a basic syntax highlighting, debugger is OK.
It is not possible.
Visual Studio not work with pascal lang.
You can use np++ for simple syntax highlighting and compile with command lines in DCC32.exe.
and the docs in here.
and for Debug use ollydb.
and I'll not suggest it.
and I think the likely pascal IDE to Delphi is Lazarus but it can't compile your Delphi source code directly.
and I'll not suggest it too.
I think use the Delphi with fix and speedup patches.

Referencing 3rd party components in Delphi 2005

I'm quite new to Delphi and I'm helping a team setting up a build server which are using Rad Studio 2005.
They have just bought DevExpress VCL and wants to use these. I would rather not have the component installed on the build server, but instead having them as a part of the source code and making sure that the project is using that version.
How is that done in Delphi?
We compiled all of our 3rd-party stuff into a BPL, then put that .bpl and corresponding .dcp and .dpr/.bdsproje into source control, so it gets delivered to the build server. Works well. In retrospect, it should have been a series of BPLs, divided by vendor, so that we could upgrade individual components/libraries without having to run regression tests on everything else.

What testing framework/unit testing to use with Delphi XE Starter Edition

I'm looking at moving from Delphi 2007 (purchased by my employer) to Delphi XE Starter Edition (purchased by me because my employer is moving away from Delphi) for some open source/hobby work. So, price is definitely a concern.
Delphi XE Starter Edition doesn't appear to have the integrated DUnit stuff. Are there any recommendations for testing frameworks that will work well with XE Starter? The framework must be automatible; for example, it must must be runnable by a Continuous Integration System such as Hudson or CruiseControl. Of course, free would be best. Integration directly into the IDE would also be handy, but not a requirement.
DUNIT is on SourceForge so you can get it from there. The version on SF is 9.4.0, the same that ships with Delphi XE. The code is however not identical. I do not know if it works with Delphi XE Starter edition but I don't see why it should not.
Will DUnit2 do?
Dunit2 is used in tiOPF framework and said to be quite good. The download sites are:
http://sourceforge.net/projects/dunit2/
http://members.optusnet.com.au/~mcnabp/
http://github.com/graemeg/dunit2
DUnit may be a better choice that DUnit2. With DUnit you can use the jcl and USE_JEDI_JCL to get the line numbers of failures. DUnit2 doesn't appear to support this.
DUNit2 doesn't seem to be getting much attention since Peter's death either. I don't know if it has been updated to use the latest version of delphi but it doesn't look like it.

DELPHI and WANT or NANT

We use cruise control .net to do our Continuous Integration in our Delphi 2006 application. We use a setup similar to the one described here.
QUESTION:
1) What is the best scripting tool/language to use implement the build script?
2) Are there any advantages of using WANT over using NANT?
(NOTE: D2006 is not compatible with MSBuild)
I never used WANT, but NANT works fine with any Delphi version. I presume NANT is also better supported and has more features you can use since it is used more widely then WANT.
BTW: You can still use MSBuild and call dcc32 if you want. In that way it is the same as NANT. If you move to Delphi 2007 MSBuild has a bigger advantage over NANT since the Delphi projects are in the MSBuild format. But even then you can still use NANT as a buildscript. It will just call out to MSBuild to do the separate builds.
Another build tool that is worth checking out is FinalBuilder. It is very complete and knows Delphi. It should, since it is build using Delphi. They also offer a CruiseControl like Continuous Integration solution. The drawback is that FinalBuilder is not free.
Only couple of days back I managed to implement a complex NANT scripts to compile our projects (which uses d7-2009 compilers, VC++ 2005 and subversion). It was very easy to setup and work when used with NantGui .Unlike MSBuild you dont have to have certain version of .NET installed in your system.
For compiling the projects using dcc32, have a look at the delphi3000 article
I used XSL to generate the Cruisecontrol project file automatically. We had a large project with many Delphi applications which already used a common Ant script. So generating the CC project file using a script was a natural solution.
Another Continuous Integration solution which works with Ant (and many others) is TeamCity. It is free up to a certain number of build agents / projects. The user interface is awesome.
I successfully use Ant for many years now for all kinds of Delphi projects, from small component libraries to multi-project multi-tier applications.

Resources