You are here

Compile issue with ApplicationPortableTemplate 2.0

7 posts / 0 new
Last post
chris0
Offline
Last seen: 15 years 1 month ago
Joined: 2006-12-02 18:51
Compile issue with ApplicationPortableTemplate 2.0

So I'm trying to make BZFlag portable. Someone claimed earlier that it is already portable, but it leaves a "My BZFlag Files" folder in My Documents. I plugged all necessary data into Klonk's ApplicationPortableTemplate (ver. 2.0) and compiled. It spat this message:


(no errors above here)

Processed 1 file, writing output:
Adding plug-ins initializing function... Done!
Error: could not resolve label "CheckAppsINI" in function "InitINI"
Error - aborting creation process

Any clue?

Also, I don't really remember my environment variables. The folder that gets produced is located at C:\Documents and Settings\<my username>\My Documents\My BZFlag Files. Is this the same as $PROFILE\My\ BZFlag\ Files?

I also tried to compile using Klonk's old (ver. 1.4) template. That compiled, but BZFlag wouldn't start. No error messages, no settings written anywhere. The screen would just go black with a little gray box on one side, and then restore the desktop. If I have a splash screen enabled, that runs but then BZ never starts.

Help?

Zach Thibeau
Zach Thibeau's picture
Offline
Last seen: 2 years 1 month ago
Developer
Joined: 2006-05-26 12:08
I do...

Believe that thats a labeling error in the script is not anything you did I think
-----------------------------
"I don't fear Computers. I fear the lack of them" Isaac Asimov

your friendly neighbourhood moderator Zach Thibeau

chris0
Offline
Last seen: 15 years 1 month ago
Joined: 2006-12-02 18:51
.

What do I do to fix it? Because the compile aborts before spitting out an exe.
__
chris

It is not your audience's responsibility to puzzle out what you intended to say; it is your responsibility to express yourself so clearly that no one with a modicum of intelligence and good will could possibly mistake your meaning.

__
chris

It is not your audience's responsibility to puzzle out what you intended to say; it is your responsibility to express yourself so clearly that no one with a modicum of intelligence and good will could possibly mistake your meaning.

Zach Thibeau
Zach Thibeau's picture
Offline
Last seen: 2 years 1 month ago
Developer
Joined: 2006-05-26 12:08
Hmm

Try redownloading the Template and edit for your app and see what happens. if it Happens again bring up the file here and Either Klonk can check it out or I can Wink
-----------------------------
"I don't fear Computers. I fear the lack of them" Isaac Asimov

your friendly neighbourhood moderator Zach Thibeau

chris0
Offline
Last seen: 15 years 1 month ago
Joined: 2006-12-02 18:51
.

I figured out why it won't compile; it had a readme stuck on the end of the file. When the compiler hit that, it puked.

The other problem is that a) BZFlag starts and then dies, and b) despite what is written below, My Documents\My BZFlag Files still gets created.

Am I being stupid? Or is BZFlag?

A couple other postscripts:
I can't get BZFlag (portable or no) to run from a .bat, from an AutoIt script, or from ASuite (if there are any command line options)
Also, it should be possible to pass -configdir (whatever) to BZFlag, but it seems to ignore that option.


; ----- Basic informations
!define AUTHOR "Chris Reitz" ; your name
!define APP "BZFlag" ; insert application name, e.g. "TestApp"
!define VER "0.5.0.0" ; insert version of launcher
!define EXE "bzflag.exe" ; insert program exe name, e.g. "testapp.exe"

; ----- Application specific stuff
; insert regkeys to use separated by "||", comment out, when not used,
; e.g. HKCU\Software
; !define REGKEYS ""
; If a file "Registry.reg" within the data directory is found then it is read
; and all parent registry keys are processed as if they'd have been set within
; REGKEYS
; !define USEREGKEYSFILE "TRUE"
; insert settings files to use separated by "||" as stored on the host
; computer, e.g. "$WINDIR\TEST.INI", comment out, when not used
; !define SETTINGSFILES "$PROFILE\bzflag.bzc"
; insert settings directories to use separated by "||" as stored on the host
; computer, e.g. "$PROFILE\TEST", comment out, when not used
!define SETTINGSDIRS "$PROFILE\My\ BZFlag\ Files"
; Require local administrator rights to run the launcher, necessary when
;writing to e.g. HKLM registry key. If not required comment out
; !define ADMINREQUIRED "TRUE"
; Redirect Userprofile folder, comment out when your application calls other
; programs, i.e. to disable automatic redirection. Default value "TRUE".
; !define REDIRECTUSERPROFILE "TRUE"
; When "TRUE" a launcher is created that contains the sources and copies them
; into the appropriate folder if they do not exist yet.
; !define INSTALLSOURCES "TRUE"
; define which GTK version should be used, e.g. 2.0
; !define USEGTKVERSION ""
; define which JAVA version should be used, e.g. 1.6.0_01
; !define USEJAVAVERSION ""

; ----- Normally no need to change anything here
; format of portable name (dirs and filenames)
!define PNAME "${App}Portable"
; comment this line out when default icon should be used
!define ICON "${PNAME}.ico"
; comment this line out when no splashscreen image should be used
!define SPLASHIMAGE "${PNAME}.jpg"
; could be changed when settings for multiple applications should be stored in
; one INI file
!define INI "${PNAME}.ini"

; ##########################################################################
; # Normally no need to change anything after this point (only for intermediate/advanced users!)
; ##########################################################################


__
chris

It is not your audience's responsibility to puzzle out what you intended to say; it is your responsibility to express yourself so clearly that no one with a modicum of intelligence and good will could possibly mistake your meaning.

__
chris

It is not your audience's responsibility to puzzle out what you intended to say; it is your responsibility to express yourself so clearly that no one with a modicum of intelligence and good will could possibly mistake your meaning.

Zach Thibeau
Zach Thibeau's picture
Offline
Last seen: 2 years 1 month ago
Developer
Joined: 2006-05-26 12:08
Thats

Thats great glad you got it ^_^
-----------------------------
"I don't fear Computers. I fear the lack of them" Isaac Asimov

your friendly neighbourhood moderator Zach Thibeau

tium2000
Offline
Last seen: 17 years 4 months ago
Joined: 2007-07-05 22:09
code missing in the template?

I got the same problem but cutting out the readme didn't help. It seems that the definition of CheckAppsINI is missing from the file. Googling around I found this piece of code from version 1.9.1:

CheckAppsINI:
IfFileExists "$EXEDIR\Apps\${PNAME}\${INI}" "" CheckDataINI
StrCpy "$INIFILE" "$EXEDIR\Apps\${PNAME}\${INI}"
Goto ReadINIFile
CheckDataINI:
IfFileExists "$EXEDIR\Data\${PNAME}\${INI}" "" InitINIEnd
StrCpy "$INIFILE" "$EXEDIR\Data\${PNAME}\${INI}"
Goto ReadINIFile

I did a copy/paste and now everything works great.

Log in or register to post comments