Free Software - PureInstall

Developed or developing a new product in PureBasic? Tell the world about it.
User avatar
Paul
PureBasic Expert
PureBasic Expert
Posts: 1285
Joined: Fri Apr 25, 2003 4:34 pm
Location: Canada
Contact:

Free Software - PureInstall

Post by Paul »

For those who would like to package their application quickly without spending any money and still have it look professional, I have posted a FREE application packager for everyone to use...

http://www.reelmediaproductions.com/pureinstall

Of course it's written in PureBasic :)

View the QuickTour to learn how to use it!
Image Image
DominiqueB
Enthusiast
Enthusiast
Posts: 103
Joined: Fri Apr 25, 2003 4:00 pm
Location: France

Thank's

Post by DominiqueB »

Thank's a lot Paul.
Install worked great on XP pro.

Dominique.
Dominique

Windows 10 64bits. Pure basic 32bits
Karbon
PureBasic Expert
PureBasic Expert
Posts: 2010
Joined: Mon Jun 02, 2003 1:42 am
Location: Ashland, KY
Contact:

Post by Karbon »

As always Paul, excellent work! Thank you!
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Free Software - PureInstall

Post by PB »

Looks great Paul -- but I have some suggestions. :)

(1) Can it default to C:\Program Files\MyApp instead of C:\MyApp?

(2) Maybe an option to accept an agreement before installation?

(3) Maybe prompt before uninstalling, in case user selects it by accident?

(4) Maybe an option to install MyApp.exe to the Windows Startup folder,
for apps that are meant to be run at startup?

(5) Delete all Registry entries created by PureInstall after uninstalling the
application (HKEY_LOCAL_MACHINE\SOFTWARE\PureInstall\MyApp).

Other than that -- good job, as I needed a small installer. :D

UPDATE:

Major bug: Crashes on Win98 SE (two such PCs tested). Crash occurs
when I click "Next" to start the actual install.

Small bug: The uninstall.bat file leaves the app's folder behind, instead of
deleting it. Well, I assume it should delete it. :wink:

Also, on systems with large fonts enabled, the 'Welcome to the MyApp
Installer Program' message at startup can wrap over two lines, with the
second line being cropped. This mainly happens if your app has a name
of around 10-20 characters, and again, this was tested on a PC with large
fonts enabled.

I gave a friend a test version to test the installation of one of my apps,
and he's running Windows NT, and he has this to say: "When I run the
installer, it kind of seems to freeze (or pause on a gray screen) for 4
seconds & [the CPU usage gopes to 100% during that time]... and then
it goes into the first welcome screen."

Over to you. 8)
Last edited by PB on Mon Aug 18, 2003 8:37 am, edited 5 times in total.
User avatar
Inner
PureBasic Expert
PureBasic Expert
Posts: 714
Joined: Fri Apr 25, 2003 4:47 pm
Location: New Zealand

Post by Inner »

Excellent :) thanks paul
GPI
PureBasic Expert
PureBasic Expert
Posts: 1394
Joined: Fri Apr 25, 2003 6:41 pm

Re: Free Software - PureInstall

Post by GPI »

PB wrote:Looks great Paul -- but I have some suggestions. :)

(1) Can it default to C:\Program Files\MyApp instead of C:\MyApp?
Not a good idea. On my german windows this must:
c:\programme

Also the start-menu is in a diffrent directory
C:\WINDOWS\Startmenü\Programme

There are Windows-Functions for this (look in the IncludePack1 of japbe, the system.pbi)
plouf
Enthusiast
Enthusiast
Posts: 282
Joined: Fri Apr 25, 2003 6:35 pm
Location: Athens,Greece

Re: Free Software - PureInstall

Post by plouf »

GPI wrote:
PB wrote:Looks great Paul -- but I have some suggestions. :)

(1) Can it default to C:\Program Files\MyApp instead of C:\MyApp?
Not a good idea. On my german windows this must:
c:\programme

Also the start-menu is in a diffrent directory
C:\WINDOWS\Startmenü\Programme

There are Windows-Functions for this (look in the IncludePack1 of japbe, the system.pbi)
there keys in registry telling you the path
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\Startup
for the startup forlder in example (thats way most installers find the correct path )
and i agree that registry and folder should be removed at uninstallation

BTW nice cool tool
Christos
GPI
PureBasic Expert
PureBasic Expert
Posts: 1394
Joined: Fri Apr 25, 2003 6:41 pm

Re: Free Software - PureInstall

Post by GPI »

>there keys in registry telling you the path
>HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion
>\Explorer\Shell Folders\Startup
>for the startup forlder in example (thats way most installers find the correct
>path )

Thats the wrongest way, you can do this.
and i agree that registry and folder should be removed at uninstallation

little snap out of my system.pbi from the IncludePack1

Code: Select all

#GetPath_Desktop=0
#GetPath_Fonts = $14
#GetPath_Programs = $2
#GetPath_SendTo = $9
#GetPath_StartMenu = $B
#GetPath_StartUp = $7
#GetPath_Templates = $15
#GetPath_MyDocuments = $5
Procedure.s GetPath(Type); - Return the path of some system-directorys
  *itemid.Long = #NULL
  If SHGetSpecialFolderLocation_ (0, Type, @*itemid) = #NOERROR
    location$ = Space (#MAX_PATH+1)
    If SHGetPathFromIDList_ (*itemid, @location$)
      If Right(location$,1)<>"\" : location$+"\" : EndIf
      ProcedureReturn location$
    EndIf
  EndIf
EndProcedure
So you should do this, and it is secure for all Windows-Systems (also future ones).

The deinstall-programm should be in the software-panel, where all installed software is counted.

And under win98se, i had created a testfile, and the testfile can't install... (no crashes, but i get a errormessages).

Could it be, that the installer don't check if a file can packed, and when it can't pack it not store complete?

GPI
plouf
Enthusiast
Enthusiast
Posts: 282
Joined: Fri Apr 25, 2003 6:35 pm
Location: Athens,Greece

Post by plouf »

So you agree that there is a way to get correct path of system path's :wink:

BTW what do you mean by "wrongest way" ? i have check this key on 98 2k, XP
and it is always there and correct :?:
Christos
User avatar
Paul
PureBasic Expert
PureBasic Expert
Posts: 1285
Joined: Fri Apr 25, 2003 4:34 pm
Location: Canada
Contact:

Post by Paul »

Hi Guys,

GPI: you are very close with your code snippet but you missed the constant that is actually needed to return the "Program Files" path :)
PureInstall already uses SHGetSpecialFolderLocation to retrieve the information needed to add items to the StartMenu.

plouf: Actually MS docs say you can use either to retrieve then "Program Files" path, but the Registry or the API call will work.

If you visit the PureInstall support forum, you will understand why the occasional install package will fail... and I'm waiting for Fred on this one ;)


Just a note, if you select "Help/Check for Online Updates" from the menubar, you will see if you are using the most up to date version of PureInstall.
Image Image
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Free Software - PureInstall

Post by PB »

> > Can it default to C:\Program Files\MyApp instead of C:\MyApp?
>
> Not a good idea. On my german windows this must:
> c:\programme

Well, I meant default to the current system's default application folder,
which is C:\Program Files for English versions of Windows. :wink:
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Free Software - PureInstall

Post by PB »

Just tried v1.4 of PureInstall and when I ran the Uninstall.exe of a test app,
it reported: "Installer data has become corrupt... Program aborting!".
The folder I packaged consisted of just an exe and txt file, with no sub
folders.

Also, on Win98 SE it defaulted to an install path of "\MyApp\" (without any
drive letter), but it didn't crash like it did with v1.2 before.
User avatar
Paul
PureBasic Expert
PureBasic Expert
Posts: 1285
Joined: Fri Apr 25, 2003 4:34 pm
Location: Canada
Contact:

Post by Paul »

Hi PB,

The Uninstaller is meant to be run from the StartMenu (that is why there is a link created for it). Anyway, I have now adjusted it so you can run it by directly clicking on the uninstall program.

As for the other problems, I will be happy when Microsoft drops support for 98 after Christmas, meaning everyone else is off the hook for having to try and support is also :)
Things that seem to work fine on newer OS's exhibit very strange behaviour on older OS's or just won't work right at all.

Anyway, I have posted an update and now I must talk to Fred about a few thing as I may have found some more PB bugs while tinkering with various options ;(
Image Image
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Post by PB »

I downloaded v1.5 but now when I choose Uninstall from the Start Menu
it leaves the app folder and Uninstall.exe there -- even though it said
that the app was uninstalled successfully. :?

> Things that seem to work fine on newer OS's exhibit very strange
> behaviour on older OS's or just won't work right at all.

True, but surely you can add extra code to work around that? :D
User avatar
Rings
Moderator
Moderator
Posts: 1435
Joined: Sat Apr 26, 2003 1:11 am

Post by Rings »

Paul wrote:As for the other problems, I will be happy when Microsoft drops support for 98 after Christmas, meaning everyone else is off the hook for having to try and support is also :)
Things that seem to work fine on newer OS's exhibit very strange behaviour on older OS's or just won't work right at all.
(
Could be my words ,

drop Win89! ;)
SPAMINATOR NR.1
Post Reply