Archive: Can anyone make this file a .EXE. I get an error.


Can anyone make this file a .EXE. I get an error.
Can anyone make this file a .exe file? Everytime I try and compile I get an error, i'm new to this stuff so it's a wee bit hard.

Thanks in advance mate.

http://andy.vincent-clan.com/files/g...dInstaller.nsi


Posting the exact error message could be helpful :)


This is the log:


MakeNSIS v2.20 - Copyright 1999-2006 Nullsoft, Inc.

Portions Copyright (C) 1995-1998 Jean-loup Gailly and Mark Adler (zlib).
Portions Copyright (C) 1996-2002 Julian R Seward (bzip2).
Portions Copyright (C) 1999-2003 Igor Pavlov (lzma).

Contributors: nnop@newmail.ru, Ryan Geiss, Andras Varga, Drew Davidson, Peter Windridge, Dave Laundon, Robert Rainwater, Yaroslav Faybishenko, Jeff Doozan, Amir Szekely, Ximon Eighteen, et al.

Processing config:
Processing plugin dlls: "C:\Program Files\NSIS\Plugins\*.dll"
- AdvSplash::show
- Banner::destroy
- Banner::getWindow
- Banner::show
- BgImage::AddImage
- BgImage::AddText
- BgImage::Clear
- BgImage::Destroy
- BgImage::Redraw
- BgImage::SetBg
- BgImage::SetReturn
- BgImage::Sound
- Dialer::AttemptConnect
- Dialer::AutodialHangup
- Dialer::AutodialOnline
- Dialer::AutodialUnattended
- Dialer::GetConnectedState
- InstallOptions::dialog
- InstallOptions::initDialog
- InstallOptions::show
- LangDLL::LangDialog
- Math::Script
- NSISdl::download
- NSISdl::download_quiet
- Splash::show
- StartMenu::Init
- StartMenu::Select
- StartMenu::Show
- System::Alloc
- System::Call
- System::Copy
- System::Free
- System::Get
- System::Int64Op
- System::Store
- TypeLib::GetLibVersion
- TypeLib::Register
- TypeLib::UnRegister
- UserInfo::GetAccountType
- UserInfo::GetName
- VPatch::vpatchfile
- nsExec::Exec
- nsExec::ExecToLog
- nsExec::ExecToStack

!define: "MUI_INSERT_NSISCONF"=""

Changing directory to: "C:\Documents and Settings\Dell\Desktop"

Processing script file: "C:\Documents and Settings\Dell\Desktop\GarrysMod10ModInstaller.nsi"
!define: "PRODUCT_NAME"="MyModName"
!define: "PRODUCT_VERSION"="MyVersion"
!define: "PRODUCT_PUBLISHER"="MyName"
!define: "PRODUCT_WEB_SITE"="MyWebsite"
!include: "C:\Program Files\NSIS\Include\MUI.nsh"
!include: "C:\Program Files\NSIS\Contrib\Modern UI\System.nsh"
NSIS Modern User Interface version 1.75 - © 2002-2006 Joost Verburg (C:\Program Files\NSIS\Contrib\Modern UI\System.nsh:11)
!define: "MUI_VERBOSE"="3"
!include: closed: "C:\Program Files\NSIS\Contrib\Modern UI\System.nsh"
!include: closed: "C:\Program Files\NSIS\Include\MUI.nsh"
!define: "MUI_ABORTWARNING"=""
!define: "MUI_ICON"="C:\Program Files\NSIS\Contrib\Graphics\Icons\modern-install.ico"
!insertmacro: MUI_PAGE_WELCOME
!insertmacro: end of MUI_PAGE_WELCOME
!insertmacro: MUI_PAGE_DIRECTORY
!insertmacro: end of MUI_PAGE_DIRECTORY
!insertmacro: MUI_PAGE_INSTFILES
!insertmacro: end of MUI_PAGE_INSTFILES
!insertmacro: MUI_PAGE_FINISH
!insertmacro: end of MUI_PAGE_FINISH
!insertmacro: MUI_LANGUAGE
!insertmacro: end of MUI_LANGUAGE
Function: "GetSteamAccountName"
Push: $R0
Push: $R1
Push: $R2
Push: $R3
ReadRegStr $R0 HKCU\Software\Valve\Steam\SteamExe
StrCmp "$R0" "" equal=noSteam, nonequal=
StrCpy $R1 "0" () ()
IntOp: $R1=$R1-1
StrCpy $R2 "$R0" (1) ($R1)
StrCmp "$R2" "" equal=noAccount, nonequal=
StrCmp "$R2" "/" equal=0, nonequal=-3
StrCpy $R0 "$R0" ($R1) ()
StrCpy $R1 "0" () ()
IntOp: $R1=$R1+1
StrCpy $R2 "$R0" (1) (-$R1)
StrCmp "$R2" "" equal=+8, nonequal=
StrCmp "$R2" "/" equal=0, nonequal=-3
StrCpy $R2 "$R0" (-$R1) ()
IntOp: $R1=$R1-1
StrCpy $R3 "$R0" () (-$R1)
StrCpy $R0 "$R2\$R3" () ()
IntOp: $R1=$R1+1
Goto: -9
FindFirst: spec="$R0\steamapps\*.*" handle=$R1 output=$R2
StrCmp "$R2" "media" equal=nextFile, nonequal=
StrCmp "$R2" "SourceMods" equal=nextFile, nonequal=
StrCmp "$R2" "." equal=nextFile, nonequal=
StrCmp "$R2" ".." equal=nextFile, nonequal=
IfFileExists: "$R0\steamapps\$R2\*.*" ? done :
ClearErrors
FindNext: handle=$R1 output=$R2
IfErrors ?0:loopFile
FindClose: $R1
StrCpy $R2 "[ACCOUNT_NAME]" () ()
StrCpy $R1 "$R0" () ()
StrCpy $R0 "$R2" () ()
Goto: +3
StrCpy $R1 "" () ()
StrCpy $R0 "" () ()
Pop: $R3
Pop: $R2
Exch($R1,0)
Exch(st(1),0)
Exch($R0,0)
FunctionEnd
LangString: "SteamNotInstalled" 1033 "Valve's Steam is not installed!

Setup will now exit."
LangString: "SteamNoAccounts" 1033 "No Steam accounts have been detected!

Setup will now exit."
LangString: "GarrysModNotInstalled" 1033 "Garry's Mod is not installed!

Setup will now exit."
!define: "GMOD_MOD"=""
Function: "GetGmodPath"
Call "GetSteamAccountName"
Pop: $R0
Pop: $R1
StrCmp "$R0" "" equal=no_steam, nonequal=
StrCmp "$R0" "[ACCOUNT_NAME]" equal=no_account, nonequal=
MessageBox: 16: "$R0"
MessageBox: 16: "$R1"
IfFileExists: "$R1\steamapps\sourcemods\garrysmod\*.*" ? exists : doesnt_exist
MessageBox: 16: "$(SteamNoAccounts)"
Abort: ""
MessageBox: 16: "$(SteamNotInstalled)"
Abort: ""
MessageBox: 16: "$(GarrysModNotInstalled)"
Abort: ""
StrCpy $INSTDIR "$R1\steamapps\sourcemods\garrysmod" () ()
FunctionEnd
Function: ".onInit"
Call "GetGmodPath"
FunctionEnd
Name: "MyModName MyVersion"
OutFile: "MyModName-MyVersion Installer.exe"
InstallDir: "$PROGRAMFILES\MyGmodInstaller"
InstallRegKey: "HKLM\${PRODUCT_DIR_REGKEY}\"
ShowInstDetails: show
Section: "MainSection" ->(SEC01)
CreateDirectory: "$INSTDIR\addons\MyMod"
CreateDirectory: "$INSTDIR\addons\MyMod\materials\models\props_c17"
CreateDirectory: "$INSTDIR\addons\MyMod\materials\mods"
SetOutPath: "$INSTDIR\addons\MyMod"
File: ".\info.txt" -> no files found.
Usage: File [/nonfatal] [/a] ([/r] [/x filespec [...]] filespec [...] |
/oname=outfile one_file_only)
Error in script "C:\Documents and Settings\Dell\Desktop\GarrysMod10ModInstaller.nsi" on line 143 -- aborting creation process


If you want to use the files that are in the same directory as the .nsi, just state the filename:

File "license.txt"

[edit]Also, it's better to have absolute paths, because then you can compile from anywhere.[/edit]

Actually, it's usually better to use relative paths. This way you can move around the script without having to worry about not being able to compile it. It's also easier to make copies of it this way. You won't have to change the paths of the new copy.