Обсуждение: The leanest, meanest Windows installer possible

Поиск
Список
Период
Сортировка

The leanest, meanest Windows installer possible

От
"Mitchell Vincent"
Дата:
Hi all. I'm looking at distributing PostgreSQL with a desktop
application and have a couple of what might be simple questions.

I've been using PG for years and years but bringing it to the Win32
desktop presents some deployment challenges. Since this software will
be downloaded I am looking for the smallest possible installer that
provides the functionality I'm looking for. Currently the whole
application (including the SQLite library that it's using now) is only
about 4 megs. The 20+ meg installer is awesome in it's functionality
but I won't be using most of what is contained in it (docs, language
drivers, etc). Is there a smaller "bare essentials" MSI installer that
provides an easy interface for setting things like the admin password
and the non-privileged service user addition but that contains only
the required EXEs and DLLs? Or perhaps a way for me to take the MSI
installer and strip out the things I won't be needing?

Thanks!

--
- Mitchell Vincent

Re: The leanest, meanest Windows installer possible

От
"Merlin Moncure"
Дата:
On 7/28/07, Mitchell Vincent <ksoftware@gmail.com> wrote:
> Hi all. I'm looking at distributing PostgreSQL with a desktop
> application and have a couple of what might be simple questions.
>
> I've been using PG for years and years but bringing it to the Win32
> desktop presents some deployment challenges. Since this software will
> be downloaded I am looking for the smallest possible installer that
> provides the functionality I'm looking for. Currently the whole
> application (including the SQLite library that it's using now) is only
> about 4 megs. The 20+ meg installer is awesome in it's functionality
> but I won't be using most of what is contained in it (docs, language
> drivers, etc). Is there a smaller "bare essentials" MSI installer that
> provides an easy interface for setting things like the admin password
> and the non-privileged service user addition but that contains only
> the required EXEs and DLLs? Or perhaps a way for me to take the MSI
> installer and strip out the things I won't be needing?

Well, it's possible to install postgresql on windows using only a
batch file, plus a couple of small utilities like 'ntrights.exe' and
possibly 'sanur.exe' to do some things which are difficult from the
command prompt.  You can use the built in net command to do user
management and pg_ctl.exe can handle creation of the service and
bootstrap the database yourself with runas/initdb.exe.  This would add
a few kb to the required files which are the in the lib, bin, and
share folders iirc.

Also, if you don't have any ssl requirements you can recompile the
database without ssl...ditto contrib.  This is a medium difficulty
exercise and you have to test with all versions of windows you plan to
deploy on (watch out for things like password policies, etc).

Also remember you can run the standard installer in silent mode.  I
think in the long run this is probably a better idea than what you are
thinking about doing...

merlin

Re: The leanest, meanest Windows installer possible

От
"Mitchell Vincent"
Дата:
> On 7/28/07, Mitchell Vincent <ksoftware@gmail.com> wrote:
>
> Also remember you can run the standard installer in silent mode.  I
> think in the long run this is probably a better idea than what you are
> thinking about doing...

Yes, what I'm looking for is a way to reduce the size of the MSI
installer. Since it's been tested I'd sure like to use it but
deploying  20+ megs of additional software with a 4 meg program is
prohibitive right now.

Thanks!

--
- Mitchell Vincent
- K Software - Innovative Software Solutions
- Visit our website and check out our great software!
- http://www.ksoftware.net

Re: The leanest, meanest Windows installer possible

От
"Mitchell Vincent"
Дата:
Now that I think of it, shouldn't everything that is needed to build
the .MSI installer be in one of the source packages? As a user of
InnoSetup I'm afraid I'm clueless about MSI, so if someone could shove
me in the right direction I'd sure appreciate it!


> On 7/28/07, Mitchell Vincent <ksoftware@gmail.com> wrote:
> > Hi all. I'm looking at distributing PostgreSQL with a desktop
> > application and have a couple of what might be simple questions.
> >
> > I've been using PG for years and years but bringing it to the Win32
> > desktop presents some deployment challenges. Since this software will
> > be downloaded I am looking for the smallest possible installer that
> > provides the functionality I'm looking for. Currently the whole
> > application (including the SQLite library that it's using now) is only
> > about 4 megs. The 20+ meg installer is awesome in it's functionality
> > but I won't be using most of what is contained in it (docs, language
> > drivers, etc). Is there a smaller "bare essentials" MSI installer that
> > provides an easy interface for setting things like the admin password
> > and the non-privileged service user addition but that contains only
> > the required EXEs and DLLs? Or perhaps a way for me to take the MSI
> > installer and strip out the things I won't be needing?
>


--
- Mitchell Vincent
- K Software - Innovative Software Solutions
- Visit our website and check out our great software!
- http://www.ksoftware.net

Re: The leanest, meanest Windows installer possible

От
Magnus Hagander
Дата:
Mitchell Vincent wrote:
> Now that I think of it, shouldn't everything that is needed to build
> the .MSI installer be in one of the source packages? As a user of
> InnoSetup I'm afraid I'm clueless about MSI, so if someone could shove
> me in the right direction I'd sure appreciate it!

All that's needed is certainly in the pginstaller package. Or rather,
it's either there or in one of the packages referenced by the
documentation for that one (we don't actually ship a "source package").

You can find the source for the installer on
http://pgfoundry.org/projects/pginstaller.

//Magnus

Re: The leanest, meanest Windows installer possible

От
Magnus Hagander
Дата:
Mitchell Vincent wrote:
> Ah, I see what you mean.
>
> I was hoping to be able to rebuild the MSI to not include the things I
> didn't need but that doesn't look like it's going to be the case....
> Humbug.. Is there any way at all to modify what's contained in the MSI
> file so I can shrink the distribution size of the windows installer
> package?

Yes, you need to modify the wxs/pginst.wxs file - it lists what's
included in the package.

//Magnus

Re: The leanest, meanest Windows installer possible

От
Tony Caduto
Дата:
Mitchell Vincent wrote:
>
> I've been using PG for years and years but bringing it to the Win32
> desktop presents some deployment challenges. Since this software will
> be downloaded I am looking for the smallest possible installer that
> provides the functionality I'm looking for.
>
Hi Mitchell,

I created a slick installer to do just what you want with Inno setup.
Nice and easy to use with no MSI/WIX dependencies or complexities.
Get it here, full source included with a BSD license for the parts I wrote.
www.amsoftwaredesign.com/downloads/pg_installer_setup.zip

It's only been tested with 8.1, but should work just fine with 8.2.

This program is AS IS..with no support from AM Software.

Inno Setup is available from here for free:
http://www.jrsoftware.org/isinfo.php

I can't remember exactly, but I think this one comes in at around 8mb.

--
Tony Caduto
AM Software Design
Home of Lightning Admin for PostgreSQL and MySQL
http://www.amsoftwaredesign.com


Re: The leanest, meanest Windows installer possible

От
"Mitchell Vincent"
Дата:
On Jul 29, 2007 2:51 PM, Magnus Hagander <magnus@hagander.net> wrote:
> Mitchell Vincent wrote:
> > Ah, I see what you mean.
> >
> > I was hoping to be able to rebuild the MSI to not include the things I
> > didn't need but that doesn't look like it's going to be the case....
> > Humbug.. Is there any way at all to modify what's contained in the MSI
> > file so I can shrink the distribution size of the windows installer
> > package?
>
> Yes, you need to modify the wxs/pginst.wxs file - it lists what's
> included in the package.
>
> //Magnus

Hello Magnus, I had to back-burner this for a few months but I'm back
at it. Can you tell me where to find the wxs/pginst.wxs file and what
tools I'll need to rebuild the installer?

Thanks!

--
- Mitchell Vincent
- K Software - Innovative Software Solutions
- Visit our website and check out our great software!
- http://www.ksoftware.net

Re: The leanest, meanest Windows installer possible

От
Magnus Hagander
Дата:
Mitchell Vincent wrote:
> On Jul 29, 2007 2:51 PM, Magnus Hagander <magnus@hagander.net> wrote:
>> Mitchell Vincent wrote:
>>> Ah, I see what you mean.
>>>
>>> I was hoping to be able to rebuild the MSI to not include the things I
>>> didn't need but that doesn't look like it's going to be the case....
>>> Humbug.. Is there any way at all to modify what's contained in the MSI
>>> file so I can shrink the distribution size of the windows installer
>>> package?
>> Yes, you need to modify the wxs/pginst.wxs file - it lists what's
>> included in the package.
>>
>> //Magnus
>
> Hello Magnus, I had to back-burner this for a few months but I'm back
> at it. Can you tell me where to find the wxs/pginst.wxs file and what
> tools I'll need to rebuild the installer?

http://pgfoundry.org/projects/pginstaller

There should be READMEs explaning what you need. They do require some
insight and some pokeing around (e.g. not entirely sure the
step-by-steps work), but should be fairly straightforward. Make sure you
look at CVS HEAD - it's simpler than 8.2 and previous.

//Magnus