[wpkg-users] Silent installer for adobe_falsh_player_10_active_x

Rainer Meier r.meier at wpkg.org
Wed Oct 22 22:43:52 CEST 2008


Hi Dejan,


Dejan Batic wrote:
> I’m trying to put the new version of Flash Player. The command I found
> is in the list of Silent Installers but for some reason it does not
> work. If I try to execute
> 
> msiexec /q /i install_flash_player_10_active_x.msi
> 
> it has no problem installing.

OK


> *-* <install cmd="*msiexec /q /i
> \\myserver\wpkg\software\Flash\install_flash_player_10_active_x.msi*">

> 2008-10-23 02:11:04, DEBUG  : Executing command : msiexec /q /i
> \\Mrksywalker\wpkg\software\Flash\install_flash_player_10_active_x.msi
> 
> 2008-10-23 02:11:18, ERROR  : Could not process (install) package 'Adobe
> Flash Player 10 for Internet Explorer' (flash-ie):|Exit code returned
> non-successful value (1620) on command 'msiexec /q /i

Exit code 1620 stands for
"This installation package could not be opened. Contact the application
vendor to verify that this is a valid Windows Installer package"

Is it possible that your MSI file on the server is somehow corrupt?

This active-x installer is somehow crazy anyway. Adobe does not provide
it to unregistered users for download. Only the web-installer is
provided on the web page.
Personally I managed to download an exe installer from somewhere. So I
am using the following package:

FlashPlayerActiveX.xml:
<?xml version="1.0" encoding="utf-8" ?>
<packages>

<package id='FlashPlayerActiveX' name='Flash Player for Internet
Explorer' revision='1001236' priority='50' reboot='false' >
  <!-- Active-X Plug-in for Internet Explorer -->
  <check type='uninstall' condition='exists' path='Adobe Flash Player 10
ActiveX' />
  <install cmd='"%SOFTWARE%\Flash Player Active-X
v.10.0.12.36\unattended.cmd"' >
    <exit code='3010' reboot='true' />
  </install>
  <remove cmd='"%SOFTWARE%\Flash Player Active-X
v.10.0.12.36\unattended-uninstall.cmd"' />
  <upgrade cmd='"%SOFTWARE%\Flash Player Active-X
v.10.0.12.36\unattended.cmd"' >
    <exit code='3010' reboot='true' />
  </upgrade>
</package>

</packages>



Also this one uses my generic install/uninstall scripts.


unattended.cmd:
@echo off

set CMD32=install_flash_player_10_active_x.exe
set CMD64=%CMD32%

echo Installing Flash Player

set INSTALLER_LOC=%~dp0
set INSTALLER=install.cmd

call "%INSTALLER_LOC%%INSTALLER%" nsis "%CMD32%" "%CMD64%"


unattended-uninstall.cmd
@echo off

echo Removing FlashPlayer

set SYSDIR32=%SystemRoot%\system32
if not "%ProgramFiles(x86)%" == "" set SYSDIR32=%SystemRoot%\SysWOW64

start /wait "Flash Player"
"%SYSDIR32%\Macromed\Flash\uninstall_activeX.exe" /S



install.cmd:
@echo off

REM Usage:
REM msiinstall.cmd <type> <32-bit-installer> <64-bit-installer>
[installer-location [custom-options]]
REM where type is one of
REM     msiinstall     Install the given MSI package
REM     msiuninstall   Uninstall the given MSI package
REM     innosetup      Inno setup
REM     installshield  Install shield
REM     nsis           Nullsoft install system (NSIS)
REM     custom         Custom installer - options required in this case
REM 32-bit-installer   Full file name (including extension) of 32-bit
installer
REM 64-bit-installer   Full file name (including extension) of 64-bit
installer
REM installer-location Path where the installers are stored, if empty
assumes directory where install.cmd is
REM custom-options     Replace the default installer options with the
ones given

REM Global variables
set INSTALL_CMD=
set EXIT_CODE=0

REM Get command type
set TYPE=%~1

REM Get 32-bit installer name
set CMD32=%~2

REM Get 64-bit installer name
set CMD64=%~3

REM get file path
set INSTALLER_PATH=%~dp0
if not "%~4" == "" (
set INSTALLER_PATH=%~4
)

set OPTIONS=
if not "%~5" == "" (
set OPTIONS=%~5
)


REM Detect which system is used
if not "%ProgramFiles(x86)%" == "" goto 64bit
goto 32bit


REM
##########################################################################
REM 64-bit system detected
REM
##########################################################################
:64bit
REM Determine 64-bit installer to be used
echo 64-bit system detected.
REM set INSTALLER64=
if not "%CMD64%" == "" (
set INSTALLER64=%CMD64%
) else (
REM Use 32-bit installer if available, no 64-bit installer available.
if not "%CMD32%" == "" (
echo Using 32-bit installer, no 64-bit installer specified.
set INSTALLER64=%CMD32%
) else (
echo Neither 64-bit nor 32-bit installer specified. Exiting.
goto usage
)
)

REM Check if installer is valid
if exist "%INSTALLER_PATH%%INSTALLER64%" (
set INSTALL_CMD=%INSTALLER_PATH%%INSTALLER64%
) else (
echo Installer "%INSTALLER_PATH%%INSTALLER64%" cannot be found! Exiting.
exit /B 97
)
goto installerselection


REM
##########################################################################
REM 32-bit system detected
REM
##########################################################################
:32bit
REM Determine 32-bit installer to be used
echo 32-bit system detected.
set INSTALLER32=
if not "%CMD32%" == "" (
set INSTALLER32=%CMD32%
) else (
echo No 32-bit installer specified. Exiting.
exit /B 96
)


REM Check if installer is valid
if exist "%INSTALLER_PATH%%INSTALLER32%" (
set INSTALL_CMD=%INSTALLER_PATH%%INSTALLER32%
) else (
echo Installer "%INSTALLER_PATH%%INSTALLER32%" cannot be found! Exiting.
exit /B 95
)
goto installerselection



REM
##########################################################################
REM select installer system
REM
##########################################################################
:installerselection
if /i "%TYPE%" == "msiinstall"    goto msiinstaller
if /i "%TYPE%" == "msiuninstall"  goto msiuninstaller
if /i "%TYPE%" == "innosetup"     goto innoinstaller
if /i "%TYPE%" == "installshield" goto installshieldinstaller
if /i "%TYPE%" == "nsis"          goto nsisinstaller
if /i "%TYPE%" == "custom"        goto custominstaller
goto usage



:msiinstaller
echo Installing "%INSTALL_CMD%"
if "%OPTIONS%" == "" (
set OPTIONS=/qn /norestart
)
start /wait "Software installation" msiexec /i "%INSTALL_CMD%" %OPTIONS%
set EXIT_CODE=%ERRORLEVEL%
goto end


:msiuninstaller
echo Uninstalling "%INSTALL_CMD%"
if "%OPTIONS%" == "" (
set OPTIONS=/qn /norestart
)
start /wait "Software uninstallation" msiexec /x "%INSTALL_CMD%" %OPTIONS%
set EXIT_CODE=%ERRORLEVEL%
goto end


:innoinstaller
echo Installing "%INSTALL_CMD%"
REM if "%OPTIONS%" == "" (
REM set OPTIONS=/verysilent /norestart /sp-
REM )
start /wait "Software installation" "%INSTALL_CMD%" /verysilent
/norestart /sp- %OPTIONS%
set EXIT_CODE=%ERRORLEVEL%
goto end


:installshieldinstaller
echo Installing "%INSTALL_CMD%"
start /wait "Software installation" "%INSTALL_CMD%" /s %OPTIONS%
set EXIT_CODE=%ERRORLEVEL%
goto end


:nsisinstaller
echo Installing "%INSTALL_CMD%"
start /wait "Software installation" "%INSTALL_CMD%" /S %OPTIONS%
set EXIT_CODE=%ERRORLEVEL%
goto end

:custominstaller
if "%OPTIONS%" == "" goto usage
echo Installing "%INSTALL_CMD%"
start /wait "Software installation" "%INSTALL_CMD%" %OPTIONS%
set EXIT_CODE=%ERRORLEEL%
goto end

:usage
echo Usage:
echo "%~nx0 <type> <32-bit-installer> <64-bit-installer>
[installer-location [custom-options]]"
echo where type is one of
echo     msiinstall        Install the given MSI package
echo     msiuninstall      Uninstall the given MSI package
echo     innosetup         Inno setup
echo     installshield     Install shield
echo     nsis              Nullsoft install system (NSIS)
echo     custom            Custom installer - options required in this case
echo 32-bit-installer      Full file name (including extension) of
32-bit installer
echo 64-bit-installer      Full file name (including extension) of
64-bit installer
echo installer-location    Path where the installers are stored
echo custom-options        Replace the default installer options with
the ones given
exit /B 99

:end
exit /B %EXIT_CODE%

=====

Works absolutely fine for me.

br,
Rainer



More information about the wpkg-users mailing list