Automatically generate/build EXEs

forum.cdk (1998-2005) & forum.td.cdk (2005-2010)
Romulus Diudea

Automatically generate/build EXEs

Post by Romulus Diudea » 26 Feb 2006, 19:44

 Posted by:  Romulus Diudea 

Hello everyone,

I would like to accomplish the following task (using the TD2005's CDK): open
an APP or APT file and generate/build the EXE.
It should be as though you manually open a file and go: Project --> Build:
xyz.exe, but everything should be done autonatically, from my little app.

Any idea what CDK functions could be used?
I browsed the set of functions provided by the CDK, but no one is spelled
close to what I need.
I assume I need to use some classes (which expose an interface through which
I could access the BUILD options of an app), but I don't know which one(s).

Any help would be greatly appreciated.
Best regards to all of you out there,

Romulus

Jeff Luther
Site Admin
Site Admin
United States of America
Posts: 2167
Joined: 04 Mar 2017, 18:34
Location: Palm Springs, California

Automatically generate/build EXEs

Post by Jeff Luther » 26 Feb 2006, 20:23

 Posted by:  Jeff Luther 

" open an APP or APT file and generate/build the EXE" - You should be able to
do that by calling TD directly. Go to this Gupta page:
http://www.guptaworldwide.com/DevCenter/Tips_Summary.aspx

and look for:
"February 2003: Mahesh Ramakrishnan submitted a utility for automatic
compilation of programs."

Here's what the App. Description states in the utility:
Centura Builder application

Written by Maheswaran Ramakrishnan for CTD151

Program helps to compile all the APTs or APPs and creates EXEs
into the desired folder

Feel free to modify accordingly

Note: If your are using other than CTD151, search and change the following line

"cbi15 -b " || dfFilePath || '\\' || sFiles[ nIdx ] || ' ' || sExe

Best Regards,
Jeff Luther/PC Design
info: www.pulpcards.com/gupta/

Romulus Diudea

Automatically generate/build EXEs

Post by Romulus Diudea » 26 Feb 2006, 21:48

 Posted by:  Romulus Diudea 

Thank you very much, Jeff, for your swift reply.
This looks great, except it doesn't quite do what I need.
I assume some responsibility in not presenting my case too well.
I did not provide a complete and accurate description of the problem.

The proposed solution works fine if the name of the compiled file is the
same as the name of
the source file (or if the user of the compile app specifies a different
name for the compiled file).
But what if we'd like to compile ABC.APP into XYZ.EXE, and we don't know
what XYZ is?
(XYZ is specified in the app's IDE, but it's unknown at the time we run the
compile.exe program).

There should be a way to use a set of CDK functions that will let us open an
APP, and generate an EXE the same way as using the IDE:
Project --> Build: XYZ.EXE.

Whatever value XYZ has within a particular app, that will be the one used.
This will solve the unknown name of the compiled file problem.
The little showstopper here is: what set of CDK functions could provide
that?

I would be very much interested in finding the right answer.

Thank you,

Romulus

Jeff Luther
Site Admin
Site Admin
United States of America
Posts: 2167
Joined: 04 Mar 2017, 18:34
Location: Palm Springs, California

Automatically generate/build EXEs

Post by Jeff Luther » 27 Feb 2006, 02:33

 Posted by:  Jeff Luther 

Then take a look at the CDK class cdkBuildSettings, especially SetTargetType()
and SetTargetName(). They show how to specify setting for your app. and thus
you might be able to set your ABC.APP as MAKERUN_COMEXE and the target name
as XYZ.EXE, save to disk using SaveOutlineXXX() and call cti40 after that.

You can also call cdkBuildSettings.GetTargetName() to find out what XYZ.EXE
is. Looks like the pieces are there; you just need to go put them together.

- Jeff

Romulus Diudea

Automatically generate/build EXEs

Post by Romulus Diudea » 27 Feb 2006, 06:41

 Posted by:  Romulus Diudea 

Thank you, Jeff.
You're right, looks like all the pieces are there.
I really appreciate your help.

All the very best to you,
Romulus

Return to “td.cdk”

Who is online

Users browsing this forum: [Ccbot] and 0 guests