Build problem #2

I've got a multi-project solution (VS 2002) which builds a bunch of DLLs and
then an MFC application.

Now, I want to get it to build the help file (.chm) ... but the interesting
bit is that most of the topic files (and bits of the table of contents and
so on) is actually autogenerated ... by the MFC application, when run with
some magic command line switch.

So what I need to do to build the system is:

(1) build the DLLs
(2) build the application
(3) run the application, giving it a magic command line switch, to generate
some help files
(4) build the .chm

Various approaches seem possible:

(a) Try to do it all inside the project that builds the application,
probably using some combination of a Project Custom Build Step and the
Post-Build Event to do (3) and (4) (and all the other stuff that the
Post-Build event is already doing).

(b) Leave the existing project just building the application, and add a new
project to the solution to do (3) and (4). But, what sort of project should
it be? - there's no generic "empty project" option to which I could add the
necessary custom build steps.

(c) As (b) but use a "makefile project" and code all the dependencies for
(3) and (4) in the makefile and maintain it by hand.

Pros and cons??

One issue is that it would be nice if (3) could run whenever any of the
source files in one subdirectory of the application's project changed (as
the application might then generate different help files), and to run (4) if
*either* (3) was run *or* any of the hand-written help files have changed
(which again really wants me to be able to specify a wild-card for the
dependencies, as I don't want to have to list every single hand-written
topic file under "Additional Dependencies"). Step (3) takes a couple of
minutes, and (4) many seconds, so I'd like to both avoid running them when
not necessary and make sure I do run them when they need to be run.

-- 
Tim Ward
Brett Ward Limited - www.brettward.co.uk


0
tw2 (223)
12/6/2006 2:55:24 PM
vc.mfc 33608 articles. 0 followers. Follow

2 Replies
411 Views

Similar Articles

[PageSpeed] 37

"Tim Ward" <tw2@ipaccess.com> wrote in
news:4to3usF14advsU1@mid.individual.net: 

> I've got a multi-project solution (VS 2002) which builds a bunch of
> DLLs and then an MFC application.
> 
> Now, I want to get it to build the help file (.chm) ... but the
> interesting bit is that most of the topic files (and bits of the table
> of contents and so on) is actually autogenerated ... by the MFC
> application, when run with some magic command line switch.
> 
> So what I need to do to build the system is:
> 
> (1) build the DLLs
> (2) build the application
> (3) run the application, giving it a magic command line switch, to
> generate some help files
> (4) build the .chm

I do something close: A run a custom tool that parses the resource.hm 
file and converts the hex values into decimal so that the hhc compiler 
will properly work with text popups. I also have a tendency to hand-edit 
my resource file - so it does some sanity checking in case I need to 
regenerate the help ids.

Anyways, that project (call it ParseResourceHeader) is dependent on the 
main executable and in it's post-build step, it calls a script that runs 
itself and the hhc compiler. This does mean that if I manually change the 
help files, I have to manually rebuild the chm file. But it's wrapped up 
in a nice bat file: "BuildHelp Release VC8" (this allows me to run 
debug/release, vc7/8/8x64 compiler combinations)

Dave Connet
http://www.agilityrecordbook.com
0
connet1 (33)
12/8/2006 2:47:23 AM
"David Connet" <connet@entelos.com> wrote in message 
news:8IidnSR5S56mT-XYnZ2dnUVZ_rOqnZ2d@comcast.com...
>
> Anyways, that project (call it ParseResourceHeader) is dependent on the
> main executable and in it's post-build step, it calls a script that runs
> itself and the hhc compiler.

I've ended up with essentially that solution, a makefile run from the 
post-build step. Appropriate use of wildcards in the dependencies means that 
I'll hardly ever have to tweak the makefile. (And a nice touch is that the 
PATH in effect when the makefile is run includes all the tools directories 
set for the project, which could have been a bit of a headache otherwise.)

-- 
Tim Ward - posting as an individual unless otherwise clear
Brett Ward Limited - www.brettward.co.uk
Cambridge Accommodation Notice Board - www.brettward.co.uk/canb
Cambridge City Councillor


0
tim6244 (11)
12/8/2006 8:33:46 AM
Reply:

Similar Artilces:

default appointment times problems
When i re-open outlook and go to the calender, all the appointments times have changed to 1am on the start day - 1am on the day after it waqs meant to finish. So a 12 day appointment is now shown as over 2 days. How do you change the default appointment time settings so an appointment which is just typed into the day is from 9am - 5pm for example and will stay as a 1 day event when opening and closing outlook? All day events are 12 -12, not 9-5. If you want it 9-5, you need to make it for 9-5. All day appointment change to 1 -1 if you change the time zone or DST settings aft...

Problem with vba directory function
Hi We have an access application that has a button when clicked opens an excel worksheet showing all exported data based on code The access sql system is in Citrix with a single front end copy. Here is the code part that is throwing the error for just one user. Rest all are working fine Dim strSourceFileName As String Dim WorkBookName As String strSourceFileName = "c:\CarLogOutPut\CarLogExportTemplate.xls" WorkBookName = "c:\CarLogOutPut\CarLogExport.xls" If Dir(strSourceFileName) = "" Then MsgBox "CarLogExportTemplate.xls doe...

Outlook 2003 sends my gmail through 2 steps, why??
I am using Outlook 2003 to send my gmail account through smtp.gmail.com. When I send mail in Outlook, it goes into the Outbox rather than get sent right away. Then from my outbox, I can send the email. This seems like a redundancy in efforts, how can I get Outlook to send it straight away? Look at the Tools Menu, then Options, then Mail Setup Tab. Check off the box "Send immediately when connected". -- Lenny V "Uncle Scotty" wrote: > I am using Outlook 2003 to send my gmail account through > smtp.gmail.com. When I send mail in Outlook, it goes into the Outbox...

File Sharing Problems
Can anyone explain this error/information message to me? - "The file 'filename.xls' may have been changed by another user since you last saved it. In that case, what do you want to do?" Options are to Save a Copy or Overwrite Changes. The file is not being shared with anyone else - it comes up whenever making general saves in Excel. -THANKS! Hi try deleting all files in your TEMP directory, reboot your computer and try again -- Regards Frank Kabel Frankfurt, Germany "Kristi - Skills Group" <KristiSkillsGroup@discussions.microsoft.com> schrieb im...

Connection Problem 03-20-08
Hello I'm new to access programming so I'm probably making some obvious mistake. The following code comes from 'Beginning Access 2003 VBA' by Denise Cosnell. On page 130 of the book you can read: 1. Create a new database by selecting File ?New ?Blank Database and specifying Ch5CodeExamples as the filename. 2. Create a new table in the database by selecting Tables from the Database Window and clicking the Design button. Alternatively, you can select the New button and then choose Design View from the list. The table should be named tblContacts and should have the fields i...

Access Query Output to report Summation problems
Hello, I have a query that I output into a report. When I use the sum function in the report control source property field I get a mismatch error when I run the report. example CURRENT DOLLARS 2.00 - 3.00 - - =Sum(current_1) the "-" signifies nothing, the output is blank on the report and in the database there is no data stored there. I read that the sum function ignores null. Is there a way where I can sum the above example? Also, I cannot populate the cells with 0's because 0 is an actual value. Thanks in advance Is it possible that current_1 is NOT numerical (but te...

Problem w/ workbook size, processing
I have a workbook which creates and inserts additional sheets, based o a list of items located elsewhere. The number is items in the lis varies, but I would like the workbook to handle as many as possible Then, the macro pastes identical info onto each of the newly create sheets. On each sheet then, there is about 750 rows and 20 columns o data. The macro is designed to create, then paste, then create... The problem I have, is that after around 75 sheets, the workbook slam to a halt during the sheet creation process. I have found it seem faster to select and paste entire columns, versus rang...

Problems creating my own AFX_MODULE_STATE for multiple gui threads
I'm trying to convert a single gui threaded application to use multiple threads (one for each main window). I've created my own CWinThread subclass and use that to spawn new gui threads. Everything runs properly until I try to shut down my applications and close my threads -- various asserts start to fire. The shutdown of a gui thread invokes the function AfxEndThread which will call AfxOleTermOrFreeLib, which eventually calls COleObjectFactory::RevokeAll, and here is my problem. RevokeAll will go through all the class factory objects registered in the module state's m_factoryL...

Problems with VC++ 6.0 debug symbols under XP Home SP2
Just installed XP Home (including SP2), and then installed VC++ 6.0 SP6. Then I downloaded WindowsXP-KB835935-SP2-slp-Symbols.exe from http://www.microsoft.com/whdc/ddk/debugging/symbolpkg.mspx and installed it. But when working with the compiler I noticed that no debug symbols could be loaded at all. (Under NT4 SP6a I was used to have debug symbols at least for Mfc42d.dll resp. Mfc42.dll) And yes, I have read KB article 304989. So I added a registry string value "Pdb Dirs" under [HKEY_CURRENT_USER\Software\Microsoft\ Devstudio\6.0\Build System\Components\Platforms\Win32 (x86)\...

Excel 2007 Conditional Formatting problem
I have a conditional format that works fine on the previous version of Excel, but not so well on 2007. It is a formula condition: =AND($D$13 = "N",LEFT($D$6,2) = "AP")=TRUE D13 is the cell with the conditional format in it and D6 is a drop down of items, some of which start with "AP" and some of which start with "GL". (Basically, I'm having D13 turn red when D13 has a value of "N" and D6 starts with "AP".) It works just fine if you are changing the value of D13. It doesn't work at all if you are changing the value of D6-- ...

Problem with after update code in field that disables another field
Hi I want to be able to disable the Non Member field in a record when something is entered in the Member field. Unfortunately, the code I am usng below disables the Non Member field in *all* records, and the database has to be closed and reopened to get round this before data entry can continue. I'd be grateful if someone could show me the correction, Thanks. Private Sub Member_AfterUpdate() If Not IsNull([Member]) Then Me![Non Members].Enabled = False Else Me![Non Members].Enabled = True End If End Sub Sam, You need to put that same code in on the OnCurrent event of the form...

Please help me solve my problem
Hi, I Have a cell say a1 that has a continuously changing number it in and I want to track the highest number that it prints, and the same for the lowest number in cell a2. I would like these results to show up in the cells below them Im very new to programming and your help would be much appreciated many thanks Sacha David On Mar 5, 1:01=A0pm, Sacha David <sach1...@googlemail.com> wrote: > Hi, =A0I Have a cell say a1 that has a continuously changing number it > in and I want to track the highest number that it prints, =A0and the > same for the lowest number i...

Copy / Paste of Floorplan shapes in Visio Automation problems
Hi All I am working on a .Net (FW1.1) application that has a hosted Visio drawing control. Copy and paste from most existing Visio drawings to this hosted control works fine. The exception to this rule is Visio floorplans, where copying and pasting of most shapes is OK, but walls go totally screwed up (all over the screen, nothing like their original shape, etc). Our client needs to be able to copy and paste the floorplans into this container control without the walls breaking; they have a large investment already made i.t.o. existing floorplans. Page scaling and size is the same as the exi...

Outlook hanging #2
When I open Outlook it is slow to check send/receive. Once open, it appears to be randomly hanging when I click on a message to open it. Especially those with attachments. I have to control, alt, delete to move on. When I open the details window in the error report window it has "szAppName:OUTLOOK.EXE szAppVer: 10.0.4510.0 szModName:hungapp szModVer: 0.0.0.0 offset:00000000". I can't seem to get past this problem, and have been unable to find anything to help me fix it. ...

Outlook 2000 & Vista #2
Can anyone tell me whether Outlook 2000 (from Ofice 2000) is compatible with Vista? If so, where might I find support to complete the installation? I keep getting an "Operation Cancelled" message anytime I try to sign in or set Outlook 2000 as my default. Thanks -- Steve Only 2003 and above is fully compatible OL2k is out of support as is OLxp "Steve" <Steve@discussions.microsoft.com> wrote in message news:ACAE99AB-0EAB-4523-9304-AFAB18AB724C@microsoft.com... > Can anyone tell me whether Outlook 2000 (from Ofice 2000) is compatible > with > Vista? I...

Problem moving mailbox between administrative groups
Hi there, We have a big problem. We need to move mailboxes from one adm group to other, and at ramdom we receive a MAPI Error Error moving messages CN=testuser,CN=users,dc=machine,dc=company,dc=com The MAPI call failed MAPI or an unspecified service provicer ID no: 80004005-0000-00000000 The Exchange 2000 organization is in native mode (All E2K) Any thoughts. Thanks in advance -- Gabriel N Argentina ...

CheckBox #2
I have a sheet with a checkbox in column A and a value in column B. There are about 30 rows of this data. The user selects the items they want to view and I run VBA code based on their selection. I want to turn the checkboxes on and off within VBA but can't figure out what each checkbox is named and how to reference it in VBA code. I just need to do something like: CheckBox13 = True Checkbox 99 = False like in Access Can anyone help please? Thanks in advance. Is ActiveSheet.CheckBox13 = True what you need ? Regards.. Daniel "PeterM" <PeterM@discussions.microsoft...

Date formatting in Excel #2
How do I format a cell to return Oct 04 when I type 10-4 in Excel...When I type 10-4, Excel returns Oct 05. Hi When no year is typed, excel would assume it is the current year. You would ahve to type the full date (including 2004) for it to display as Oct 2004. Use Format - cells - date and then select the particular format you want from the options there. >-----Original Message----- >How do I format a cell to return Oct 04 when I type 10-4 in Excel...When I >type 10-4, Excel returns Oct 05. >. > ...

dropdown list problem for newbie
i have a column(A) where each cell is a dropdownlist(same list). if person chooses an item from that list...can it return a correspondin value? example: my drop down list corresponding value animal 005 building 1174 vehicle 3345 so for a specific cell...lets say A1, i choose building from th dropdown. i want it to return a value of 1174 in cell A1. is this possible? if so please help? thx eri -- enag ----------------------------------------------------------------------- enags'...

Sales Pipeline Report #2
Anybody had problems with this report in terms of the group by Date function. Cannot get the date order of the report to work in terms of ordering by Estimated Close date. Am posting here in the attempt to get anyone out there to help me please... have been pulling my hair out in looking at the query in this report to work out how to order by Estimated Close Date! Thanks in advance, Charlie Absolutely. The CRM 4.0 Sales Pipeline report group by Date does not work correctly when using non-US CRM date formats. I have logged this as an issue with MSFT support, who accept there is a ...

Installed from CD, apps in "trial" mode #2
I went through the whole procedure again. Here is the list of files in the Trash: com.microsoft.Office.prefs.plist com.microsoft.Excel.prefs.plist com.microsoft.Entourage.prefs.plist com.microsoft.Entourage.plist com.microsoft.OfficeNotifications.plist Office Font Cache (11) Microsoft Office ACL [English] OLE Registration Database 11 OfficeSync Prefs Custom Dictionary Office 11 First Run Entourage Preferences Proofing Tool Preferences Office Registration Cache 11 OK, the Remove Office tool is operating correctly, there's something else wrong. Check back in a few days, I'm escalatin...

Viewing 2 worksheets in the same workbook
Is there a way of viewing data on two separate worksheets in the same workbook in a similar way to splitting a single worksheet? Thanks Choose Window> New Window Choose Window> Arrange Select Tile (or one of the other options), and check the box 'Windows of active workbook' Click OK In each of the windows, select a different worksheet to view. Ant wrote: > Is there a way of viewing data on two separate worksheets in the same > workbook in a similar way to splitting a single worksheet? -- Debra Dalgleish Excel FAQ, Tips & Book List http://www.contextures....

Mailbox Manager and Moved Mailboxes #2
I set up a new exchange 2003 server and moved mailboxes over to it from an old exchange 5.5 server. Then I ran mailbox manager on the 2003 server in Report Only mode. The report came back all zeros. The only policy I set up was a 30 day limit on deleted items, and I know there were deleted items in the mailboxes I moved older than that. Does it have anything to do with the fact that I just moved the mailboxes recently, so they haven't been on this particular server for 30 days? I read that Mailbox Manager uses three dates to see if it should process a message- PR_MESSAGE_DELIVERY_TI...

IHTMLDocument::Write method problem
Hello EveyOne I am using IHTMLdocument and its method. My aim is to extract the body of a IHTMLDocument after loading the local html page ( saved file ) to IHTMDocument. So I just read the file into buffer , created a safe Array and used IHTMLDocument::write method to write the contents of a file to IHTMLDocument. It worked fine for many web pages, But when I tried it for web page http://www.microsoft.com/isapi/redir.dll?prd=ie&ar=windowsmedia application became NOt Responding.When I debugged the application , I found that the IHTMLDocument::write method never returned and thats why my ap...

sharing problem
Hi there, I have a strange problem. I have 13 exchange users an Exchange 2000 (english) All the users were migrated when I installed Exchange 1 year ago. a month ago 2 users left and were replaced by 2 others so I added them to exchange. All users are using Outlook 2000 (dutch) and are sharing their calendar. When I share the calendar of the 2 new people everybody gets the share in their outlook but when they open it it gives an error that it can't open the share. The strange thing is also that thier shares are in dutch (postbus) and all other shares are in english. I made a workaround b...