2003-08-13 03:27:48 +02:00
|
|
|
/*
|
|
|
|
* Implementation of the Microsoft Installer (msi.dll)
|
|
|
|
*
|
2005-01-28 13:39:57 +01:00
|
|
|
* Copyright 2002-2005 Mike McCormack for CodeWeavers
|
2006-10-10 13:03:52 +02:00
|
|
|
* Copyright 2005 Aric Stewart for CodeWeavers
|
2003-08-13 03:27:48 +02:00
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
2006-05-18 14:49:52 +02:00
|
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
2003-08-13 03:27:48 +02:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __WINE_MSI_PRIVATE__
|
|
|
|
#define __WINE_MSI_PRIVATE__
|
|
|
|
|
2003-09-06 01:08:26 +02:00
|
|
|
#include <stdarg.h>
|
|
|
|
|
|
|
|
#include "windef.h"
|
|
|
|
#include "winbase.h"
|
2008-04-30 11:22:46 +02:00
|
|
|
#include "fdi.h"
|
2003-08-13 03:27:48 +02:00
|
|
|
#include "msi.h"
|
|
|
|
#include "msiquery.h"
|
2010-10-06 15:45:05 +02:00
|
|
|
#include "msidefs.h"
|
2004-08-22 23:38:46 +02:00
|
|
|
#include "objbase.h"
|
2003-08-13 03:27:48 +02:00
|
|
|
#include "objidl.h"
|
2010-11-11 10:45:42 +01:00
|
|
|
#include "fusion.h"
|
2005-06-01 13:02:19 +02:00
|
|
|
#include "winnls.h"
|
2010-06-11 15:19:15 +02:00
|
|
|
#include "winver.h"
|
2005-05-23 14:08:17 +02:00
|
|
|
#include "wine/list.h"
|
2008-08-25 07:06:09 +02:00
|
|
|
#include "wine/debug.h"
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2018-04-16 03:52:09 +02:00
|
|
|
#include "msiserver.h"
|
2018-04-18 02:11:29 +02:00
|
|
|
#include "winemsi.h"
|
2018-04-16 03:52:09 +02:00
|
|
|
|
2010-10-13 14:23:25 +02:00
|
|
|
static const BOOL is_64bit = sizeof(void *) > sizeof(int);
|
2015-03-24 11:43:18 +01:00
|
|
|
BOOL is_wow64 DECLSPEC_HIDDEN;
|
2010-10-13 14:23:25 +02:00
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
#define MSI_DATASIZEMASK 0x00ff
|
|
|
|
#define MSITYPE_VALID 0x0100
|
2005-09-28 13:59:40 +02:00
|
|
|
#define MSITYPE_LOCALIZABLE 0x200
|
2003-08-13 03:27:48 +02:00
|
|
|
#define MSITYPE_STRING 0x0800
|
|
|
|
#define MSITYPE_NULLABLE 0x1000
|
|
|
|
#define MSITYPE_KEY 0x2000
|
2007-07-21 03:41:16 +02:00
|
|
|
#define MSITYPE_TEMPORARY 0x4000
|
2011-12-23 13:54:26 +01:00
|
|
|
#define MSITYPE_UNKNOWN 0x8000
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2010-07-21 09:47:39 +02:00
|
|
|
#define MAX_STREAM_NAME_LEN 62
|
2010-10-11 12:09:45 +02:00
|
|
|
#define LONG_STR_BYTES 3
|
2006-08-07 20:37:49 +02:00
|
|
|
|
2007-02-07 06:53:24 +01:00
|
|
|
/* Install UI level mask for AND operation to exclude flags */
|
|
|
|
#define INSTALLUILEVEL_MASK 0x0007
|
|
|
|
|
2005-09-28 13:59:40 +02:00
|
|
|
#define MSITYPE_IS_BINARY(type) (((type) & ~MSITYPE_NULLABLE) == (MSITYPE_STRING|MSITYPE_VALID))
|
2004-06-29 05:44:01 +02:00
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
struct tagMSITABLE;
|
|
|
|
typedef struct tagMSITABLE MSITABLE;
|
|
|
|
|
2004-03-17 21:49:59 +01:00
|
|
|
struct string_table;
|
|
|
|
typedef struct string_table string_table;
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
struct tagMSIOBJECTHDR;
|
|
|
|
typedef struct tagMSIOBJECTHDR MSIOBJECTHDR;
|
|
|
|
|
|
|
|
typedef VOID (*msihandledestructor)( MSIOBJECTHDR * );
|
|
|
|
|
|
|
|
struct tagMSIOBJECTHDR
|
|
|
|
{
|
|
|
|
UINT magic;
|
|
|
|
UINT type;
|
2005-07-06 12:33:30 +02:00
|
|
|
LONG refcount;
|
2004-07-10 00:25:34 +02:00
|
|
|
msihandledestructor destructor;
|
|
|
|
};
|
|
|
|
|
2011-03-22 20:45:09 +01:00
|
|
|
#define MSI_INITIAL_MEDIA_TRANSFORM_OFFSET 10000
|
2018-11-20 13:42:22 +01:00
|
|
|
#define MSI_INITIAL_MEDIA_TRANSFORM_DISKID 32000
|
2011-03-22 20:45:09 +01:00
|
|
|
|
2015-02-13 13:39:38 +01:00
|
|
|
typedef struct tagMSISTREAM
|
|
|
|
{
|
|
|
|
UINT str_index;
|
|
|
|
IStream *stream;
|
|
|
|
} MSISTREAM;
|
|
|
|
|
|
|
|
typedef struct tagMSITRANSFORM
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
IStorage *stg;
|
|
|
|
} MSITRANSFORM;
|
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
typedef struct tagMSIDATABASE
|
|
|
|
{
|
2004-07-10 00:25:34 +02:00
|
|
|
MSIOBJECTHDR hdr;
|
2003-08-13 03:27:48 +02:00
|
|
|
IStorage *storage;
|
2004-03-17 21:49:59 +01:00
|
|
|
string_table *strings;
|
2007-06-08 01:41:51 +02:00
|
|
|
UINT bytes_per_strref;
|
2006-09-26 05:03:31 +02:00
|
|
|
LPWSTR path;
|
2006-09-12 17:47:10 +02:00
|
|
|
LPWSTR deletefile;
|
2015-04-01 12:33:11 +02:00
|
|
|
LPWSTR tempfolder;
|
2005-05-31 11:30:28 +02:00
|
|
|
LPCWSTR mode;
|
2011-03-22 20:45:09 +01:00
|
|
|
UINT media_transform_offset;
|
2011-04-14 14:42:48 +02:00
|
|
|
UINT media_transform_disk_id;
|
2005-09-14 12:07:26 +02:00
|
|
|
struct list tables;
|
2005-10-27 14:25:04 +02:00
|
|
|
struct list transforms;
|
2015-02-13 13:39:38 +01:00
|
|
|
MSISTREAM *streams;
|
|
|
|
UINT num_streams;
|
|
|
|
UINT num_streams_allocated;
|
2003-08-13 03:27:48 +02:00
|
|
|
} MSIDATABASE;
|
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
typedef struct tagMSIVIEW MSIVIEW;
|
|
|
|
|
|
|
|
typedef struct tagMSIQUERY
|
|
|
|
{
|
|
|
|
MSIOBJECTHDR hdr;
|
|
|
|
MSIVIEW *view;
|
|
|
|
UINT row;
|
|
|
|
MSIDATABASE *db;
|
2005-05-23 14:08:17 +02:00
|
|
|
struct list mem;
|
2004-07-10 00:25:34 +02:00
|
|
|
} MSIQUERY;
|
|
|
|
|
|
|
|
/* maybe we can use a Variant instead of doing it ourselves? */
|
|
|
|
typedef struct tagMSIFIELD
|
|
|
|
{
|
|
|
|
UINT type;
|
|
|
|
union
|
|
|
|
{
|
|
|
|
INT iVal;
|
|
|
|
LPWSTR szwVal;
|
|
|
|
IStream *stream;
|
|
|
|
} u;
|
2012-10-29 12:13:12 +01:00
|
|
|
int len;
|
2004-07-10 00:25:34 +02:00
|
|
|
} MSIFIELD;
|
|
|
|
|
|
|
|
typedef struct tagMSIRECORD
|
|
|
|
{
|
|
|
|
MSIOBJECTHDR hdr;
|
|
|
|
UINT count; /* as passed to MsiCreateRecord */
|
2018-10-12 16:44:03 +02:00
|
|
|
UINT64 cookie;
|
2004-07-10 00:25:34 +02:00
|
|
|
MSIFIELD fields[1]; /* nb. array size is count+1 */
|
|
|
|
} MSIRECORD;
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2007-07-03 05:20:20 +02:00
|
|
|
typedef struct tagMSISOURCELISTINFO
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
DWORD context;
|
|
|
|
DWORD options;
|
|
|
|
LPCWSTR property;
|
|
|
|
LPWSTR value;
|
|
|
|
} MSISOURCELISTINFO;
|
|
|
|
|
|
|
|
typedef struct tagMSIMEDIADISK
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
DWORD context;
|
|
|
|
DWORD options;
|
|
|
|
DWORD disk_id;
|
|
|
|
LPWSTR volume_label;
|
|
|
|
LPWSTR disk_prompt;
|
|
|
|
} MSIMEDIADISK;
|
|
|
|
|
2008-04-30 11:22:46 +02:00
|
|
|
typedef struct tagMSIMEDIAINFO
|
|
|
|
{
|
|
|
|
UINT disk_id;
|
|
|
|
UINT type;
|
|
|
|
UINT last_sequence;
|
|
|
|
LPWSTR disk_prompt;
|
|
|
|
LPWSTR cabinet;
|
|
|
|
LPWSTR volume_label;
|
2019-01-07 08:55:15 +01:00
|
|
|
LPWSTR last_volume;
|
2008-04-30 11:22:46 +02:00
|
|
|
BOOL is_continuous;
|
|
|
|
BOOL is_extracted;
|
2010-03-26 12:12:15 +01:00
|
|
|
WCHAR sourcedir[MAX_PATH];
|
2008-04-30 11:22:46 +02:00
|
|
|
} MSIMEDIAINFO;
|
|
|
|
|
2011-04-14 14:41:19 +02:00
|
|
|
typedef struct tagMSICABINETSTREAM
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
UINT disk_id;
|
|
|
|
IStorage *storage;
|
|
|
|
WCHAR *stream;
|
|
|
|
} MSICABINETSTREAM;
|
|
|
|
|
2008-12-15 04:07:23 +01:00
|
|
|
typedef struct tagMSIPATCHINFO
|
|
|
|
{
|
2010-04-29 09:39:22 +02:00
|
|
|
struct list entry;
|
2008-12-15 04:07:23 +01:00
|
|
|
LPWSTR patchcode;
|
2011-08-23 14:42:03 +02:00
|
|
|
LPWSTR products;
|
2008-12-15 04:07:23 +01:00
|
|
|
LPWSTR transforms;
|
2011-06-30 12:15:37 +02:00
|
|
|
LPWSTR filename;
|
2010-05-04 09:06:42 +02:00
|
|
|
LPWSTR localfile;
|
2010-07-20 14:54:34 +02:00
|
|
|
MSIPATCHSTATE state;
|
2017-04-19 11:26:49 +02:00
|
|
|
DWORD uninstallable;
|
2011-08-23 14:42:03 +02:00
|
|
|
BOOL delete_on_close;
|
2015-04-10 12:58:26 +02:00
|
|
|
BOOL registered;
|
2015-03-04 14:30:42 +01:00
|
|
|
UINT disk_id;
|
2008-12-15 04:07:23 +01:00
|
|
|
} MSIPATCHINFO;
|
|
|
|
|
2010-12-02 11:32:26 +01:00
|
|
|
typedef struct tagMSIBINARY
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
WCHAR *source;
|
|
|
|
WCHAR *tmpfile;
|
|
|
|
} MSIBINARY;
|
|
|
|
|
2007-12-18 02:35:31 +01:00
|
|
|
typedef struct _column_info
|
|
|
|
{
|
|
|
|
LPCWSTR table;
|
|
|
|
LPCWSTR column;
|
|
|
|
INT type;
|
|
|
|
BOOL temporary;
|
|
|
|
struct expr *val;
|
|
|
|
struct _column_info *next;
|
|
|
|
} column_info;
|
|
|
|
|
2006-11-06 13:02:47 +01:00
|
|
|
typedef const struct tagMSICOLUMNHASHENTRY *MSIITERHANDLE;
|
2006-03-18 17:12:15 +01:00
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
typedef struct tagMSIVIEWOPS
|
|
|
|
{
|
|
|
|
/*
|
|
|
|
* fetch_int - reads one integer from {row,col} in the table
|
|
|
|
*
|
|
|
|
* This function should be called after the execute method.
|
2006-10-10 13:03:52 +02:00
|
|
|
* Data returned by the function should not change until
|
2003-08-13 03:27:48 +02:00
|
|
|
* close or delete is called.
|
|
|
|
* To get a string value, query the database's string table with
|
|
|
|
* the integer value returned from this function.
|
|
|
|
*/
|
2007-06-16 19:05:32 +02:00
|
|
|
UINT (*fetch_int)( struct tagMSIVIEW *view, UINT row, UINT col, UINT *val );
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2004-07-06 20:56:12 +02:00
|
|
|
/*
|
2006-03-18 17:12:15 +01:00
|
|
|
* fetch_stream - gets a stream from {row,col} in the table
|
2004-07-06 20:56:12 +02:00
|
|
|
*
|
|
|
|
* This function is similar to fetch_int, except fetches a
|
|
|
|
* stream instead of an integer.
|
|
|
|
*/
|
2007-06-16 19:05:32 +02:00
|
|
|
UINT (*fetch_stream)( struct tagMSIVIEW *view, UINT row, UINT col, IStream **stm );
|
2004-07-06 20:56:12 +02:00
|
|
|
|
2019-01-26 23:58:58 +01:00
|
|
|
/*
|
|
|
|
* set_int - set the integer value at {row, col}
|
|
|
|
* This function has undefined behaviour if the column does not contain
|
|
|
|
* integers.
|
|
|
|
*/
|
|
|
|
UINT (*set_int)( struct tagMSIVIEW *view, UINT row, UINT col, int val );
|
|
|
|
|
|
|
|
/*
|
|
|
|
* set_string - set the string value at {row, col}
|
|
|
|
* This function has undefined behaviour if the column does not contain
|
|
|
|
* strings.
|
|
|
|
*/
|
|
|
|
UINT (*set_string)( struct tagMSIVIEW *view, UINT row, UINT col, const WCHAR *val, int len );
|
|
|
|
|
2019-01-29 05:11:08 +01:00
|
|
|
/*
|
|
|
|
* set_stream - set the stream value at {row, col}
|
|
|
|
* This function has undefined behaviour if the column does not contain
|
|
|
|
* streams.
|
|
|
|
*/
|
|
|
|
UINT (*set_stream)( struct tagMSIVIEW *view, UINT row, UINT col, IStream *stream );
|
|
|
|
|
2004-03-19 02:16:36 +01:00
|
|
|
/*
|
2006-10-26 10:09:47 +02:00
|
|
|
* set_row - sets values in a row as specified by mask
|
2004-03-19 02:16:36 +01:00
|
|
|
*
|
|
|
|
* Similar semantics to fetch_int
|
|
|
|
*/
|
2007-06-16 19:05:32 +02:00
|
|
|
UINT (*set_row)( struct tagMSIVIEW *view, UINT row, MSIRECORD *rec, UINT mask );
|
2004-03-19 02:16:36 +01:00
|
|
|
|
|
|
|
/*
|
2005-08-24 13:10:23 +02:00
|
|
|
* Inserts a new row into the database from the records contents
|
2004-03-19 02:16:36 +01:00
|
|
|
*/
|
2009-03-02 06:41:22 +01:00
|
|
|
UINT (*insert_row)( struct tagMSIVIEW *view, MSIRECORD *record, UINT row, BOOL temporary );
|
2004-03-19 02:16:36 +01:00
|
|
|
|
2007-06-18 22:49:31 +02:00
|
|
|
/*
|
|
|
|
* Deletes a row from the database
|
|
|
|
*/
|
|
|
|
UINT (*delete_row)( struct tagMSIVIEW *view, UINT row );
|
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
/*
|
|
|
|
* execute - loads the underlying data into memory so it can be read
|
|
|
|
*/
|
2007-06-16 19:05:32 +02:00
|
|
|
UINT (*execute)( struct tagMSIVIEW *view, MSIRECORD *record );
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* close - clears the data read by execute from memory
|
|
|
|
*/
|
2007-06-16 19:05:32 +02:00
|
|
|
UINT (*close)( struct tagMSIVIEW *view );
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* get_dimensions - returns the number of rows or columns in a table.
|
|
|
|
*
|
|
|
|
* The number of rows can only be queried after the execute method
|
|
|
|
* is called. The number of columns can be queried at any time.
|
|
|
|
*/
|
2007-06-16 19:05:32 +02:00
|
|
|
UINT (*get_dimensions)( struct tagMSIVIEW *view, UINT *rows, UINT *cols );
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* get_column_info - returns the name and type of a specific column
|
|
|
|
*
|
|
|
|
* The column information can be queried at any time.
|
|
|
|
*/
|
2011-07-27 10:53:10 +02:00
|
|
|
UINT (*get_column_info)( struct tagMSIVIEW *view, UINT n, LPCWSTR *name, UINT *type,
|
|
|
|
BOOL *temporary, LPCWSTR *table_name );
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* modify - not yet implemented properly
|
|
|
|
*/
|
2007-07-27 02:40:38 +02:00
|
|
|
UINT (*modify)( struct tagMSIVIEW *view, MSIMODIFY eModifyMode, MSIRECORD *record, UINT row );
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* delete - destroys the structure completely
|
|
|
|
*/
|
|
|
|
UINT (*delete)( struct tagMSIVIEW * );
|
|
|
|
|
2007-07-19 03:21:00 +02:00
|
|
|
/*
|
|
|
|
* add_ref - increases the reference count of the table
|
|
|
|
*/
|
|
|
|
UINT (*add_ref)( struct tagMSIVIEW *view );
|
|
|
|
|
|
|
|
/*
|
|
|
|
* release - decreases the reference count of the table
|
|
|
|
*/
|
|
|
|
UINT (*release)( struct tagMSIVIEW *view );
|
2007-07-20 23:01:13 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* add_column - adds a column to the table
|
|
|
|
*/
|
2007-07-21 03:41:16 +02:00
|
|
|
UINT (*add_column)( struct tagMSIVIEW *view, LPCWSTR table, UINT number, LPCWSTR column, UINT type, BOOL hold );
|
|
|
|
|
2007-12-18 02:35:31 +01:00
|
|
|
/*
|
|
|
|
* sort - orders the table by columns
|
|
|
|
*/
|
|
|
|
UINT (*sort)( struct tagMSIVIEW *view, column_info *columns );
|
2008-10-02 22:56:54 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* drop - drops the table from the database
|
|
|
|
*/
|
|
|
|
UINT (*drop)( struct tagMSIVIEW *view );
|
2003-08-13 03:27:48 +02:00
|
|
|
} MSIVIEWOPS;
|
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
struct tagMSIVIEW
|
2003-08-13 03:27:48 +02:00
|
|
|
{
|
2004-07-10 00:25:34 +02:00
|
|
|
MSIOBJECTHDR hdr;
|
2006-06-10 12:02:39 +02:00
|
|
|
const MSIVIEWOPS *ops;
|
2011-06-07 10:34:49 +02:00
|
|
|
MSIDBERROR error;
|
|
|
|
const WCHAR *error_column;
|
2004-07-10 00:25:34 +02:00
|
|
|
};
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2005-02-02 10:55:51 +01:00
|
|
|
struct msi_dialog_tag;
|
|
|
|
typedef struct msi_dialog_tag msi_dialog;
|
|
|
|
|
2010-09-17 15:20:26 +02:00
|
|
|
enum platform
|
|
|
|
{
|
2013-01-31 15:11:38 +01:00
|
|
|
PLATFORM_UNKNOWN,
|
2010-09-17 15:20:26 +02:00
|
|
|
PLATFORM_INTEL,
|
|
|
|
PLATFORM_INTEL64,
|
2012-03-18 19:26:50 +01:00
|
|
|
PLATFORM_X64,
|
2018-11-10 15:13:47 +01:00
|
|
|
PLATFORM_ARM,
|
|
|
|
PLATFORM_ARM64
|
2010-09-17 15:20:26 +02:00
|
|
|
};
|
|
|
|
|
2011-03-07 12:40:39 +01:00
|
|
|
enum clr_version
|
|
|
|
{
|
2011-05-06 14:40:33 +02:00
|
|
|
CLR_VERSION_V10,
|
2011-03-07 12:40:39 +01:00
|
|
|
CLR_VERSION_V11,
|
|
|
|
CLR_VERSION_V20,
|
2012-05-17 10:17:50 +02:00
|
|
|
CLR_VERSION_V40,
|
2011-03-07 12:40:39 +01:00
|
|
|
CLR_VERSION_MAX
|
|
|
|
};
|
|
|
|
|
2017-09-19 19:46:53 +02:00
|
|
|
enum script
|
|
|
|
{
|
|
|
|
SCRIPT_NONE = -1,
|
|
|
|
SCRIPT_INSTALL = 0,
|
|
|
|
SCRIPT_COMMIT = 1,
|
|
|
|
SCRIPT_ROLLBACK = 2,
|
|
|
|
SCRIPT_MAX = 3
|
|
|
|
};
|
|
|
|
|
2004-07-04 02:32:48 +02:00
|
|
|
typedef struct tagMSIPACKAGE
|
|
|
|
{
|
2004-07-10 00:25:34 +02:00
|
|
|
MSIOBJECTHDR hdr;
|
|
|
|
MSIDATABASE *db;
|
2010-10-06 15:44:08 +02:00
|
|
|
INT version;
|
2010-09-17 15:20:26 +02:00
|
|
|
enum platform platform;
|
|
|
|
UINT num_langids;
|
|
|
|
LANGID *langids;
|
2010-04-29 09:39:22 +02:00
|
|
|
struct list patches;
|
2005-08-22 11:15:23 +02:00
|
|
|
struct list components;
|
2005-08-22 16:09:17 +02:00
|
|
|
struct list features;
|
2005-08-23 12:03:17 +02:00
|
|
|
struct list files;
|
2011-03-22 20:45:11 +01:00
|
|
|
struct list filepatches;
|
2005-09-07 13:25:18 +02:00
|
|
|
struct list tempfiles;
|
2005-08-23 20:15:44 +02:00
|
|
|
struct list folders;
|
2010-12-02 11:32:26 +01:00
|
|
|
struct list binaries;
|
2011-04-14 14:41:19 +02:00
|
|
|
struct list cabinet_streams;
|
2004-12-22 16:05:07 +01:00
|
|
|
LPWSTR ActionFormat;
|
|
|
|
LPWSTR LastAction;
|
2017-07-10 20:46:40 +02:00
|
|
|
LPWSTR LastActionTemplate;
|
2017-07-07 16:03:14 +02:00
|
|
|
UINT LastActionResult;
|
2012-05-15 09:40:22 +02:00
|
|
|
UINT action_progress_increment;
|
2010-10-26 12:42:34 +02:00
|
|
|
HANDLE log_file;
|
2011-03-07 12:40:39 +01:00
|
|
|
IAssemblyCache *cache_net[CLR_VERSION_MAX];
|
2010-11-11 10:45:42 +01:00
|
|
|
IAssemblyCache *cache_sxs;
|
2005-01-19 20:07:40 +01:00
|
|
|
|
2005-08-25 12:22:32 +02:00
|
|
|
struct list classes;
|
2005-08-29 11:38:39 +02:00
|
|
|
struct list extensions;
|
2005-09-06 11:26:18 +02:00
|
|
|
struct list progids;
|
2005-08-26 10:47:31 +02:00
|
|
|
struct list mimes;
|
2005-08-24 11:45:18 +02:00
|
|
|
struct list appids;
|
2006-08-25 10:54:29 +02:00
|
|
|
|
2018-06-06 07:59:22 +02:00
|
|
|
enum script script;
|
2017-09-19 19:46:53 +02:00
|
|
|
LPWSTR *script_actions[SCRIPT_MAX];
|
|
|
|
int script_actions_count[SCRIPT_MAX];
|
|
|
|
LPWSTR *unique_actions;
|
|
|
|
int unique_actions_count;
|
|
|
|
BOOL ExecuteSequenceRun;
|
|
|
|
UINT InWhatSequence;
|
2005-01-19 20:07:40 +01:00
|
|
|
|
2005-09-08 14:42:07 +02:00
|
|
|
struct list RunningActions;
|
2005-01-25 21:17:09 +01:00
|
|
|
|
2018-07-10 12:08:47 +02:00
|
|
|
HANDLE custom_server_32_process;
|
|
|
|
HANDLE custom_server_64_process;
|
|
|
|
HANDLE custom_server_32_pipe;
|
|
|
|
HANDLE custom_server_64_pipe;
|
|
|
|
|
2005-01-19 20:07:40 +01:00
|
|
|
LPWSTR PackagePath;
|
2005-07-05 23:00:06 +02:00
|
|
|
LPWSTR ProductCode;
|
2011-06-30 12:15:37 +02:00
|
|
|
LPWSTR localfile;
|
2011-08-23 14:41:43 +02:00
|
|
|
BOOL delete_on_close;
|
2005-01-27 12:12:56 +01:00
|
|
|
|
2012-04-05 15:12:15 +02:00
|
|
|
INSTALLUILEVEL ui_level;
|
2005-02-02 10:55:51 +01:00
|
|
|
msi_dialog *dialog;
|
|
|
|
LPWSTR next_dialog;
|
2006-08-31 22:43:01 +02:00
|
|
|
float center_x;
|
|
|
|
float center_y;
|
2006-08-07 20:37:49 +02:00
|
|
|
|
|
|
|
UINT WordCount;
|
2008-04-05 07:10:02 +02:00
|
|
|
UINT Context;
|
2006-08-25 10:54:29 +02:00
|
|
|
|
2005-06-06 17:40:15 +02:00
|
|
|
struct list subscriptions;
|
2007-06-25 21:47:38 +02:00
|
|
|
|
2007-07-03 05:20:20 +02:00
|
|
|
struct list sourcelist_info;
|
|
|
|
struct list sourcelist_media;
|
|
|
|
|
2018-01-04 12:58:43 +01:00
|
|
|
unsigned char scheduled_action_running : 1;
|
|
|
|
unsigned char commit_action_running : 1;
|
|
|
|
unsigned char rollback_action_running : 1;
|
2012-04-02 13:15:16 +02:00
|
|
|
unsigned char need_reboot_at_end : 1;
|
2012-04-02 13:15:56 +02:00
|
|
|
unsigned char need_reboot_now : 1;
|
2011-05-24 10:50:28 +02:00
|
|
|
unsigned char need_rollback : 1;
|
2018-07-10 12:08:44 +02:00
|
|
|
unsigned char rpc_server_started : 1;
|
2004-07-04 02:32:48 +02:00
|
|
|
} MSIPACKAGE;
|
|
|
|
|
2005-01-21 11:17:01 +01:00
|
|
|
typedef struct tagMSIPREVIEW
|
|
|
|
{
|
|
|
|
MSIOBJECTHDR hdr;
|
2005-01-28 13:39:57 +01:00
|
|
|
MSIPACKAGE *package;
|
2005-02-02 10:55:51 +01:00
|
|
|
msi_dialog *dialog;
|
2005-01-21 11:17:01 +01:00
|
|
|
} MSIPREVIEW;
|
|
|
|
|
2005-10-26 12:10:50 +02:00
|
|
|
#define MSI_MAX_PROPS 20
|
|
|
|
|
|
|
|
typedef struct tagMSISUMMARYINFO
|
|
|
|
{
|
|
|
|
MSIOBJECTHDR hdr;
|
2006-10-23 18:11:30 +02:00
|
|
|
IStorage *storage;
|
2005-10-26 12:10:50 +02:00
|
|
|
DWORD update_count;
|
|
|
|
PROPVARIANT property[MSI_MAX_PROPS];
|
|
|
|
} MSISUMMARYINFO;
|
|
|
|
|
2006-10-10 13:03:52 +02:00
|
|
|
typedef struct tagMSIFEATURE
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR Feature;
|
|
|
|
LPWSTR Feature_Parent;
|
|
|
|
LPWSTR Title;
|
|
|
|
LPWSTR Description;
|
|
|
|
INT Display;
|
|
|
|
INT Level;
|
|
|
|
LPWSTR Directory;
|
|
|
|
INT Attributes;
|
|
|
|
INSTALLSTATE Installed;
|
|
|
|
INSTALLSTATE ActionRequest;
|
|
|
|
INSTALLSTATE Action;
|
|
|
|
struct list Children;
|
|
|
|
struct list Components;
|
|
|
|
} MSIFEATURE;
|
|
|
|
|
2010-11-11 10:45:42 +01:00
|
|
|
typedef struct tagMSIASSEMBLY
|
|
|
|
{
|
|
|
|
LPWSTR feature;
|
|
|
|
LPWSTR manifest;
|
|
|
|
LPWSTR application;
|
|
|
|
DWORD attributes;
|
|
|
|
LPWSTR display_name;
|
|
|
|
LPWSTR tempdir;
|
|
|
|
BOOL installed;
|
2011-03-07 12:40:39 +01:00
|
|
|
BOOL clr_version[CLR_VERSION_MAX];
|
2010-11-11 10:45:42 +01:00
|
|
|
} MSIASSEMBLY;
|
|
|
|
|
2006-10-10 13:03:52 +02:00
|
|
|
typedef struct tagMSICOMPONENT
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR Component;
|
|
|
|
LPWSTR ComponentId;
|
|
|
|
LPWSTR Directory;
|
|
|
|
INT Attributes;
|
|
|
|
LPWSTR Condition;
|
|
|
|
LPWSTR KeyPath;
|
|
|
|
INSTALLSTATE Installed;
|
|
|
|
INSTALLSTATE ActionRequest;
|
|
|
|
INSTALLSTATE Action;
|
|
|
|
BOOL ForceLocalState;
|
|
|
|
BOOL Enabled;
|
|
|
|
INT Cost;
|
|
|
|
INT RefCount;
|
|
|
|
LPWSTR FullKeypath;
|
|
|
|
LPWSTR AdvertiseString;
|
2010-11-11 10:45:42 +01:00
|
|
|
MSIASSEMBLY *assembly;
|
2012-09-11 16:20:59 +02:00
|
|
|
int num_clients;
|
2006-12-05 10:24:39 +01:00
|
|
|
|
2007-11-01 09:12:41 +01:00
|
|
|
unsigned int anyAbsent:1;
|
2014-02-13 14:25:39 +01:00
|
|
|
unsigned int hasAdvertisedFeature:1;
|
2007-05-24 01:32:18 +02:00
|
|
|
unsigned int hasLocalFeature:1;
|
|
|
|
unsigned int hasSourceFeature:1;
|
2006-10-10 13:03:52 +02:00
|
|
|
} MSICOMPONENT;
|
|
|
|
|
|
|
|
typedef struct tagComponentList
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
MSICOMPONENT *component;
|
|
|
|
} ComponentList;
|
|
|
|
|
|
|
|
typedef struct tagFeatureList
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
MSIFEATURE *feature;
|
|
|
|
} FeatureList;
|
|
|
|
|
2011-06-30 12:14:07 +02:00
|
|
|
enum folder_state
|
|
|
|
{
|
|
|
|
FOLDER_STATE_UNINITIALIZED,
|
|
|
|
FOLDER_STATE_EXISTS,
|
|
|
|
FOLDER_STATE_CREATED,
|
|
|
|
FOLDER_STATE_CREATED_PERSISTENT,
|
|
|
|
FOLDER_STATE_REMOVED
|
|
|
|
};
|
|
|
|
|
2006-10-10 13:03:52 +02:00
|
|
|
typedef struct tagMSIFOLDER
|
|
|
|
{
|
|
|
|
struct list entry;
|
2011-05-02 16:03:55 +02:00
|
|
|
struct list children;
|
2006-10-10 13:03:52 +02:00
|
|
|
LPWSTR Directory;
|
2006-11-22 07:13:12 +01:00
|
|
|
LPWSTR Parent;
|
2006-10-10 13:03:52 +02:00
|
|
|
LPWSTR TargetDefault;
|
|
|
|
LPWSTR SourceLongPath;
|
|
|
|
LPWSTR SourceShortPath;
|
|
|
|
LPWSTR ResolvedTarget;
|
|
|
|
LPWSTR ResolvedSource;
|
2011-06-30 12:14:07 +02:00
|
|
|
enum folder_state State;
|
2011-06-30 12:15:19 +02:00
|
|
|
BOOL persistent;
|
2006-10-10 13:03:52 +02:00
|
|
|
} MSIFOLDER;
|
|
|
|
|
2011-05-02 16:03:55 +02:00
|
|
|
typedef struct tagFolderList
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
MSIFOLDER *folder;
|
|
|
|
} FolderList;
|
|
|
|
|
2006-10-10 13:03:52 +02:00
|
|
|
typedef enum _msi_file_state {
|
|
|
|
msifs_invalid,
|
|
|
|
msifs_missing,
|
|
|
|
msifs_overwrite,
|
|
|
|
msifs_present,
|
|
|
|
msifs_installed,
|
|
|
|
msifs_skipped,
|
2011-03-08 10:09:01 +01:00
|
|
|
msifs_hashmatch
|
2006-10-10 13:03:52 +02:00
|
|
|
} msi_file_state;
|
|
|
|
|
|
|
|
typedef struct tagMSIFILE
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR File;
|
|
|
|
MSICOMPONENT *Component;
|
|
|
|
LPWSTR FileName;
|
|
|
|
LPWSTR ShortName;
|
|
|
|
LPWSTR LongName;
|
|
|
|
INT FileSize;
|
|
|
|
LPWSTR Version;
|
|
|
|
LPWSTR Language;
|
|
|
|
INT Attributes;
|
|
|
|
INT Sequence;
|
|
|
|
msi_file_state state;
|
|
|
|
LPWSTR TargetPath;
|
|
|
|
BOOL IsCompressed;
|
2007-11-26 01:01:19 +01:00
|
|
|
MSIFILEHASHINFO hash;
|
2010-05-12 14:18:15 +02:00
|
|
|
UINT disk_id;
|
2006-10-10 13:03:52 +02:00
|
|
|
} MSIFILE;
|
|
|
|
|
2011-03-22 20:45:11 +01:00
|
|
|
typedef struct tagMSIFILEPATCH
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
MSIFILE *File;
|
|
|
|
INT Sequence;
|
|
|
|
INT PatchSize;
|
|
|
|
INT Attributes;
|
2015-04-01 12:32:18 +02:00
|
|
|
BOOL extracted;
|
2015-04-01 12:25:27 +02:00
|
|
|
UINT disk_id;
|
2015-04-01 12:32:18 +02:00
|
|
|
WCHAR *path;
|
2011-03-22 20:45:11 +01:00
|
|
|
} MSIFILEPATCH;
|
|
|
|
|
2006-10-10 13:03:52 +02:00
|
|
|
typedef struct tagMSIAPPID
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR AppID; /* Primary key */
|
|
|
|
LPWSTR RemoteServerName;
|
|
|
|
LPWSTR LocalServer;
|
|
|
|
LPWSTR ServiceParameters;
|
|
|
|
LPWSTR DllSurrogate;
|
|
|
|
BOOL ActivateAtStorage;
|
|
|
|
BOOL RunAsInteractiveUser;
|
|
|
|
} MSIAPPID;
|
|
|
|
|
|
|
|
typedef struct tagMSIPROGID MSIPROGID;
|
|
|
|
|
|
|
|
typedef struct tagMSICLASS
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR clsid; /* Primary Key */
|
|
|
|
LPWSTR Context; /* Primary Key */
|
|
|
|
MSICOMPONENT *Component;
|
|
|
|
MSIPROGID *ProgID;
|
|
|
|
LPWSTR ProgIDText;
|
|
|
|
LPWSTR Description;
|
|
|
|
MSIAPPID *AppID;
|
|
|
|
LPWSTR FileTypeMask;
|
|
|
|
LPWSTR IconPath;
|
|
|
|
LPWSTR DefInprocHandler;
|
|
|
|
LPWSTR DefInprocHandler32;
|
|
|
|
LPWSTR Argument;
|
|
|
|
MSIFEATURE *Feature;
|
|
|
|
INT Attributes;
|
|
|
|
/* not in the table, set during installation */
|
2014-02-27 11:01:41 +01:00
|
|
|
INSTALLSTATE action;
|
2006-10-10 13:03:52 +02:00
|
|
|
} MSICLASS;
|
|
|
|
|
|
|
|
typedef struct tagMSIMIME MSIMIME;
|
|
|
|
|
|
|
|
typedef struct tagMSIEXTENSION
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR Extension; /* Primary Key */
|
|
|
|
MSICOMPONENT *Component;
|
|
|
|
MSIPROGID *ProgID;
|
|
|
|
LPWSTR ProgIDText;
|
|
|
|
MSIMIME *Mime;
|
|
|
|
MSIFEATURE *Feature;
|
|
|
|
/* not in the table, set during installation */
|
2014-02-27 11:01:41 +01:00
|
|
|
INSTALLSTATE action;
|
2006-10-10 13:03:52 +02:00
|
|
|
struct list verbs;
|
|
|
|
} MSIEXTENSION;
|
|
|
|
|
|
|
|
struct tagMSIPROGID
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR ProgID; /* Primary Key */
|
|
|
|
MSIPROGID *Parent;
|
|
|
|
MSICLASS *Class;
|
|
|
|
LPWSTR Description;
|
|
|
|
LPWSTR IconPath;
|
|
|
|
/* not in the table, set during installation */
|
|
|
|
MSIPROGID *CurVer;
|
|
|
|
MSIPROGID *VersionInd;
|
|
|
|
};
|
|
|
|
|
|
|
|
typedef struct tagMSIVERB
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR Verb;
|
|
|
|
INT Sequence;
|
|
|
|
LPWSTR Command;
|
|
|
|
LPWSTR Argument;
|
|
|
|
} MSIVERB;
|
|
|
|
|
|
|
|
struct tagMSIMIME
|
|
|
|
{
|
|
|
|
struct list entry;
|
|
|
|
LPWSTR ContentType; /* Primary Key */
|
|
|
|
MSIEXTENSION *Extension;
|
2010-04-29 09:38:08 +02:00
|
|
|
LPWSTR suffix;
|
2006-10-10 13:03:52 +02:00
|
|
|
LPWSTR clsid;
|
|
|
|
MSICLASS *Class;
|
|
|
|
};
|
|
|
|
|
|
|
|
#define SEQUENCE_UI 0x1
|
|
|
|
#define SEQUENCE_EXEC 0x2
|
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
#define MSIHANDLETYPE_ANY 0
|
|
|
|
#define MSIHANDLETYPE_DATABASE 1
|
|
|
|
#define MSIHANDLETYPE_SUMMARYINFO 2
|
|
|
|
#define MSIHANDLETYPE_VIEW 3
|
|
|
|
#define MSIHANDLETYPE_RECORD 4
|
2004-06-30 21:38:36 +02:00
|
|
|
#define MSIHANDLETYPE_PACKAGE 5
|
2005-01-21 11:17:01 +01:00
|
|
|
#define MSIHANDLETYPE_PREVIEW 6
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2010-08-18 11:22:37 +02:00
|
|
|
#define MSI_MAJORVERSION 4
|
|
|
|
#define MSI_MINORVERSION 5
|
|
|
|
#define MSI_BUILDNUMBER 6001
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
#define GUID_SIZE 39
|
2016-11-04 13:28:07 +01:00
|
|
|
#define SQUASHED_GUID_SIZE 33
|
2003-08-13 03:27:48 +02:00
|
|
|
|
|
|
|
#define MSIHANDLE_MAGIC 0x4d434923
|
|
|
|
|
2005-10-31 15:07:37 +01:00
|
|
|
/* handle unicode/ascii output in the Msi* API functions */
|
2005-09-06 13:05:35 +02:00
|
|
|
typedef struct {
|
|
|
|
BOOL unicode;
|
|
|
|
union {
|
|
|
|
LPSTR a;
|
|
|
|
LPWSTR w;
|
|
|
|
} str;
|
|
|
|
} awstring;
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
BOOL unicode;
|
|
|
|
union {
|
|
|
|
LPCSTR a;
|
|
|
|
LPCWSTR w;
|
|
|
|
} str;
|
|
|
|
} awcstring;
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2012-10-29 12:16:42 +01:00
|
|
|
UINT msi_strcpy_to_awstring(const WCHAR *, int, awstring *, DWORD *) DECLSPEC_HIDDEN;
|
2005-10-31 15:07:37 +01:00
|
|
|
|
2007-02-08 09:20:55 +01:00
|
|
|
/* msi server interface */
|
2018-04-16 03:52:10 +02:00
|
|
|
extern MSIHANDLE msi_get_remote(MSIHANDLE handle) DECLSPEC_HIDDEN;
|
2018-09-08 03:17:22 +02:00
|
|
|
extern LONG WINAPI rpc_filter(EXCEPTION_POINTERS *eptr) DECLSPEC_HIDDEN;
|
2007-02-08 09:20:55 +01:00
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
/* handle functions */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void *msihandle2msiinfo(MSIHANDLE handle, UINT type) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIHANDLE alloc_msihandle( MSIOBJECTHDR * ) DECLSPEC_HIDDEN;
|
2018-04-16 03:52:10 +02:00
|
|
|
extern MSIHANDLE alloc_msi_remote_handle(MSIHANDLE remote) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void *alloc_msiobject(UINT type, UINT size, msihandledestructor destroy ) DECLSPEC_HIDDEN;
|
|
|
|
extern void msiobj_addref(MSIOBJECTHDR *) DECLSPEC_HIDDEN;
|
|
|
|
extern int msiobj_release(MSIOBJECTHDR *) DECLSPEC_HIDDEN;
|
|
|
|
extern void msiobj_lock(MSIOBJECTHDR *) DECLSPEC_HIDDEN;
|
|
|
|
extern void msiobj_unlock(MSIOBJECTHDR *) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_free_handle_table(void) DECLSPEC_HIDDEN;
|
2003-08-13 03:27:48 +02:00
|
|
|
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void free_cached_tables( MSIDATABASE *db ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_CommitTables( MSIDATABASE *db ) DECLSPEC_HIDDEN;
|
2015-02-13 13:39:38 +01:00
|
|
|
extern UINT msi_commit_streams( MSIDATABASE *db ) DECLSPEC_HIDDEN;
|
2004-03-18 05:04:08 +01:00
|
|
|
|
2004-03-17 21:49:59 +01:00
|
|
|
|
|
|
|
/* string table functions */
|
2019-01-24 07:07:32 +01:00
|
|
|
extern BOOL msi_add_string( string_table *st, const WCHAR *data, int len, BOOL persistent ) DECLSPEC_HIDDEN;
|
2012-10-29 12:12:50 +01:00
|
|
|
extern UINT msi_string2id( const string_table *st, const WCHAR *data, int len, UINT *id ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern VOID msi_destroy_stringtable( string_table *st ) DECLSPEC_HIDDEN;
|
2012-10-29 12:12:50 +01:00
|
|
|
extern const WCHAR *msi_string_lookup( const string_table *st, UINT id, int *len ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern HRESULT msi_init_string_table( IStorage *stg ) DECLSPEC_HIDDEN;
|
|
|
|
extern string_table *msi_load_string_table( IStorage *stg, UINT *bytes_per_strref ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_save_string_table( const string_table *st, IStorage *storage, UINT *bytes_per_strref ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_get_string_table_codepage( const string_table *st ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_set_string_table_codepage( string_table *st, UINT codepage ) DECLSPEC_HIDDEN;
|
2012-11-05 16:30:27 +01:00
|
|
|
extern WCHAR *msi_strdupW( const WCHAR *value, int len ) DECLSPEC_HIDDEN;
|
2004-06-26 02:11:08 +02:00
|
|
|
|
2011-04-21 11:03:25 +02:00
|
|
|
extern BOOL TABLE_Exists( MSIDATABASE *db, LPCWSTR name ) DECLSPEC_HIDDEN;
|
|
|
|
extern MSICONDITION MSI_DatabaseIsTablePersistent( MSIDATABASE *db, LPCWSTR table ) DECLSPEC_HIDDEN;
|
2004-03-19 02:16:36 +01:00
|
|
|
|
2007-07-16 23:45:29 +02:00
|
|
|
extern UINT read_stream_data( IStorage *stg, LPCWSTR stname, BOOL table,
|
2011-04-21 11:03:25 +02:00
|
|
|
BYTE **pdata, UINT *psz ) DECLSPEC_HIDDEN;
|
2007-04-23 09:17:40 +02:00
|
|
|
extern UINT write_stream_data( IStorage *stg, LPCWSTR stname,
|
2011-04-21 11:03:25 +02:00
|
|
|
LPCVOID data, UINT sz, BOOL bTable ) DECLSPEC_HIDDEN;
|
2005-01-26 20:41:13 +01:00
|
|
|
|
2005-10-26 15:56:33 +02:00
|
|
|
/* transform functions */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_table_apply_transform( MSIDATABASE *db, IStorage *stg ) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
extern UINT MSI_DatabaseApplyTransformW( MSIDATABASE *db,
|
2011-04-21 11:03:25 +02:00
|
|
|
LPCWSTR szTransformFile, int iErrorCond ) DECLSPEC_HIDDEN;
|
|
|
|
extern void append_storage_to_db( MSIDATABASE *db, IStorage *stg ) DECLSPEC_HIDDEN;
|
2011-05-24 10:49:37 +02:00
|
|
|
extern UINT msi_apply_transforms( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2005-10-26 15:56:33 +02:00
|
|
|
|
2010-05-05 14:37:55 +02:00
|
|
|
/* patch functions */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_check_patch_applicable( MSIPACKAGE *package, MSISUMMARYINFO *si ) DECLSPEC_HIDDEN;
|
2011-05-24 10:49:37 +02:00
|
|
|
extern UINT msi_apply_patches( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2011-06-30 12:15:37 +02:00
|
|
|
extern UINT msi_apply_registered_patch( MSIPACKAGE *package, LPCWSTR patch_code ) DECLSPEC_HIDDEN;
|
2011-08-23 14:42:03 +02:00
|
|
|
extern void msi_free_patchinfo( MSIPATCHINFO *patch ) DECLSPEC_HIDDEN;
|
2009-09-02 11:44:17 +02:00
|
|
|
|
2005-01-26 20:41:13 +01:00
|
|
|
/* action internals */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_InstallPackage( MSIPACKAGE *, LPCWSTR, LPCWSTR ) DECLSPEC_HIDDEN;
|
2017-07-11 07:18:33 +02:00
|
|
|
extern INT ACTION_ShowDialog( MSIPACKAGE*, LPCWSTR) DECLSPEC_HIDDEN;
|
2017-07-23 22:50:56 +02:00
|
|
|
extern INT ACTION_DialogBox( MSIPACKAGE*, LPCWSTR) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT ACTION_ForceReboot(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
2011-07-27 10:53:26 +02:00
|
|
|
extern UINT MSI_Sequence( MSIPACKAGE *package, LPCWSTR szTable ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_SetFeatureStates( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2011-05-20 12:33:45 +02:00
|
|
|
extern UINT msi_parse_command_line( MSIPACKAGE *package, LPCWSTR szCommandLine, BOOL preserve_case ) DECLSPEC_HIDDEN;
|
2018-06-21 21:48:56 +02:00
|
|
|
extern const WCHAR *msi_get_command_line_option( const WCHAR *cmd, const WCHAR *option, UINT *len ) DECLSPEC_HIDDEN;
|
2011-05-20 12:33:45 +02:00
|
|
|
extern UINT msi_schedule_action( MSIPACKAGE *package, UINT script, const WCHAR *action ) DECLSPEC_HIDDEN;
|
2011-05-24 10:50:28 +02:00
|
|
|
extern INSTALLSTATE msi_get_component_action( MSIPACKAGE *package, MSICOMPONENT *comp ) DECLSPEC_HIDDEN;
|
2011-05-24 10:51:15 +02:00
|
|
|
extern INSTALLSTATE msi_get_feature_action( MSIPACKAGE *package, MSIFEATURE *feature ) DECLSPEC_HIDDEN;
|
2011-06-10 10:13:34 +02:00
|
|
|
extern UINT msi_load_all_components( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_load_all_features( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2011-12-23 13:53:54 +01:00
|
|
|
extern UINT msi_validate_product_id( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2004-06-28 22:34:35 +02:00
|
|
|
|
2004-06-30 20:18:27 +02:00
|
|
|
/* record internals */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void MSI_CloseRecord( MSIOBJECTHDR * ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordSetIStream( MSIRECORD *, UINT, IStream *) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordGetIStream( MSIRECORD *, UINT, IStream **) DECLSPEC_HIDDEN;
|
|
|
|
extern const WCHAR *MSI_RecordGetString( const MSIRECORD *, UINT ) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIRECORD *MSI_CreateRecord( UINT ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordSetInteger( MSIRECORD *, UINT, int ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordSetStringW( MSIRECORD *, UINT, LPCWSTR ) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL MSI_RecordIsNull( MSIRECORD *, UINT ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordGetStringW( MSIRECORD * , UINT, LPWSTR, LPDWORD) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordGetStringA( MSIRECORD *, UINT, LPSTR, LPDWORD) DECLSPEC_HIDDEN;
|
|
|
|
extern int MSI_RecordGetInteger( MSIRECORD *, UINT ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordReadStream( MSIRECORD *, UINT, char *, LPDWORD) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordSetStream(MSIRECORD *, UINT, IStream *) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordGetFieldCount( const MSIRECORD *rec ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordStreamToFile( MSIRECORD *, UINT, LPCWSTR ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordSetStreamFromFileW( MSIRECORD *, UINT, LPCWSTR ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_RecordCopyField( MSIRECORD *, UINT, MSIRECORD *, UINT ) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIRECORD *MSI_CloneRecord( MSIRECORD * ) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL MSI_RecordsAreEqual( MSIRECORD *, MSIRECORD * ) DECLSPEC_HIDDEN;
|
2011-08-26 04:53:39 +02:00
|
|
|
extern BOOL MSI_RecordsAreFieldsEqual(MSIRECORD *a, MSIRECORD *b, UINT field) DECLSPEC_HIDDEN;
|
2012-10-29 12:13:12 +01:00
|
|
|
extern UINT msi_record_set_string(MSIRECORD *, UINT, const WCHAR *, int) DECLSPEC_HIDDEN;
|
2012-10-29 12:13:54 +01:00
|
|
|
extern const WCHAR *msi_record_get_string(const MSIRECORD *, UINT, int *) DECLSPEC_HIDDEN;
|
2017-07-11 07:18:32 +02:00
|
|
|
extern void dump_record(MSIRECORD *) DECLSPEC_HIDDEN;
|
2018-04-18 02:11:29 +02:00
|
|
|
extern UINT unmarshal_record(const struct wire_record *in, MSIHANDLE *out) DECLSPEC_HIDDEN;
|
2018-04-19 01:40:06 +02:00
|
|
|
extern struct wire_record *marshal_record(MSIHANDLE handle) DECLSPEC_HIDDEN;
|
|
|
|
extern void free_remote_record(struct wire_record *rec) DECLSPEC_HIDDEN;
|
2018-04-20 06:44:15 +02:00
|
|
|
extern UINT copy_remote_record(const struct wire_record *rec, MSIHANDLE handle) DECLSPEC_HIDDEN;
|
2004-06-30 20:18:27 +02:00
|
|
|
|
|
|
|
/* stream internals */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void enum_stream_names( IStorage *stg ) DECLSPEC_HIDDEN;
|
|
|
|
extern LPWSTR encode_streamname(BOOL bTable, LPCWSTR in) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL decode_streamname(LPCWSTR in, LPWSTR out) DECLSPEC_HIDDEN;
|
2004-06-29 05:41:28 +02:00
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
/* database internals */
|
2015-02-13 13:39:38 +01:00
|
|
|
extern UINT msi_get_stream( MSIDATABASE *, const WCHAR *, IStream ** ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_OpenDatabaseW( LPCWSTR, LPCWSTR, MSIDATABASE ** ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_DatabaseOpenViewW(MSIDATABASE *, LPCWSTR, MSIQUERY ** ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_OpenQuery( MSIDATABASE *, MSIQUERY **, LPCWSTR, ... ) DECLSPEC_HIDDEN;
|
2005-05-31 11:30:28 +02:00
|
|
|
typedef UINT (*record_func)( MSIRECORD *, LPVOID );
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_IterateRecords( MSIQUERY *, LPDWORD, record_func, LPVOID ) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIRECORD *MSI_QueryGetRecord( MSIDATABASE *db, LPCWSTR query, ... ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_DatabaseGetPrimaryKeys( MSIDATABASE *, LPCWSTR, MSIRECORD ** ) DECLSPEC_HIDDEN;
|
2004-07-10 00:25:34 +02:00
|
|
|
|
|
|
|
/* view internals */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_ViewExecute( MSIQUERY*, MSIRECORD * ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_ViewFetch( MSIQUERY*, MSIRECORD ** ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_ViewClose( MSIQUERY* ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_ViewGetColumnInfo(MSIQUERY *, MSICOLINFO, MSIRECORD **) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_ViewModify( MSIQUERY *, MSIMODIFY, MSIRECORD * ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT VIEW_find_column( MSIVIEW *, LPCWSTR, LPCWSTR, UINT * ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_view_get_row(MSIDATABASE *, MSIVIEW *, UINT, MSIRECORD **) DECLSPEC_HIDDEN;
|
2004-07-10 00:25:34 +02:00
|
|
|
|
2006-07-19 20:17:28 +02:00
|
|
|
/* install internals */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_SetInstallLevel( MSIPACKAGE *package, int iInstallLevel ) DECLSPEC_HIDDEN;
|
2006-07-19 20:17:28 +02:00
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
/* package internals */
|
2018-06-21 21:48:56 +02:00
|
|
|
#define WINE_OPENPACKAGEFLAGS_RECACHE 0x80000000
|
2018-04-18 10:05:46 +02:00
|
|
|
extern MSIPACKAGE *MSI_CreatePackage( MSIDATABASE * ) DECLSPEC_HIDDEN;
|
2018-06-21 21:48:56 +02:00
|
|
|
extern UINT MSI_OpenPackageW( LPCWSTR szPackage, DWORD dwOptions, MSIPACKAGE **pPackage ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_SetTargetPathW( MSIPACKAGE *, LPCWSTR, LPCWSTR ) DECLSPEC_HIDDEN;
|
2017-07-10 20:46:40 +02:00
|
|
|
extern INT MSI_ProcessMessageVerbatim( MSIPACKAGE *, INSTALLMESSAGE, MSIRECORD * ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern INT MSI_ProcessMessage( MSIPACKAGE *, INSTALLMESSAGE, MSIRECORD * ) DECLSPEC_HIDDEN;
|
|
|
|
extern MSICONDITION MSI_EvaluateConditionW( MSIPACKAGE *, LPCWSTR ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_GetComponentStateW( MSIPACKAGE *, LPCWSTR, INSTALLSTATE *, INSTALLSTATE * ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_GetFeatureStateW( MSIPACKAGE *, LPCWSTR, INSTALLSTATE *, INSTALLSTATE * ) DECLSPEC_HIDDEN;
|
2011-09-23 11:12:22 +02:00
|
|
|
extern UINT MSI_SetFeatureStateW(MSIPACKAGE*, LPCWSTR, INSTALLSTATE ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_download_file( LPCWSTR szUrl, LPWSTR filename ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_package_add_info(MSIPACKAGE *, DWORD, DWORD, LPCWSTR, LPWSTR) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_package_add_media_disk(MSIPACKAGE *, DWORD, DWORD, DWORD, LPWSTR, LPWSTR) DECLSPEC_HIDDEN;
|
2014-11-04 10:57:13 +01:00
|
|
|
extern UINT msi_clone_properties(MSIDATABASE *) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_set_context(MSIPACKAGE *) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_adjust_privilege_properties(MSIPACKAGE *) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSI_GetFeatureCost(MSIPACKAGE *, MSIFEATURE *, MSICOSTTREE, INSTALLSTATE, LPINT) DECLSPEC_HIDDEN;
|
2004-07-10 00:25:34 +02:00
|
|
|
|
2005-01-25 21:17:09 +01:00
|
|
|
/* for deformating */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSI_FormatRecordW( MSIPACKAGE *, MSIRECORD *, LPWSTR, LPDWORD ) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
|
2004-07-10 00:25:34 +02:00
|
|
|
/* registry data encoding/decoding functions */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern BOOL unsquash_guid(LPCWSTR in, LPWSTR out) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL squash_guid(LPCWSTR in, LPWSTR out) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL encode_base85_guid(GUID *,LPWSTR) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL decode_base85_guid(LPCWSTR,GUID*) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenUninstallKey(const WCHAR *, enum platform, HKEY *, BOOL) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteUninstallKey(const WCHAR *, enum platform) DECLSPEC_HIDDEN;
|
2009-03-22 22:30:16 +01:00
|
|
|
extern UINT MSIREG_OpenProductKey(LPCWSTR szProduct, LPCWSTR szUserSid,
|
2011-04-21 11:03:25 +02:00
|
|
|
MSIINSTALLCONTEXT context, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
2013-01-09 11:43:48 +01:00
|
|
|
extern UINT MSIREG_OpenFeaturesKey(LPCWSTR szProduct, LPCWSTR szUserSid, MSIINSTALLCONTEXT context,
|
2011-04-21 11:03:25 +02:00
|
|
|
HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenUserPatchesKey(LPCWSTR szPatch, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
2013-01-09 11:43:48 +01:00
|
|
|
UINT MSIREG_OpenUserDataFeaturesKey(LPCWSTR szProduct, LPCWSTR szUserSid, MSIINSTALLCONTEXT context,
|
2011-04-21 11:03:25 +02:00
|
|
|
HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenUserComponentsKey(LPCWSTR szComponent, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
2008-12-09 07:21:00 +01:00
|
|
|
extern UINT MSIREG_OpenUserDataComponentKey(LPCWSTR szComponent, LPCWSTR szUserSid,
|
2011-04-21 11:03:25 +02:00
|
|
|
HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenPatchesKey(LPCWSTR szPatch, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
2008-12-15 04:07:06 +01:00
|
|
|
extern UINT MSIREG_OpenUserDataProductKey(LPCWSTR szProduct, MSIINSTALLCONTEXT dwContext,
|
2011-04-21 11:03:25 +02:00
|
|
|
LPCWSTR szUserSid, HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
2008-12-15 04:07:09 +01:00
|
|
|
extern UINT MSIREG_OpenUserDataPatchKey(LPCWSTR szPatch, MSIINSTALLCONTEXT dwContext,
|
2011-04-21 11:03:25 +02:00
|
|
|
HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
2010-05-04 09:07:39 +02:00
|
|
|
extern UINT MSIREG_OpenUserDataProductPatchesKey(LPCWSTR product, MSIINSTALLCONTEXT context,
|
2011-04-21 11:03:25 +02:00
|
|
|
HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
2008-12-15 04:07:14 +01:00
|
|
|
extern UINT MSIREG_OpenInstallProps(LPCWSTR szProduct, MSIINSTALLCONTEXT dwContext,
|
2011-04-21 11:03:25 +02:00
|
|
|
LPCWSTR szUserSid, HKEY *key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenUpgradeCodesKey(LPCWSTR szProduct, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenUserUpgradeCodesKey(LPCWSTR szProduct, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteProductKey(LPCWSTR szProduct) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteUserProductKey(LPCWSTR szProduct) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteUserDataPatchKey(LPCWSTR patch, MSIINSTALLCONTEXT context) DECLSPEC_HIDDEN;
|
2016-11-04 13:28:08 +01:00
|
|
|
extern UINT MSIREG_DeleteUserDataProductKey(LPCWSTR, MSIINSTALLCONTEXT) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSIREG_DeleteUserFeaturesKey(LPCWSTR szProduct) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteUserDataComponentKey(LPCWSTR szComponent, LPCWSTR szUserSid) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteUserUpgradeCodesKey(LPCWSTR szUpgradeCode) DECLSPEC_HIDDEN;
|
2016-11-04 13:28:11 +01:00
|
|
|
extern UINT MSIREG_DeleteUpgradeCodesKey(const WCHAR *) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT MSIREG_DeleteClassesUpgradeCodesKey(LPCWSTR szUpgradeCode) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_OpenClassesUpgradeCodesKey(LPCWSTR szUpgradeCode, HKEY* key, BOOL create) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteLocalClassesProductKey(LPCWSTR szProductCode) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT MSIREG_DeleteLocalClassesFeaturesKey(LPCWSTR szProductCode) DECLSPEC_HIDDEN;
|
2011-08-23 14:41:43 +02:00
|
|
|
extern UINT msi_locate_product(LPCWSTR szProduct, MSIINSTALLCONTEXT *context) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern LPWSTR msi_reg_get_val_str( HKEY hkey, LPCWSTR name ) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL msi_reg_get_val_dword( HKEY hkey, LPCWSTR name, DWORD *val) DECLSPEC_HIDDEN;
|
|
|
|
|
|
|
|
extern DWORD msi_version_str_to_dword(LPCWSTR p) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_parse_version_string(LPCWSTR, PDWORD, PDWORD) DECLSPEC_HIDDEN;
|
|
|
|
extern VS_FIXEDFILEINFO *msi_get_disk_file_version(LPCWSTR) DECLSPEC_HIDDEN;
|
|
|
|
extern int msi_compare_file_versions(VS_FIXEDFILEINFO *, const WCHAR *) DECLSPEC_HIDDEN;
|
|
|
|
extern int msi_compare_font_versions(const WCHAR *, const WCHAR *) DECLSPEC_HIDDEN;
|
|
|
|
extern DWORD msi_get_disk_file_size(LPCWSTR) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL msi_file_hash_matches(MSIFILE *) DECLSPEC_HIDDEN;
|
2015-03-16 10:55:21 +01:00
|
|
|
extern UINT msi_get_filehash(const WCHAR *, MSIFILEHASHINFO *) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
|
|
|
|
extern LONG msi_reg_set_val_str( HKEY hkey, LPCWSTR name, LPCWSTR value ) DECLSPEC_HIDDEN;
|
|
|
|
extern LONG msi_reg_set_val_multi_str( HKEY hkey, LPCWSTR name, LPCWSTR value ) DECLSPEC_HIDDEN;
|
|
|
|
extern LONG msi_reg_set_val_dword( HKEY hkey, LPCWSTR name, DWORD val ) DECLSPEC_HIDDEN;
|
|
|
|
extern LONG msi_reg_set_subkey_val( HKEY hkey, LPCWSTR path, LPCWSTR name, LPCWSTR val ) DECLSPEC_HIDDEN;
|
2005-09-15 16:58:38 +02:00
|
|
|
|
2005-01-28 13:39:57 +01:00
|
|
|
/* msi dialog interface */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void msi_dialog_check_messages( HANDLE ) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_dialog_destroy( msi_dialog* ) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_dialog_unregister_class( void ) DECLSPEC_HIDDEN;
|
2004-07-04 02:26:54 +02:00
|
|
|
|
2005-10-26 12:10:50 +02:00
|
|
|
/* summary information */
|
2015-03-16 10:55:58 +01:00
|
|
|
extern UINT msi_get_suminfo( IStorage *stg, UINT uiUpdateCount, MSISUMMARYINFO **si ) DECLSPEC_HIDDEN;
|
2015-03-25 14:31:47 +01:00
|
|
|
extern UINT msi_get_db_suminfo( MSIDATABASE *db, UINT uiUpdateCount, MSISUMMARYINFO **si ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern LPWSTR msi_suminfo_dup_string( MSISUMMARYINFO *si, UINT uiProperty ) DECLSPEC_HIDDEN;
|
|
|
|
extern INT msi_suminfo_get_int32( MSISUMMARYINFO *si, UINT uiProperty ) DECLSPEC_HIDDEN;
|
|
|
|
extern LPWSTR msi_get_suminfo_product( IStorage *stg ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_add_suminfo( MSIDATABASE *db, LPWSTR **records, int num_records, int num_columns ) DECLSPEC_HIDDEN;
|
2015-03-25 14:32:17 +01:00
|
|
|
extern UINT msi_load_suminfo_properties( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2005-10-26 12:10:50 +02:00
|
|
|
|
2005-06-07 22:29:51 +02:00
|
|
|
/* undocumented functions */
|
|
|
|
UINT WINAPI MsiCreateAndVerifyInstallerDirectory( DWORD );
|
2007-08-09 10:41:41 +02:00
|
|
|
UINT WINAPI MsiDecomposeDescriptorW( LPCWSTR, LPWSTR, LPWSTR, LPWSTR, LPDWORD );
|
|
|
|
UINT WINAPI MsiDecomposeDescriptorA( LPCSTR, LPSTR, LPSTR, LPSTR, LPDWORD );
|
2005-06-07 22:29:51 +02:00
|
|
|
LANGID WINAPI MsiLoadStringW( MSIHANDLE, UINT, LPWSTR, int, LANGID );
|
|
|
|
LANGID WINAPI MsiLoadStringA( MSIHANDLE, UINT, LPSTR, int, LANGID );
|
|
|
|
|
2004-07-04 02:26:54 +02:00
|
|
|
/* UI globals */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern INSTALLUILEVEL gUILevel DECLSPEC_HIDDEN;
|
|
|
|
extern HWND gUIhwnd DECLSPEC_HIDDEN;
|
|
|
|
extern INSTALLUI_HANDLERA gUIHandlerA DECLSPEC_HIDDEN;
|
|
|
|
extern INSTALLUI_HANDLERW gUIHandlerW DECLSPEC_HIDDEN;
|
|
|
|
extern INSTALLUI_HANDLER_RECORD gUIHandlerRecord DECLSPEC_HIDDEN;
|
|
|
|
extern DWORD gUIFilter DECLSPEC_HIDDEN;
|
2017-06-19 04:53:28 +02:00
|
|
|
extern DWORD gUIFilterRecord DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern LPVOID gUIContext DECLSPEC_HIDDEN;
|
2017-06-19 04:53:28 +02:00
|
|
|
extern LPVOID gUIContextRecord DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern WCHAR *gszLogFile DECLSPEC_HIDDEN;
|
|
|
|
extern HINSTANCE msi_hInstance DECLSPEC_HIDDEN;
|
2004-07-04 02:26:54 +02:00
|
|
|
|
2006-10-10 13:03:52 +02:00
|
|
|
/* action related functions */
|
2018-06-06 07:59:22 +02:00
|
|
|
extern UINT ACTION_PerformAction(MSIPACKAGE *package, const WCHAR *action) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void ACTION_FinishCustomActions( const MSIPACKAGE* package) DECLSPEC_HIDDEN;
|
2018-06-06 07:59:22 +02:00
|
|
|
extern UINT ACTION_CustomAction(MSIPACKAGE *package, const WCHAR *action) DECLSPEC_HIDDEN;
|
2018-07-10 12:08:47 +02:00
|
|
|
extern void custom_stop_server(HANDLE process, HANDLE pipe) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
|
|
|
|
/* actions in other modules */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT ACTION_AppSearch(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_CCPSearch(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_FindRelatedProducts(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_InstallFiles(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_PatchFiles( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RemoveFiles(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_MoveFiles(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_DuplicateFiles(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RemoveDuplicateFiles(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RegisterClassInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RegisterProgIdInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RegisterExtensionInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RegisterMIMEInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_RegisterFonts(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_UnregisterClassInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_UnregisterExtensionInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_UnregisterFonts(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_UnregisterMIMEInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_UnregisterProgIdInfo(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_MsiPublishAssemblies(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT ACTION_MsiUnpublishAssemblies(MSIPACKAGE *package) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
|
|
|
|
/* Helpers */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern DWORD deformat_string(MSIPACKAGE *package, LPCWSTR ptr, WCHAR** data ) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:17 +02:00
|
|
|
extern WCHAR *msi_dup_record_field(MSIRECORD *row, INT index) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern LPWSTR msi_dup_property( MSIDATABASE *db, LPCWSTR prop ) DECLSPEC_HIDDEN;
|
2012-10-29 12:15:21 +01:00
|
|
|
extern UINT msi_set_property( MSIDATABASE *, const WCHAR *, const WCHAR *, int ) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_get_property( MSIDATABASE *, LPCWSTR, LPWSTR, LPDWORD ) DECLSPEC_HIDDEN;
|
|
|
|
extern int msi_get_property_int( MSIDATABASE *package, LPCWSTR prop, int def ) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:17 +02:00
|
|
|
extern WCHAR *msi_resolve_source_folder(MSIPACKAGE *package, const WCHAR *name, MSIFOLDER **folder) DECLSPEC_HIDDEN;
|
2011-05-02 16:03:55 +02:00
|
|
|
extern void msi_resolve_target_folder(MSIPACKAGE *package, const WCHAR *name, BOOL load_prop) DECLSPEC_HIDDEN;
|
2012-01-18 12:58:15 +01:00
|
|
|
extern WCHAR *msi_normalize_path(const WCHAR *) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:17 +02:00
|
|
|
extern WCHAR *msi_resolve_file_source(MSIPACKAGE *package, MSIFILE *file) DECLSPEC_HIDDEN;
|
2011-05-02 16:03:32 +02:00
|
|
|
extern const WCHAR *msi_get_target_folder(MSIPACKAGE *package, const WCHAR *name) DECLSPEC_HIDDEN;
|
2018-10-10 16:14:28 +02:00
|
|
|
extern void msi_reset_source_folders( MSIPACKAGE *package ) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:17 +02:00
|
|
|
extern MSICOMPONENT *msi_get_loaded_component(MSIPACKAGE *package, const WCHAR *Component) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIFEATURE *msi_get_loaded_feature(MSIPACKAGE *package, const WCHAR *Feature) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIFILE *msi_get_loaded_file(MSIPACKAGE *package, const WCHAR *file) DECLSPEC_HIDDEN;
|
|
|
|
extern MSIFOLDER *msi_get_loaded_folder(MSIPACKAGE *package, const WCHAR *dir) DECLSPEC_HIDDEN;
|
2015-04-01 12:33:11 +02:00
|
|
|
extern WCHAR *msi_create_temp_file(MSIDATABASE *db) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void msi_free_action_script(MSIPACKAGE *package, UINT script) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:17 +02:00
|
|
|
extern WCHAR *msi_build_icon_path(MSIPACKAGE *, const WCHAR *) DECLSPEC_HIDDEN;
|
|
|
|
extern WCHAR *msi_build_directory_name(DWORD , ...) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL msi_create_full_path(const WCHAR *path) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_reduce_to_long_filename(WCHAR *) DECLSPEC_HIDDEN;
|
|
|
|
extern WCHAR *msi_create_component_advertise_string(MSIPACKAGE *, MSICOMPONENT *, const WCHAR *) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern void ACTION_UpdateComponentStates(MSIPACKAGE *package, MSIFEATURE *feature) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:17 +02:00
|
|
|
extern UINT msi_register_unique_action(MSIPACKAGE *, const WCHAR *) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL msi_action_is_unique(const MSIPACKAGE *, const WCHAR *) DECLSPEC_HIDDEN;
|
2008-02-26 08:55:01 +01:00
|
|
|
extern UINT msi_set_last_used_source(LPCWSTR product, LPCWSTR usersid,
|
2011-04-21 11:03:25 +02:00
|
|
|
MSIINSTALLCONTEXT context, DWORD options, LPCWSTR value) DECLSPEC_HIDDEN;
|
2011-08-23 14:41:43 +02:00
|
|
|
extern UINT msi_create_empty_local_file(LPWSTR path, LPCWSTR suffix) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_set_sourcedir_props(MSIPACKAGE *package, BOOL replace) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:58 +02:00
|
|
|
extern MSIASSEMBLY *msi_load_assembly(MSIPACKAGE *, MSICOMPONENT *) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_install_assembly(MSIPACKAGE *, MSICOMPONENT *) DECLSPEC_HIDDEN;
|
2012-04-30 09:35:25 +02:00
|
|
|
extern UINT msi_uninstall_assembly(MSIPACKAGE *, MSICOMPONENT *) DECLSPEC_HIDDEN;
|
2011-05-06 14:39:58 +02:00
|
|
|
extern BOOL msi_init_assembly_caches(MSIPACKAGE *) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_destroy_assembly_caches(MSIPACKAGE *) DECLSPEC_HIDDEN;
|
2015-04-01 12:32:44 +02:00
|
|
|
extern BOOL msi_is_global_assembly(MSICOMPONENT *) DECLSPEC_HIDDEN;
|
2015-04-10 12:59:01 +02:00
|
|
|
extern IAssemblyEnum *msi_create_assembly_enum(MSIPACKAGE *, const WCHAR *) DECLSPEC_HIDDEN;
|
|
|
|
extern WCHAR *msi_get_assembly_path(MSIPACKAGE *, const WCHAR *) DECLSPEC_HIDDEN;
|
2011-09-20 11:31:41 +02:00
|
|
|
extern WCHAR *msi_font_version_from_file(const WCHAR *) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern WCHAR **msi_split_string(const WCHAR *, WCHAR) DECLSPEC_HIDDEN;
|
2013-01-21 16:24:11 +01:00
|
|
|
extern UINT msi_set_original_database_property(MSIDATABASE *, const WCHAR *) DECLSPEC_HIDDEN;
|
2017-07-23 22:50:54 +02:00
|
|
|
extern WCHAR *msi_get_error_message(MSIDATABASE *, int) DECLSPEC_HIDDEN;
|
2018-05-16 06:03:33 +02:00
|
|
|
extern UINT msi_strncpyWtoA(const WCHAR *str, int len, char *buf, DWORD *sz, BOOL remote) DECLSPEC_HIDDEN;
|
2018-05-16 06:03:34 +02:00
|
|
|
extern UINT msi_strncpyW(const WCHAR *str, int len, WCHAR *buf, DWORD *sz) DECLSPEC_HIDDEN;
|
2018-06-19 12:02:48 +02:00
|
|
|
extern WCHAR *msi_get_package_code(MSIDATABASE *db) DECLSPEC_HIDDEN;
|
2008-08-19 05:59:44 +02:00
|
|
|
|
|
|
|
/* media */
|
|
|
|
|
|
|
|
typedef BOOL (*PMSICABEXTRACTCB)(MSIPACKAGE *, LPCWSTR, DWORD, LPWSTR *, DWORD *, PVOID);
|
|
|
|
|
|
|
|
#define MSICABEXTRACT_BEGINEXTRACT 0x01
|
|
|
|
#define MSICABEXTRACT_FILEEXTRACTED 0x02
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
MSIPACKAGE* package;
|
|
|
|
MSIMEDIAINFO *mi;
|
|
|
|
PMSICABEXTRACTCB cb;
|
|
|
|
LPWSTR curfile;
|
|
|
|
PVOID user;
|
|
|
|
} MSICABDATA;
|
|
|
|
|
2011-12-23 13:53:34 +01:00
|
|
|
extern UINT ready_media(MSIPACKAGE *package, BOOL compressed, MSIMEDIAINFO *mi) DECLSPEC_HIDDEN;
|
2011-04-21 11:03:25 +02:00
|
|
|
extern UINT msi_load_media_info(MSIPACKAGE *package, UINT Sequence, MSIMEDIAINFO *mi) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_free_media_info(MSIMEDIAINFO *mi) DECLSPEC_HIDDEN;
|
|
|
|
extern BOOL msi_cabextract(MSIPACKAGE* package, MSIMEDIAINFO *mi, LPVOID data) DECLSPEC_HIDDEN;
|
|
|
|
extern UINT msi_add_cabinet_stream(MSIPACKAGE *, UINT, IStorage *, const WCHAR *) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
|
|
|
|
/* control event stuff */
|
2013-07-26 17:19:34 +02:00
|
|
|
extern void msi_event_fire(MSIPACKAGE *, const WCHAR *, MSIRECORD *) DECLSPEC_HIDDEN;
|
|
|
|
extern void msi_event_cleanup_all_subscriptions( MSIPACKAGE * ) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
|
2007-05-01 03:54:31 +02:00
|
|
|
/* OLE automation */
|
2012-11-14 05:45:02 +01:00
|
|
|
typedef enum tid_t {
|
|
|
|
Database_tid,
|
|
|
|
Installer_tid,
|
|
|
|
Record_tid,
|
|
|
|
Session_tid,
|
|
|
|
StringList_tid,
|
|
|
|
SummaryInfo_tid,
|
|
|
|
View_tid,
|
|
|
|
LAST_tid
|
|
|
|
} tid_t;
|
|
|
|
|
2011-04-21 11:03:25 +02:00
|
|
|
extern HRESULT create_msiserver(IUnknown *pOuter, LPVOID *ppObj) DECLSPEC_HIDDEN;
|
|
|
|
extern HRESULT create_session(MSIHANDLE msiHandle, IDispatch *pInstaller, IDispatch **pDispatch) DECLSPEC_HIDDEN;
|
2012-11-14 05:45:02 +01:00
|
|
|
extern HRESULT get_typeinfo(tid_t tid, ITypeInfo **ti) DECLSPEC_HIDDEN;
|
|
|
|
extern void release_typelib(void) DECLSPEC_HIDDEN;
|
2007-05-01 03:54:43 +02:00
|
|
|
|
|
|
|
/* Scripting */
|
2011-04-21 11:03:25 +02:00
|
|
|
extern DWORD call_script(MSIHANDLE hPackage, INT type, LPCWSTR script, LPCWSTR function, LPCWSTR action) DECLSPEC_HIDDEN;
|
2007-05-01 03:54:31 +02:00
|
|
|
|
2011-05-06 14:39:17 +02:00
|
|
|
/* User interface messages from the actions */
|
|
|
|
extern void msi_ui_progress(MSIPACKAGE *, int, int, int, int) DECLSPEC_HIDDEN;
|
2006-10-10 13:03:52 +02:00
|
|
|
|
2009-10-15 12:46:27 +02:00
|
|
|
/* common strings */
|
2011-05-02 16:04:25 +02:00
|
|
|
static const WCHAR szSourceDir[] = {'S','o','u','r','c','e','D','i','r',0};
|
|
|
|
static const WCHAR szSOURCEDIR[] = {'S','O','U','R','C','E','D','I','R',0};
|
|
|
|
static const WCHAR szRootDrive[] = {'R','O','O','T','D','R','I','V','E',0};
|
|
|
|
static const WCHAR szTargetDir[] = {'T','A','R','G','E','T','D','I','R',0};
|
2009-10-15 12:46:27 +02:00
|
|
|
static const WCHAR szLocalSid[] = {'S','-','1','-','5','-','1','8',0};
|
2012-03-12 12:25:50 +01:00
|
|
|
static const WCHAR szAllSid[] = {'S','-','1','-','1','-','0',0};
|
2009-10-15 12:46:27 +02:00
|
|
|
static const WCHAR szEmpty[] = {0};
|
|
|
|
static const WCHAR szAll[] = {'A','L','L',0};
|
|
|
|
static const WCHAR szOne[] = {'1',0};
|
|
|
|
static const WCHAR szZero[] = {'0',0};
|
|
|
|
static const WCHAR szSpace[] = {' ',0};
|
|
|
|
static const WCHAR szBackSlash[] = {'\\',0};
|
|
|
|
static const WCHAR szForwardSlash[] = {'/',0};
|
|
|
|
static const WCHAR szDot[] = {'.',0};
|
|
|
|
static const WCHAR szDotDot[] = {'.','.',0};
|
|
|
|
static const WCHAR szSemiColon[] = {';',0};
|
|
|
|
static const WCHAR szPreselected[] = {'P','r','e','s','e','l','e','c','t','e','d',0};
|
|
|
|
static const WCHAR szPatches[] = {'P','a','t','c','h','e','s',0};
|
|
|
|
static const WCHAR szState[] = {'S','t','a','t','e',0};
|
|
|
|
static const WCHAR szMsi[] = {'m','s','i',0};
|
|
|
|
static const WCHAR szPatch[] = {'P','A','T','C','H',0};
|
|
|
|
static const WCHAR szSourceList[] = {'S','o','u','r','c','e','L','i','s','t',0};
|
|
|
|
static const WCHAR szInstalled[] = {'I','n','s','t','a','l','l','e','d',0};
|
|
|
|
static const WCHAR szReinstall[] = {'R','E','I','N','S','T','A','L','L',0};
|
|
|
|
static const WCHAR szReinstallMode[] = {'R','E','I','N','S','T','A','L','L','M','O','D','E',0};
|
|
|
|
static const WCHAR szRemove[] = {'R','E','M','O','V','E',0};
|
|
|
|
static const WCHAR szUserSID[] = {'U','s','e','r','S','I','D',0};
|
|
|
|
static const WCHAR szProductCode[] = {'P','r','o','d','u','c','t','C','o','d','e',0};
|
|
|
|
static const WCHAR szRegisterClassInfo[] = {'R','e','g','i','s','t','e','r','C','l','a','s','s','I','n','f','o',0};
|
|
|
|
static const WCHAR szRegisterProgIdInfo[] = {'R','e','g','i','s','t','e','r','P','r','o','g','I','d','I','n','f','o',0};
|
|
|
|
static const WCHAR szRegisterExtensionInfo[] = {'R','e','g','i','s','t','e','r','E','x','t','e','n','s','i','o','n','I','n','f','o',0};
|
|
|
|
static const WCHAR szRegisterMIMEInfo[] = {'R','e','g','i','s','t','e','r','M','I','M','E','I','n','f','o',0};
|
|
|
|
static const WCHAR szDuplicateFiles[] = {'D','u','p','l','i','c','a','t','e','F','i','l','e','s',0};
|
2010-02-23 12:59:52 +01:00
|
|
|
static const WCHAR szRemoveDuplicateFiles[] = {'R','e','m','o','v','e','D','u','p','l','i','c','a','t','e','F','i','l','e','s',0};
|
2009-10-15 12:46:27 +02:00
|
|
|
static const WCHAR szInstallFiles[] = {'I','n','s','t','a','l','l','F','i','l','e','s',0};
|
2011-03-22 20:45:11 +01:00
|
|
|
static const WCHAR szPatchFiles[] = {'P','a','t','c','h','F','i','l','e','s',0};
|
2009-10-15 12:46:27 +02:00
|
|
|
static const WCHAR szRemoveFiles[] = {'R','e','m','o','v','e','F','i','l','e','s',0};
|
|
|
|
static const WCHAR szFindRelatedProducts[] = {'F','i','n','d','R','e','l','a','t','e','d','P','r','o','d','u','c','t','s',0};
|
|
|
|
static const WCHAR szAllUsers[] = {'A','L','L','U','S','E','R','S',0};
|
|
|
|
static const WCHAR szCustomActionData[] = {'C','u','s','t','o','m','A','c','t','i','o','n','D','a','t','a',0};
|
|
|
|
static const WCHAR szUILevel[] = {'U','I','L','e','v','e','l',0};
|
2010-02-10 11:55:59 +01:00
|
|
|
static const WCHAR szProductID[] = {'P','r','o','d','u','c','t','I','D',0};
|
|
|
|
static const WCHAR szPIDTemplate[] = {'P','I','D','T','e','m','p','l','a','t','e',0};
|
|
|
|
static const WCHAR szPIDKEY[] = {'P','I','D','K','E','Y',0};
|
2010-02-12 10:32:35 +01:00
|
|
|
static const WCHAR szTYPELIB[] = {'T','Y','P','E','L','I','B',0};
|
2010-02-19 12:27:36 +01:00
|
|
|
static const WCHAR szSumInfo[] = {5 ,'S','u','m','m','a','r','y','I','n','f','o','r','m','a','t','i','o','n',0};
|
2010-02-25 15:17:11 +01:00
|
|
|
static const WCHAR szHCR[] = {'H','K','E','Y','_','C','L','A','S','S','E','S','_','R','O','O','T','\\',0};
|
|
|
|
static const WCHAR szHCU[] = {'H','K','E','Y','_','C','U','R','R','E','N','T','_','U','S','E','R','\\',0};
|
|
|
|
static const WCHAR szHLM[] = {'H','K','E','Y','_','L','O','C','A','L','_','M','A','C','H','I','N','E','\\',0};
|
|
|
|
static const WCHAR szHU[] = {'H','K','E','Y','_','U','S','E','R','S','\\',0};
|
2010-03-02 14:58:55 +01:00
|
|
|
static const WCHAR szWindowsFolder[] = {'W','i','n','d','o','w','s','F','o','l','d','e','r',0};
|
2010-03-05 12:23:53 +01:00
|
|
|
static const WCHAR szAppSearch[] = {'A','p','p','S','e','a','r','c','h',0};
|
2010-03-05 12:27:07 +01:00
|
|
|
static const WCHAR szMoveFiles[] = {'M','o','v','e','F','i','l','e','s',0};
|
2010-03-23 11:46:00 +01:00
|
|
|
static const WCHAR szCCPSearch[] = {'C','C','P','S','e','a','r','c','h',0};
|
2010-04-02 10:37:50 +02:00
|
|
|
static const WCHAR szUnregisterClassInfo[] = {'U','n','r','e','g','i','s','t','e','r','C','l','a','s','s','I','n','f','o',0};
|
2010-04-02 10:39:20 +02:00
|
|
|
static const WCHAR szUnregisterExtensionInfo[] = {'U','n','r','e','g','i','s','t','e','r','E','x','t','e','n','s','i','o','n','I','n','f','o',0};
|
2010-04-02 10:40:07 +02:00
|
|
|
static const WCHAR szUnregisterMIMEInfo[] = {'U','n','r','e','g','i','s','t','e','r','M','I','M','E','I','n','f','o',0};
|
2010-04-02 10:38:57 +02:00
|
|
|
static const WCHAR szUnregisterProgIdInfo[] = {'U','n','r','e','g','i','s','t','e','r','P','r','o','g','I','d','I','n','f','o',0};
|
|
|
|
static const WCHAR szRegisterFonts[] = {'R','e','g','i','s','t','e','r','F','o','n','t','s',0};
|
|
|
|
static const WCHAR szUnregisterFonts[] = {'U','n','r','e','g','i','s','t','e','r','F','o','n','t','s',0};
|
2010-04-02 10:37:50 +02:00
|
|
|
static const WCHAR szCLSID[] = {'C','L','S','I','D',0};
|
|
|
|
static const WCHAR szProgID[] = {'P','r','o','g','I','D',0};
|
|
|
|
static const WCHAR szVIProgID[] = {'V','e','r','s','i','o','n','I','n','d','e','p','e','n','d','e','n','t','P','r','o','g','I','D',0};
|
|
|
|
static const WCHAR szAppID[] = {'A','p','p','I','D',0};
|
|
|
|
static const WCHAR szDefaultIcon[] = {'D','e','f','a','u','l','t','I','c','o','n',0};
|
|
|
|
static const WCHAR szInprocHandler[] = {'I','n','p','r','o','c','H','a','n','d','l','e','r',0};
|
|
|
|
static const WCHAR szInprocHandler32[] = {'I','n','p','r','o','c','H','a','n','d','l','e','r','3','2',0};
|
2010-04-02 10:40:07 +02:00
|
|
|
static const WCHAR szMIMEDatabase[] = {'M','I','M','E','\\','D','a','t','a','b','a','s','e','\\','C','o','n','t','e','n','t',' ','T','y','p','e','\\',0};
|
2010-05-04 09:07:39 +02:00
|
|
|
static const WCHAR szLocalPackage[] = {'L','o','c','a','l','P','a','c','k','a','g','e',0};
|
2010-05-11 14:05:32 +02:00
|
|
|
static const WCHAR szOriginalDatabase[] = {'O','r','i','g','i','n','a','l','D','a','t','a','b','a','s','e',0};
|
2010-07-21 09:46:30 +02:00
|
|
|
static const WCHAR szUpgradeCode[] = {'U','p','g','r','a','d','e','C','o','d','e',0};
|
2010-09-17 15:19:56 +02:00
|
|
|
static const WCHAR szAdminUser[] = {'A','d','m','i','n','U','s','e','r',0};
|
2010-09-17 15:20:26 +02:00
|
|
|
static const WCHAR szIntel[] = {'I','n','t','e','l',0};
|
|
|
|
static const WCHAR szIntel64[] = {'I','n','t','e','l','6','4',0};
|
|
|
|
static const WCHAR szX64[] = {'x','6','4',0};
|
2010-11-26 10:27:07 +01:00
|
|
|
static const WCHAR szAMD64[] = {'A','M','D','6','4',0};
|
2012-03-18 19:26:50 +01:00
|
|
|
static const WCHAR szARM[] = {'A','r','m',0};
|
2018-11-10 15:13:47 +01:00
|
|
|
static const WCHAR szARM64[] = {'A','r','m','6','4',0};
|
2010-10-13 14:23:25 +02:00
|
|
|
static const WCHAR szWow6432NodeCLSID[] = {'W','o','w','6','4','3','2','N','o','d','e','\\','C','L','S','I','D',0};
|
2010-10-19 11:27:44 +02:00
|
|
|
static const WCHAR szStreams[] = {'_','S','t','r','e','a','m','s',0};
|
|
|
|
static const WCHAR szStorages[] = {'_','S','t','o','r','a','g','e','s',0};
|
2010-11-11 10:45:42 +01:00
|
|
|
static const WCHAR szMsiPublishAssemblies[] = {'M','s','i','P','u','b','l','i','s','h','A','s','s','e','m','b','l','i','e','s',0};
|
2018-07-30 04:16:20 +02:00
|
|
|
static const WCHAR szMsiUnpublishAssemblies[] = {'M','s','i','U','n','p','u','b','l','i','s','h','A','s','s','e','m','b','l','i','e','s',0};
|
2011-04-01 14:54:12 +02:00
|
|
|
static const WCHAR szCostingComplete[] = {'C','o','s','t','i','n','g','C','o','m','p','l','e','t','e',0};
|
2011-05-02 16:04:25 +02:00
|
|
|
static const WCHAR szTempFolder[] = {'T','e','m','p','F','o','l','d','e','r',0};
|
|
|
|
static const WCHAR szDatabase[] = {'D','A','T','A','B','A','S','E',0};
|
|
|
|
static const WCHAR szCRoot[] = {'C',':','\\',0};
|
|
|
|
static const WCHAR szProductLanguage[] = {'P','r','o','d','u','c','t','L','a','n','g','u','a','g','e',0};
|
|
|
|
static const WCHAR szProductVersion[] = {'P','r','o','d','u','c','t','V','e','r','s','i','o','n',0};
|
|
|
|
static const WCHAR szWindowsInstaller[] = {'W','i','n','d','o','w','s','I','n','s','t','a','l','l','e','r',0};
|
|
|
|
static const WCHAR szStringData[] = {'_','S','t','r','i','n','g','D','a','t','a',0};
|
|
|
|
static const WCHAR szStringPool[] = {'_','S','t','r','i','n','g','P','o','o','l',0};
|
|
|
|
static const WCHAR szInstallLevel[] = {'I','N','S','T','A','L','L','L','E','V','E','L',0};
|
|
|
|
static const WCHAR szCostInitialize[] = {'C','o','s','t','I','n','i','t','i','a','l','i','z','e',0};
|
2011-05-06 14:39:17 +02:00
|
|
|
static const WCHAR szAppDataFolder[] = {'A','p','p','D','a','t','a','F','o','l','d','e','r',0};
|
2011-05-20 12:33:16 +02:00
|
|
|
static const WCHAR szRollbackDisabled[] = {'R','o','l','l','b','a','c','k','D','i','s','a','b','l','e','d',0};
|
2011-07-27 10:53:10 +02:00
|
|
|
static const WCHAR szName[] = {'N','a','m','e',0};
|
|
|
|
static const WCHAR szData[] = {'D','a','t','a',0};
|
2012-04-23 15:47:15 +02:00
|
|
|
static const WCHAR szLangResource[] = {'\\','V','a','r','F','i','l','e','I','n','f','o','\\','T','r','a','n','s','l','a','t','i','o','n',0};
|
2012-08-01 11:55:22 +02:00
|
|
|
static const WCHAR szInstallLocation[] = {'I','n','s','t','a','l','l','L','o','c','a','t','i','o','n',0};
|
2014-11-04 10:57:40 +01:00
|
|
|
static const WCHAR szProperty[] = {'P','r','o','p','e','r','t','y',0};
|
2017-04-19 11:26:49 +02:00
|
|
|
static const WCHAR szUninstallable[] = {'U','n','i','n','s','t','a','l','l','a','b','l','e',0};
|
2017-09-14 08:03:53 +02:00
|
|
|
static const WCHAR szEXECUTEACTION[] = {'E','X','E','C','U','T','E','A','C','T','I','O','N',0};
|
2018-06-18 20:13:14 +02:00
|
|
|
static const WCHAR szProductToBeRegistered[] = {'P','r','o','d','u','c','t','T','o','B','e','R','e','g','i','s','t','e','r','e','d',0};
|
2006-10-10 13:03:52 +02:00
|
|
|
|
2005-09-20 13:57:19 +02:00
|
|
|
/* memory allocation macro functions */
|
2008-09-04 13:39:58 +02:00
|
|
|
static void *msi_alloc( size_t len ) __WINE_ALLOC_SIZE(1);
|
2005-09-20 13:57:19 +02:00
|
|
|
static inline void *msi_alloc( size_t len )
|
|
|
|
{
|
|
|
|
return HeapAlloc( GetProcessHeap(), 0, len );
|
|
|
|
}
|
|
|
|
|
2008-09-04 13:39:58 +02:00
|
|
|
static void *msi_alloc_zero( size_t len ) __WINE_ALLOC_SIZE(1);
|
2005-09-20 13:57:19 +02:00
|
|
|
static inline void *msi_alloc_zero( size_t len )
|
|
|
|
{
|
|
|
|
return HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, len );
|
|
|
|
}
|
|
|
|
|
2008-09-04 13:39:58 +02:00
|
|
|
static void *msi_realloc( void *mem, size_t len ) __WINE_ALLOC_SIZE(2);
|
2005-09-20 13:57:19 +02:00
|
|
|
static inline void *msi_realloc( void *mem, size_t len )
|
|
|
|
{
|
|
|
|
return HeapReAlloc( GetProcessHeap(), 0, mem, len );
|
|
|
|
}
|
|
|
|
|
2008-09-04 13:39:58 +02:00
|
|
|
static void *msi_realloc_zero( void *mem, size_t len ) __WINE_ALLOC_SIZE(2);
|
2005-09-20 13:57:19 +02:00
|
|
|
static inline void *msi_realloc_zero( void *mem, size_t len )
|
|
|
|
{
|
|
|
|
return HeapReAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, mem, len );
|
|
|
|
}
|
|
|
|
|
|
|
|
static inline BOOL msi_free( void *mem )
|
|
|
|
{
|
|
|
|
return HeapFree( GetProcessHeap(), 0, mem );
|
|
|
|
}
|
|
|
|
|
2007-03-22 19:21:52 +01:00
|
|
|
static inline char *strdupWtoA( LPCWSTR str )
|
2005-03-16 12:31:35 +01:00
|
|
|
{
|
|
|
|
LPSTR ret = NULL;
|
2005-09-20 13:57:19 +02:00
|
|
|
DWORD len;
|
|
|
|
|
|
|
|
if (!str) return ret;
|
|
|
|
len = WideCharToMultiByte( CP_ACP, 0, str, -1, NULL, 0, NULL, NULL);
|
|
|
|
ret = msi_alloc( len );
|
|
|
|
if (ret)
|
|
|
|
WideCharToMultiByte( CP_ACP, 0, str, -1, ret, len, NULL, NULL );
|
2005-03-16 12:31:35 +01:00
|
|
|
return ret;
|
|
|
|
}
|
|
|
|
|
2007-03-22 19:21:52 +01:00
|
|
|
static inline LPWSTR strdupAtoW( LPCSTR str )
|
2005-03-16 12:31:35 +01:00
|
|
|
{
|
|
|
|
LPWSTR ret = NULL;
|
2005-09-20 13:57:19 +02:00
|
|
|
DWORD len;
|
|
|
|
|
|
|
|
if (!str) return ret;
|
|
|
|
len = MultiByteToWideChar( CP_ACP, 0, str, -1, NULL, 0 );
|
|
|
|
ret = msi_alloc( len * sizeof(WCHAR) );
|
|
|
|
if (ret)
|
|
|
|
MultiByteToWideChar( CP_ACP, 0, str, -1, ret, len );
|
2005-03-16 12:31:35 +01:00
|
|
|
return ret;
|
|
|
|
}
|
|
|
|
|
2007-03-22 19:21:52 +01:00
|
|
|
static inline LPWSTR strdupW( LPCWSTR src )
|
2005-03-16 12:31:35 +01:00
|
|
|
{
|
|
|
|
LPWSTR dest;
|
|
|
|
if (!src) return NULL;
|
2005-09-20 13:57:19 +02:00
|
|
|
dest = msi_alloc( (lstrlenW(src)+1)*sizeof(WCHAR) );
|
|
|
|
if (dest)
|
|
|
|
lstrcpyW(dest, src);
|
2005-03-16 12:31:35 +01:00
|
|
|
return dest;
|
|
|
|
}
|
|
|
|
|
2003-08-13 03:27:48 +02:00
|
|
|
#endif /* __WINE_MSI_PRIVATE__ */
|