JBoss Native SVN: r1520 - trunk/build/install/installer.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-04 12:22:22 -0400 (Fri, 04 Apr 2008)
New Revision: 1520
Modified:
trunk/build/install/installer/main.c
Log:
Use mktemp from xtools and add eula page
Modified: trunk/build/install/installer/main.c
===================================================================
--- trunk/build/install/installer/main.c 2008-04-04 16:17:51 UTC (rev 1519)
+++ trunk/build/install/installer/main.c 2008-04-04 16:22:22 UTC (rev 1520)
@@ -38,6 +38,8 @@
#include "crypt.h"
#include "unzvers.h"
+#define DEF_WWIDTH 505
+#define DEF_WHEIGHT 360
#define MAX_CMDLINE 16384
#define IS_INVALID_HANDLE(x) (((x) == NULL || (x) == INVALID_HANDLE_VALUE))
@@ -69,7 +71,7 @@
static LPSTR szProgramName = NULL;
static LPSTR szProgramPath = NULL;
-static CHAR szTempPath[MAX_PATH] = { 0 };
+static LPSTR szTempPath = NULL;
static int c_errno_table[] = {
@@ -165,15 +167,16 @@
return c_errno_table[err];
}
-static void x_perror(const char *msg)
+static void x_perror(int err, const char *msg)
{
- int err = errno;
+ if (err == 0)
+ err = x_cerror(errno);
- errno = x_cerror(err);
-
#ifdef _CONSOLE
- if (!opt_Quiet)
+ if (!opt_Quiet) {
+ errno = err;
perror(msg);
+ }
if (opt_Verbose)
fprintf(stderr, "(%s): exit(%d)\n", GetProgramName(), err);
#else
@@ -196,7 +199,7 @@
void *ptr = calloc(1, len);
if (!ptr) {
- x_perror("Malloc");
+ x_perror(0, "Malloc");
}
return ptr;
}
@@ -245,6 +248,121 @@
return x_strdup(full);
}
+/*
+ * Replacement for the strncpy() function. We roll our
+ * own to implement these specific changes:
+ * (1) strncpy() doesn't always null terminate and we want it to.
+ * (2) strncpy() null fills, which is bogus, esp. when copy 8byte
+ * strings into 8k blocks.
+ * (3) Instead of returning the pointer to the beginning of
+ * the destination string, we return a pointer to the
+ * terminating '\0' to allow us to "check" for truncation
+ *
+ * x_strncpy() follows the same call structure as strncpy().
+ */
+static char *x_strncpy(char *d, const char *s, size_t l)
+{
+ char *dst, *end;
+ if (l == 0)
+ return d;
+ if (s == NULL) {
+ *d = '\0';
+ return d;
+ }
+ dst = d;
+ end = d + l - 1;
+
+ for (; dst < end; ++dst, ++s) {
+ if (!(*dst = *s))
+ return dst;
+ }
+
+ *dst = '\0'; /* always null terminate */
+ return dst;
+}
+
+static const unsigned char padchar[] =
+"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
+static int randseed = 0;
+
+static char *x_mktemp(const char *pattern, int file)
+{
+ char path[MAX_PATH] = { 0 };
+ int randnum;
+ char pbuf[MAX_PATH];
+ register char *start, *trv, *suffp;
+
+ if (pattern)
+ x_strncpy(pbuf, pattern, MAX_PATH);
+ else
+ strcpy(pbuf, "_sx.XXXXXXXX");
+
+ if (GetTempPathA(MAX_PATH - strlen(pbuf) - 1, path) == 0) {
+ x_perror(0, "Temp Path");
+ return NULL;
+ }
+ strcat(path, pbuf);
+ for (trv = path; *trv; ++trv)
+ ;
+ suffp = trv;
+ --trv;
+ if (trv < path) {
+ x_perror(EINVAL, "Temp Path");
+ return NULL;
+ }
+
+ if (randseed == 0) {
+ randseed = (int)time(NULL);
+ srand(randseed);
+ }
+ /* Fill space with random characters */
+ while (*trv == 'X') {
+ randnum = rand() % (sizeof(padchar) - 1);
+ *trv-- = padchar[randnum];
+ }
+ start = trv + 1;
+
+ for (;;) {
+ if (access(path, 0)) {
+ if (errno == ENOENT) {
+ if (file) {
+ FILE *fp = fopen(path, "w");
+ if (!fp) {
+ x_perror(0, path);
+ return NULL;
+ }
+ fclose(fp);
+ }
+ else {
+ if (mkdir(path)) {
+ x_perror(0, path);
+ return NULL;
+ }
+ }
+ return x_strdup(path);
+ }
+ }
+ /* If we have a collision, cycle through the space of filenames */
+ for (trv = start;;) {
+ char *pad;
+ if (*trv == '\0' || trv == suffp) {
+ x_perror(ENOENT, "Temp Path");
+ return NULL;
+ }
+ pad = strchr((char *)padchar, *trv);
+ if (pad == NULL || !*++pad) {
+ *trv++ = padchar[0];
+ }
+ else {
+ *trv++ = *pad;
+ break;
+ }
+ }
+
+ }
+ return NULL;
+}
+
LPCSTR
GetProgramName()
{
@@ -546,21 +664,21 @@
}
static BOOL
-AcceptLicensePage()
+AcceptLicensePage(LPCSTR szPage)
{
HANDLE hHtml;
CHAR sBuf[MAX_PATH] = { 0 };
CHAR *retVal;
BOOL rv = FALSE;
- hHtml = DHTMLDialogInit(GetModuleHandle(NULL), "/HTML_LGPLMAIN");
+ hHtml = DHTMLDialogInit(GetModuleHandle(NULL), szPage);
if (IS_INVALID_HANDLE(hHtml))
return FALSE;
sprintf(sBuf, "%s", GetProgramName());
DHTMLDialogRun(NULL, hHtml,
GuiLoadResource(IDS_LICTITLE, 0),
- 505, 360, 0, INFINITE,
+ DEF_WWIDTH, DEF_WHEIGHT, 0, INFINITE,
sBuf);
retVal = DHTMLDialogResult(hHtml);
if (retVal && !strncmp(retVal, "OK", 2)) {
@@ -608,7 +726,7 @@
if (fp) {
if (retVal && *retVal) {
if (!strncmp(retVal, "OK", 2))
- rv = TRUE;
+ rv = TRUE;
fputs(retVal, fp);
}
else
@@ -627,8 +745,9 @@
if (cleanup++)
return;
- if (szTempPath[0])
+ if (szTempPath)
SXDeleteDirectory(szTempPath);
+ x_free(szTempPath);
GuiTerminate();
}
@@ -664,7 +783,7 @@
int nShowCmd)
{
#endif
- int i, r, ch;
+ int r, ch;
int ap = 1;
size_t l;
BOOL selectDest = TRUE;
@@ -678,21 +797,22 @@
LPSTR szHtmlTitle = NULL;
LPSTR szHtmlParams = NULL;
LPSTR szHtmlResult = NULL;
- DWORD dwHtmlWidth = 505;
- DWORD dwHtmlHeight = 360;
- DWORD dwTimeout = INFINITE;
+ DWORD dwHtmlWidth = DEF_WWIDTH;
+ DWORD dwHtmlHeight = DEF_WHEIGHT;
+ DWORD dwWinTimeout = INFINITE;
DWORD dwFlags = 0;
PROCESS_INFORMATION prInfo;
-
+ LPCSTR szEulaPage = "/HTML_EULAMAIN";
+
atexit(ExitCleanup);
if (!GuiInitialize()) {
exit(-1);
}
- while ((ch = getopt(__argc, __argv, "aAd:f:h:n:p:qQr:st:vVw:")) != EOF) {
+ while ((ch = getopt(__argc, __argv, "aAd:f:gh:n:p:qQr:st:vVw:")) != EOF) {
switch (ch) {
+ case 'A':
case 'a':
- case 'A':
GuiAboutBox(NULL);
r = 0;
goto cleanup;
@@ -712,6 +832,9 @@
opt_Verbose = TRUE;
#endif
break;
+ case 'g':
+ szEulaPage = "/HTML_LGPLMAIN";
+ break;
case 'd':
if (*optarg != '~') {
if (x_fullpath(optarg, szDest))
@@ -742,7 +865,7 @@
}
break;
case 't':
- dwTimeout = (DWORD)atoi(optarg);
+ dwWinTimeout = (DWORD)atoi(optarg);
break;
case 'w':
dwHtmlWidth = (DWORD)atoi(optarg);
@@ -762,14 +885,14 @@
if (szHtmlPage) {
if (!szHtmlTitle) {
r = EINVAL;
- goto cleanup;
+ goto cleanup;
}
if (RunCustomPage(szHtmlPage,
szHtmlTitle,
szHtmlParams,
dwHtmlWidth,
dwHtmlHeight,
- dwTimeout,
+ dwWinTimeout,
dwFlags,
szHtmlResult)) {
r = 0;
@@ -780,10 +903,11 @@
x_free(szHtmlTitle);
x_free(szHtmlParams);
x_free(szHtmlResult);
- goto cleanup;
+ goto cleanup;
}
+
/* Standard Install */
- if (!opt_Quiet && !AcceptLicensePage()) {
+ if (!opt_Quiet && !AcceptLicensePage(szEulaPage)) {
r = EPERM;
goto cleanup;
}
@@ -805,7 +929,7 @@
msg,
FALSE)) {
if (SXCreateDirectory(szDest)) {
- x_perror(szDest);
+ x_perror(0, szDest);
}
}
else {
@@ -814,7 +938,7 @@
}
}
else {
- x_perror(szDest);
+ x_perror(0, szDest);
}
}
if (GetSystemDirectory(szBuf, MAX_PATH - 20)) {
@@ -828,31 +952,12 @@
strcpy(szCmdExe, szBuf);
}
else {
- x_perror("System Directory");
+ x_perror(0, "System Directory");
}
- if (GetTempPathA(MAX_PATH - 20, szBuf) == 0) {
- x_perror("Temp Path");
+ if (!(szTempPath = x_mktemp(NULL, 0))) {
+ x_perror(EPERM, "Creating Temp directory");
}
- for (i = 0; i < 100; i++) {
- CHAR szTmp[MAX_PATH];
- if (GetTempFileName(szBuf, "_sx", _getpid(), szTmp) == 0) {
- x_perror("Temp File");
- }
- if (!mkdir(szTmp)) {
- strcpy(szTempPath, szTmp);
- break;
- }
- else {
- if (errno != EEXIST) {
- x_perror("Creating Temp directory");
- }
- }
- }
- if (!szTempPath[0]) {
- errno = EPERM;
- x_perror("Creating Temp directory");
- }
strcpy(szWorkDir, szTempPath);
strcat(szWorkDir, DIR_BATCH);
ppUnizpArgs[3] = szTempPath;
@@ -864,8 +969,7 @@
r = unzip(4, ppUnizpArgs);
if (r != 0) {
SetLastError(ERROR_INVALID_BLOCK);
- errno = EINVAL;
- x_perror("Uncompressing");
+ x_perror(EINVAL, "Uncompressing");
}
DESTROYGLOBALS();
szCmdLine = BuildCommandLine(szCmdExe,
16 years, 6 months
JBoss Native SVN: r1519 - trunk/build/install/xtool.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-04 12:17:51 -0400 (Fri, 04 Apr 2008)
New Revision: 1519
Added:
trunk/build/install/xtool/commonc.manifest
Modified:
trunk/build/install/xtool/NMAKEmakefile
trunk/build/install/xtool/xtool.c
trunk/build/install/xtool/xtool.rc
Log:
Add html page display tool
Modified: trunk/build/install/xtool/NMAKEmakefile
===================================================================
--- trunk/build/install/xtool/NMAKEmakefile 2008-04-04 06:18:32 UTC (rev 1518)
+++ trunk/build/install/xtool/NMAKEmakefile 2008-04-04 16:17:51 UTC (rev 1519)
@@ -30,8 +30,11 @@
!ENDIF
LFLAGS = $(LFLAGS) /version:1.0
-LFLAGS = $(LFLAGS) user32.lib shell32.lib advapi32.lib psapi.lib imagehlp.lib version.lib
+LFLAGS = $(LFLAGS) user32.lib gdi32.lib winspool.lib comdlg32.lib comctl32.lib
+LFLAGS = $(LFLAGS) shlwapi.lib netapi32.lib shell32.lib ole32.lib urlmon.lib
+LFLAGS = $(LFLAGS) oleaut32.lib psapi.lib version.lib advapi32.lib imagehlp.lib
+
PDBFLAGS = -Fo$(WORKDIR)\ -Fd$(WORKDIR)\$(PROJECT)-src
OBJECTS = \
$(WORKDIR)\xtool.obj
Added: trunk/build/install/xtool/commonc.manifest
===================================================================
--- trunk/build/install/xtool/commonc.manifest (rev 0)
+++ trunk/build/install/xtool/commonc.manifest 2008-04-04 16:17:51 UTC (rev 1519)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+<assemblyIdentity version="3.1.0.0" processorArchitecture="*" name="JBoss Installer" type="win32" />
+<description>JBoss Windows Installer</description>
+<dependency>
+<dependentAssembly>
+<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*" />
+</dependentAssembly>
+</dependency>
+</assembly>
Property changes on: trunk/build/install/xtool/commonc.manifest
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: trunk/build/install/xtool/xtool.c
===================================================================
--- trunk/build/install/xtool/xtool.c 2008-04-04 06:18:32 UTC (rev 1518)
+++ trunk/build/install/xtool/xtool.c 2008-04-04 16:17:51 UTC (rev 1519)
@@ -54,10 +54,20 @@
#define _WIN32_WINNT 0x0500
#endif
#include <windows.h>
+#include <windowsx.h>
+#include <commdlg.h>
+#include <commctrl.h>
+#include <objbase.h>
+#include <shlobj.h>
+#include <shlwapi.h>
#include <shellapi.h>
+#include <zmouse.h>
+#include <richedit.h>
#include <psapi.h>
-#include <shlobj.h>
#include <imagehlp.h>
+#include <urlmon.h>
+#include <mshtmhst.h>
+#include <lm.h>
#include <stdio.h>
#include <stdlib.h>
@@ -92,7 +102,16 @@
/* This is used to cache lengths in x_strvcat */
#define MAX_SAVED_LENGTHS 8
+/* Resource definitions from .rc file */
+#define IDI_MAINICON 101
+#define IDI_RHELICON 102
+#define DEF_WWIDTH 505
+#define DEF_WHEIGHT 360
+#define SIZ_BUFLEN 1024
+#define SIZ_BUFMAX (SIZ_BUFLEN - 1)
+#define IS_INVALID_HANDLE(x) (((x) == NULL || (x) == INVALID_HANDLE_VALUE))
+
/*
* Alignment macros
*/
@@ -157,7 +176,7 @@
static int xtools_pause = 0;
static SYSTEM_INFO win_osinf;
static OSVERSIONINFOEXA win_osver;
-static int verbose = 0;
+static int xtrace = 0;
static int xquiet = 0;
/*
@@ -1525,7 +1544,7 @@
DWORD el = ExpandEnvironmentStringsW(ibuf, ebuf,
INFO_BUFFER_SIZE);
if (el > INFO_BUFFER_SIZE) {
- if (verbose)
+ if (xtrace)
warnx("expansion string to large %d", el);
}
else if (el) {
@@ -1693,7 +1712,7 @@
if (!CreateDirectoryW(path, NULL)) {
r = x_cerror(GetLastError());
if (r == EEXIST) {
- if (verbose)
+ if (xtrace)
warnx("cannot create directory '%S': %s",
path, cstrerror(EEXIST));
return EEXIST;
@@ -1702,14 +1721,14 @@
return ENOENT;
}
else {
- if (verbose)
+ if (xtrace)
warnx("cannot create directory '%S': %s",
path, cstrerror(r));
return r;
}
}
else {
- if (verbose)
+ if (xtrace > 1)
warnx("created directory '%S'", path);
return 0;
}
@@ -1769,7 +1788,7 @@
}
if (!RemoveDirectoryW(path))
r = x_cerror(GetLastError());
- if (verbose) {
+ if (xtrace) {
if (r)
warnx("cannot remove directory '%S': %s",
path, cstrerror(r));
@@ -1811,7 +1830,7 @@
if (!RemoveDirectoryW(path))
r = x_cerror(GetLastError());
}
- if (verbose) {
+ if (xtrace) {
if (r)
warnx("cannot remove directory '%s': %s",
loc, cstrerror(r));
@@ -1843,7 +1862,7 @@
FOF_SILENT;
r = x_cerror(SHFileOperationW(&op));
- if (verbose) {
+ if (xtrace) {
if (r)
warnx("cannot remove file '%s': %s",
loc, cstrerror(r));
@@ -1861,11 +1880,11 @@
wchar_t path[X_MAX_PATH];
int r = 0;
- if (r = x_wfullpath(path, X_MAX_PATH, src))
+ if ((r = x_wfullpath(path, X_MAX_PATH, src)))
return r;
if (!GetFileAttributesExW(path, GetFileExInfoStandard, pa)) {
r = x_cerror(GetLastError());
- if (verbose && r != ENOENT) {
+ if (xtrace && r != ENOENT) {
warnx("cannot stat file '%S': %s",
path, cstrerror(errno));
}
@@ -1873,6 +1892,27 @@
return r;
}
+static int x_fattrib(const char *src)
+{
+
+ WIN32_FILE_ATTRIBUTE_DATA pa;
+ wchar_t path[X_MAX_PATH];
+ int r = 0;
+
+ if ((errno = x_wfullpath(path, X_MAX_PATH, src))) {
+ return 0;
+ }
+ if (!GetFileAttributesExW(path, GetFileExInfoStandard, &pa)) {
+ errno = x_cerror(GetLastError());
+ return 0;
+ }
+ if (pa.dwFileAttributes)
+ return (int)pa.dwFileAttributes;
+ else
+ return FILE_ATTRIBUTE_ARCHIVE;
+}
+
+
/*
* ---------------------------------------------------------------------
* end of file functions
@@ -1950,7 +1990,7 @@
int nextline = 0;
if (!(fp = x_fopen(fname, "rt"))) {
- if (verbose)
+ if (xtrace)
warnx("'%s' %s", fname, cstrerror(errno));
return NULL;
}
@@ -1982,7 +2022,7 @@
if (*line == '[') {
char *ends = strchr(++line, ']');
if (!ends) {
- if (verbose)
+ if (xtrace)
warnx("'%s' unterminated section at line %d",
fname, counter);
goto cleanup;
@@ -1994,7 +2034,7 @@
ini->name = x_strdup(section);
}
else {
- if (verbose > 1)
+ if (xtrace > 1)
warnx("'%s' duplicate section at line %d",
fname, counter);
}
@@ -2018,7 +2058,7 @@
line = rltrim(line);
if (!*line) {
/* Skip entries without keys **/
- if (verbose > 1)
+ if (xtrace > 1)
warnx("'%s' missing key at line %d",
fname, counter);
nextline = 0;
@@ -2217,6 +2257,495 @@
/*
* ---------------------------------------------------------------------
+ * begin of WIndows GUI
+ * ---------------------------------------------------------------------
+ */
+
+#define MGUI_WINDOWS 32
+
+HICON gui_h16Icon = NULL;
+HICON gui_h32Icon = NULL;
+HICON gui_h48Icon = NULL;
+HMODULE gui_hMSHTML = NULL;
+HWND gui_DialogWnd = NULL;
+static HINSTANCE gui_hInstance = NULL;
+static HWND gui_hMainWnd = NULL;
+static HMODULE gui_hRichedit = NULL;
+
+static UINT gui_ucNumLines = 3;
+static CHAR gui_szWndClass[MAX_PATH];
+
+
+static HWND gui_Windows[MGUI_WINDOWS];
+
+static int
+GuiRegisterWindow(HWND hWnd)
+{
+ int i;
+ for (i = 0; i < MGUI_WINDOWS; i++) {
+ if (!gui_Windows[i]) {
+ gui_Windows[i] = hWnd;
+ return i;
+ }
+ }
+ return -1;
+}
+
+static void
+GuiUnregisterWindow(int nIndex)
+{
+ if (nIndex >= 0 && nIndex < MGUI_WINDOWS)
+ gui_Windows[nIndex] = NULL;
+}
+
+static BOOL
+GuiInitialize()
+{
+ int i;
+ INITCOMMONCONTROLSEX stCmn;
+
+ CoInitializeEx(NULL, COINIT_APARTMENTTHREADED);
+ gui_hInstance = GetModuleHandle(NULL);
+ stCmn.dwSize = sizeof(INITCOMMONCONTROLSEX);
+ stCmn.dwICC = ICC_WIN95_CLASSES | ICC_USEREX_CLASSES |
+ ICC_COOL_CLASSES | ICC_NATIVEFNTCTL_CLASS |
+ ICC_INTERNET_CLASSES | ICC_PAGESCROLLER_CLASS |
+ ICC_BAR_CLASSES;
+
+ InitCommonControlsEx(&stCmn);
+ gui_hRichedit = LoadLibraryA("RICHED32.DLL");
+ gui_hMSHTML = LoadLibraryA("MSHTML.DLL");
+
+ gui_h16Icon = LoadImage(gui_hInstance, MAKEINTRESOURCE(IDI_MAINICON),
+ IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+ gui_h32Icon = LoadImage(gui_hInstance, MAKEINTRESOURCE(IDI_MAINICON),
+ IMAGE_ICON, 32, 32, LR_DEFAULTCOLOR);
+ gui_h48Icon = LoadImage(gui_hInstance, MAKEINTRESOURCE(IDI_RHELICON),
+ IMAGE_ICON, 48, 48, LR_DEFAULTCOLOR);
+
+ SystemParametersInfo(SPI_GETWHEELSCROLLLINES, 0,
+ &gui_ucNumLines, 0);
+ for (i = 0; i < MGUI_WINDOWS; i++)
+ gui_Windows[i] = NULL;
+ return TRUE;
+}
+
+static BOOL
+GuiTerminate()
+{
+ int i;
+ for (i = 0; i < MGUI_WINDOWS; i++) {
+ if (gui_Windows[i]) {
+ SendMessage(gui_Windows[i], WM_CLOSE, 0, 0);
+ gui_Windows[i] = NULL;
+ }
+ }
+ FreeLibrary(gui_hRichedit);
+ FreeLibrary(gui_hMSHTML);
+
+ return TRUE;
+}
+
+/**
+ * Load the resource string with the ID given, and return a
+ * pointer to it. Notice that the buffer is common memory so
+ * the string must be used before this call is made a second time.
+ */
+static LPSTR
+GuiLoadResource(
+ UINT wID,
+ UINT nBuf)
+{
+ static CHAR szBuf[4][SIZ_BUFLEN];
+ if (nBuf > 3)
+ return "";
+ if (LoadStringA(gui_hInstance, wID, szBuf[nBuf], SIZ_BUFMAX) > 0)
+ return szBuf[nBuf];
+ else
+ return "";
+}
+
+static void
+GuiCenterWindow(HWND hWnd)
+{
+ RECT rc, rw;
+ int cw, ch;
+ int px, py;
+
+ /* Get the Height and Width of the child window */
+ GetWindowRect(hWnd, &rc);
+ cw = rc.right - rc.left;
+ ch = rc.bottom - rc.top;
+
+ /* Get the limits of the 'workarea' */
+ if (!SystemParametersInfo(SPI_GETWORKAREA,
+ sizeof(RECT),
+ &rw,
+ 0)) {
+ rw.left = rw.top = 0;
+ rw.right = GetSystemMetrics(SM_CXSCREEN);
+ rw.bottom = GetSystemMetrics(SM_CYSCREEN);
+ }
+
+ /* Calculate new X and Y position*/
+ px = (rw.right - cw) / 2;
+ py = (rw.bottom - ch) / 2;
+ SetWindowPos(hWnd, HWND_TOP, px, py, 0, 0,
+ SWP_NOSIZE | SWP_SHOWWINDOW);
+}
+
+static BOOL
+GuiBrowseForFolder(
+ HWND hWnd,
+ LPCSTR szTitle,
+ LPSTR szPath)
+{
+ BOOL rv = FALSE;
+
+ BROWSEINFO bi;
+ ITEMIDLIST *il , *ir;
+ LPMALLOC pMalloc;
+
+ memset(&bi, 0, sizeof(BROWSEINFO));
+ SHGetSpecialFolderLocation(hWnd, CSIDL_DRIVES, &il);
+
+ bi.lpszTitle = szTitle;
+ bi.pszDisplayName = szPath;
+ bi.hwndOwner = hWnd;
+ bi.ulFlags = BIF_USENEWUI;
+ bi.pidlRoot = il;
+
+ if ((ir = SHBrowseForFolder(&bi)) != NULL) {
+ SHGetPathFromIDList(ir, szPath);
+ rv = TRUE;
+ }
+ if (SHGetMalloc(&pMalloc)) {
+ pMalloc->lpVtbl->Free(pMalloc, il);
+ pMalloc->lpVtbl->Release(pMalloc);
+ }
+ return rv;
+}
+
+#define HBUF_SIZE 8192
+#define MBUF_SIZE 4096
+
+static SHOWHTMLDIALOGEXFN *pfnShowHTMLDialog = NULL;
+
+typedef struct {
+ IMoniker *lpImk;
+ CHAR szReturnVal[HBUF_SIZE];
+} MC_HTML_DIALOG, *LPMC_HTML_DIALOG;
+
+typedef struct DHTML_THREAD_PARAMS {
+ BOOL bDone;
+ HWND hParent;
+ LPMC_HTML_DIALOG hHtmlDlg;
+ WCHAR szOptions[1024];
+ WCHAR szArguments[MBUF_SIZE];
+} DHTML_THREAD_PARAMS;
+
+static LPWSTR
+AnsiToWide(
+ LPCSTR szAnsi,
+ LPWSTR szWide,
+ DWORD dwLength)
+{
+
+ if (!szWide) {
+ dwLength = MultiByteToWideChar(CP_ACP, 0, szAnsi, -1, NULL, 0);
+ if (dwLength == 0)
+ return NULL;
+ if (!(szWide = (LPWSTR)calloc(sizeof(WCHAR), (dwLength + 1))))
+ return NULL;
+ }
+ if (MultiByteToWideChar(CP_ACP, 0, szAnsi, -1,
+ szWide, dwLength))
+ return szWide;
+ else
+ return NULL;
+}
+
+static LPSTR
+WideToAnsi(
+ LPCWSTR szWide,
+ LPSTR szAnsi,
+ DWORD dwLength)
+{
+ if (!szAnsi) {
+ dwLength = WideCharToMultiByte(CP_ACP, 0, szWide, -1,
+ NULL, 0, NULL, NULL);
+ if (dwLength == 0)
+ return NULL;
+ if (!(szAnsi = (LPSTR)calloc(sizeof(CHAR), (dwLength + 1))))
+ return NULL;
+ }
+
+ if (WideCharToMultiByte(CP_ACP, 0, szWide, -1,
+ szAnsi, dwLength, NULL, NULL))
+ return szAnsi;
+ else
+ return NULL;
+
+}
+
+static HANDLE
+DHTMLDialogInit(
+ HINSTANCE hResInstance,
+ LPCSTR szHtml)
+{
+ LPMC_HTML_DIALOG hDlg;
+ OLECHAR bstr[MAX_PATH];
+
+ hDlg = (LPMC_HTML_DIALOG)calloc(1, sizeof(MC_HTML_DIALOG));
+
+ if (!hDlg)
+ return INVALID_HANDLE_VALUE;
+
+ if (!gui_hMSHTML)
+ goto cleanup;
+ if (!pfnShowHTMLDialog)
+ pfnShowHTMLDialog = (SHOWHTMLDIALOGEXFN*)GetProcAddress(
+ gui_hMSHTML,
+ "ShowHTMLDialogEx");
+ if (!pfnShowHTMLDialog)
+ goto cleanup;
+
+ if (hResInstance) {
+ CHAR szTemp[MAX_PATH];
+ strcpy(szTemp, "res://");
+ GetModuleFileNameA(hResInstance, szTemp + strlen(szTemp),
+ ARRAYSIZE(szTemp) - strlen(szTemp));
+ if (*szHtml != '/')
+ strcat(szTemp, "/");
+ strcat(szTemp, szHtml);
+ AnsiToWide(szTemp, bstr, ARRAYSIZE(bstr));
+ }
+ else
+ AnsiToWide(szHtml, bstr, ARRAYSIZE(bstr));
+ CreateURLMoniker(NULL, bstr, &hDlg->lpImk);
+
+ if (!hDlg->lpImk)
+ goto cleanup;
+ return hDlg;
+cleanup:
+
+ free(hDlg);
+ return INVALID_HANDLE_VALUE;
+}
+
+static void
+DHTMLDialogClose(
+ HANDLE hHtmlDlg)
+{
+
+ LPMC_HTML_DIALOG hDlg = (LPMC_HTML_DIALOG)hHtmlDlg;
+ if (IS_INVALID_HANDLE(hHtmlDlg))
+ return;
+ hDlg->lpImk->lpVtbl->Release(hDlg->lpImk);
+ free(hDlg);
+}
+
+static DWORD WINAPI
+dhtmlRunThread(LPVOID lpParam)
+{
+ DWORD rv = ERROR_SUCCESS;
+ HRESULT hr;
+ VARIANT varArgs, varReturn;
+ DHTML_THREAD_PARAMS *pD = (DHTML_THREAD_PARAMS *)lpParam;
+ LPMC_HTML_DIALOG hDlg = pD->hHtmlDlg;
+
+ if (IS_INVALID_HANDLE(pD->hHtmlDlg)) {
+ rv = ERROR_INVALID_HANDLE;
+ goto cleanup;
+ }
+ VariantInit(&varReturn);
+ varArgs.vt = VT_BSTR;
+ varArgs.bstrVal = SysAllocString(pD->szArguments);
+ hr = (*pfnShowHTMLDialog)(pD->hParent,
+ hDlg->lpImk,
+ HTMLDLG_MODAL | HTMLDLG_VERIFY,
+ &varArgs,
+ pD->szOptions,
+ &varReturn);
+ VariantClear(&varArgs);
+ if (SUCCEEDED(hr)) {
+ switch(varReturn.vt) {
+ case VT_BSTR:
+ WideToAnsi(varReturn.bstrVal, hDlg->szReturnVal, HBUF_SIZE);
+ break;
+ }
+ VariantClear(&varReturn);
+ rv = ERROR_SUCCESS;
+ }
+ else
+ rv = GetLastError();
+cleanup:
+ pD->bDone = TRUE;
+ ExitThread(rv);
+ return rv;
+}
+
+static BOOL
+DHTMLDialogRun(
+ HWND hParent,
+ HANDLE hHtmlDlg,
+ LPCSTR szTitle,
+ DWORD dwWidth,
+ DWORD dwHeight,
+ DWORD dwFlags,
+ DWORD dwTimeout,
+ LPCSTR szArguments)
+{
+ DWORD dwThreadId;
+ HANDLE hThread;
+ HWND hWnd = NULL;
+ DWORD i;
+ BOOL rv = FALSE;
+ DHTML_THREAD_PARAMS pD;
+ int w = -1;
+
+ if (IS_INVALID_HANDLE(hHtmlDlg))
+ return FALSE;
+ pD.hParent = hParent;
+ pD.hHtmlDlg = hHtmlDlg;
+ swprintf(pD.szOptions,
+ L"scroll: no; status: no; help: no; dialogHeight: %dpx; dialogWidth: %dpx",
+ dwHeight, dwWidth);
+ if (dwFlags == 1)
+ wcscat(pD.szOptions, L"; unadorned:yes");
+ if (szArguments)
+ AnsiToWide(szArguments, pD.szArguments,
+ ARRAYSIZE(pD.szArguments));
+
+ hThread = CreateThread(NULL,
+ 0,
+ dhtmlRunThread,
+ &pD,
+ 0,
+ &dwThreadId);
+ if (IS_INVALID_HANDLE(hThread))
+ return FALSE;
+
+ /* Hack to change the Icon of HTML Dialog */
+ for (i = 0; i < 1000; i++) {
+ if ((hWnd = FindWindowEx(hParent, NULL, NULL, szTitle))) {
+ w = GuiRegisterWindow(hWnd);
+ SetClassLong(hWnd, GCL_HICONSM, (LONG)gui_h16Icon);
+ break;
+ }
+ if (pD.bDone)
+ break;
+ Sleep(1);
+ }
+ if ((i = WaitForSingleObject(hThread, dwTimeout)) == WAIT_TIMEOUT) {
+ if (hWnd) {
+ SendMessage(hWnd, WM_CLOSE, 0, 0);
+ WaitForSingleObject(hThread, INFINITE);
+ }
+ }
+ if (GetExitCodeThread(hThread, &i) && i == 0) {
+ rv = TRUE;
+ }
+ CloseHandle(hThread);
+ GuiUnregisterWindow(w);
+ return rv;
+}
+
+LPSTR
+DHTMLDialogResult(
+ HANDLE hHtmlDlg)
+{
+
+ LPMC_HTML_DIALOG hDlg = (LPMC_HTML_DIALOG)hHtmlDlg;
+ if (IS_INVALID_HANDLE(hHtmlDlg))
+ return NULL;
+
+ return hDlg->szReturnVal;
+}
+
+static LPSTR
+GetHtmlPath(
+ LPCSTR szWorkDir,
+ LPCSTR szHtmlPage)
+{
+
+ LPSTR p;
+ LPSTR pHtml = (LPSTR)x_malloc(MAX_PATH);
+
+ strcpy(pHtml, "file://");
+ if (szWorkDir) {
+ strcpy(pHtml, szWorkDir);
+ if (*szHtmlPage != '/')
+ strcat(pHtml, "/");
+ }
+ strcat(pHtml, szHtmlPage);
+ for (p = pHtml; *p; p++) {
+ if (*p == '\\')
+ *p = '/';
+ }
+ return pHtml;
+}
+
+static BOOL
+RunCustomPage(
+ LPCSTR szHtmlPage,
+ LPCSTR szHtmlTitle,
+ LPCSTR szHtmlParams,
+ DWORD dwHtmlWidth,
+ DWORD dwHtmlHeight,
+ DWORD dwTimeout,
+ DWORD dwFlags,
+ LPCSTR szFile)
+{
+ HANDLE hHtml;
+ LPSTR szUrl;
+ LPSTR retVal;
+ BOOL rv = FALSE;
+ FILE *fp;
+
+ szUrl = GetHtmlPath(NULL, szHtmlPage);
+ hHtml = DHTMLDialogInit(NULL, szUrl);
+ if (IS_INVALID_HANDLE(hHtml)) {
+ x_free(szUrl);
+ return FALSE;
+ }
+ DHTMLDialogRun(NULL, hHtml,
+ szHtmlTitle,
+ dwHtmlWidth,
+ dwHtmlHeight,
+ dwFlags,
+ dwTimeout,
+ szHtmlParams);
+ retVal = DHTMLDialogResult(hHtml);
+ if (szFile)
+ fp = fopen(szFile, "w");
+ else
+ fp = stdout;
+ if (fp) {
+ if (retVal && *retVal) {
+ if (!strncmp(retVal, "OK", 2))
+ rv = TRUE;
+ fputs(retVal, fp);
+ }
+ else
+ fputs("NULL", fp);
+ fflush(fp);
+ if (fp != stdout)
+ fclose(fp);
+ }
+ x_free(szUrl);
+ DHTMLDialogClose(hHtml);
+ return rv;
+}
+
+/*
+ * ---------------------------------------------------------------------
+ * end of WIndows GUI
+ * ---------------------------------------------------------------------
+ */
+
+/*
+ * ---------------------------------------------------------------------
* begin of tests
* ---------------------------------------------------------------------
*/
@@ -2331,6 +2860,7 @@
fprintf(stderr, " -q Be quiet.\n");
fprintf(stderr, " -v --verbose Explain what is being done.\n");
fprintf(stderr, " --version Output version information and exit.\n");
+ fprintf(stderr, " -V Explain what is being done in detail.\n");
fprintf(stderr, " -h --help Display this help and exit.\n\n");
}
@@ -2427,6 +2957,18 @@
return retval;
}
+static int prog_html_usage(int retval)
+{
+ fprintf(stderr, "Usage: %s [OPTION]... FILE\n", progname);
+ fprintf(stderr, "Update the access and modification times of each FILE to the current time\n\n");
+ fprintf(stderr, " -g STRING Geometry in format 'widthXheight'.\n");
+ fprintf(stderr, " -n STRING Page title. If not present defaults to html <title> tag.\n");
+ fprintf(stderr, " -t NUMBER Splash page with NUMBER of miliseconds delay.\n\n");
+ fprintf(stderr, " -T NUMBER Splash page with NUMBER of seconds delay.\n\n");
+ print_stdusage();
+ return retval;
+}
+
/*
* ---------------------------------------------------------------------
* end of programs usage
@@ -2443,13 +2985,11 @@
{
int i, ch, rv = 0;
- verbose = 0;
-
- while ((ch = getopt(argc, argv, "hqv", 1)) != EOF) {
+ while ((ch = getopt(argc, argv, "hqvV", 1)) != EOF) {
switch (ch) {
case '.':
if (!stricmp(optarg, "verbose"))
- verbose = 1;
+ xtrace = 1;
else if (!stricmp(optarg, "version"))
return print_banner(1);
else if (!stricmp(optarg, "help"))
@@ -2458,10 +2998,13 @@
return prog_mkdir_usage(EINVAL);
break;
case 'v':
- verbose = 1;
+ xtrace = 1;
break;
+ case 'V':
+ xtrace = 9;
+ break;
case 'q':
- xquiet = 1;
+ xquiet = 1;
break;
case 'h':
return prog_mkdir_usage(0);
@@ -2490,11 +3033,11 @@
int i, ch, rv = 0;
int recurse = 0;
- while ((ch = getopt(argc, argv, "rhqv", 1)) != EOF) {
+ while ((ch = getopt(argc, argv, "rhqvV", 1)) != EOF) {
switch (ch) {
case '.':
if (!stricmp(optarg, "verbose"))
- verbose = 1;
+ xtrace = 1;
else if (!stricmp(optarg, "version"))
return print_banner(1);
else if (!stricmp(optarg, "help"))
@@ -2503,8 +3046,11 @@
return prog_rmdir_usage(EINVAL);
break;
case 'v':
- verbose = 1;
+ xtrace = 1;
break;
+ case 'V':
+ xtrace = 9;
+ break;
case 'q':
xquiet = 1;
break;
@@ -2549,11 +3095,11 @@
wchar_t file[X_MAX_PATH];
WIN32_FILE_ATTRIBUTE_DATA ad;
- while ((ch = getopt(argc, argv, "acfmr:t:hqv", 1)) != EOF) {
+ while ((ch = getopt(argc, argv, "acfmr:t:hqvV", 1)) != EOF) {
switch (ch) {
case '.':
if (!stricmp(optarg, "verbose"))
- verbose = 1;
+ xtrace = 1;
else if (!stricmp(optarg, "version"))
return print_banner(1);
else if (!stricmp(optarg, "help"))
@@ -2562,10 +3108,13 @@
return prog_touch_usage(EINVAL);
break;
case 'v':
- verbose = 1;
+ xtrace = 1;
break;
+ case 'V':
+ xtrace = 9;
+ break;
case 'q':
- xquiet = 1;
+ xquiet = 1;
break;
case 'h':
return prog_touch_usage(0);
@@ -2602,7 +3151,7 @@
flags = 3;
if (from) {
if (rv = x_fstat(&ad, from)) {
- if (verbose) {
+ if (xtrace) {
x_wfullpath(file, X_MAX_PATH, from);
warnx("'%S' -- %s", file, cstrerror(rv));
}
@@ -2632,7 +3181,7 @@
&t.wDay, &t.wHour, &t.wMinute);
else {
- if (verbose)
+ if (xtrace)
warnx("invalid time format %s", tstr);
return EINVAL;
}
@@ -2647,7 +3196,7 @@
t.wYear = n.wYear;
}
if (!SystemTimeToFileTime(&t, &ad.ftLastAccessTime)) {
- if (verbose)
+ if (xtrace)
warnx("invalid time format %04d-%02d-%02d-%02d-%02d.%02d",
t.wYear, t.wMonth, t.wDay, t.wHour,
t.wMinute, t.wSecond);
@@ -2662,7 +3211,7 @@
for (i = 0; i < argc; i++) {
HANDLE hf;
if ((rv = x_wfullpath(file, X_MAX_PATH, argv[i]))) {
- if (verbose) {
+ if (xtrace) {
warnx("'%s' -- %s", argv[i], cstrerror(rv));
}
return rv;
@@ -2672,7 +3221,7 @@
FILE_ATTRIBUTE_NORMAL, NULL);
if (hf == INVALID_HANDLE_VALUE) {
rv = x_cerror(0);
- if (verbose) {
+ if (xtrace) {
warnx("'%S' -- %s", file, cstrerror(rv));
}
return rv;
@@ -2700,10 +3249,10 @@
}
if (!SetFileTime(hf, NULL, at, mt)) {
rv = x_cerror(0);
- if (verbose)
+ if (xtrace)
warnx("'%S' -- %s", file, cstrerror(rv));
}
- if (verbose) {
+ if (xtrace) {
if (at || mt)
warnx("'%S' modified.", file);
else
@@ -2744,11 +3293,11 @@
char **mainargv = NULL;
char wcpath[MAX_PATH + 32] = { 0 };
- while ((ch = getopt(argc, argv, "cefrshqv", 1)) != EOF) {
+ while ((ch = getopt(argc, argv, "cefrshqV", 1)) != EOF) {
switch (ch) {
case '.':
if (!stricmp(optarg, "verbose"))
- verbose = 1;
+ xtrace = 1;
else if (!stricmp(optarg, "version"))
return print_banner(1);
else if (!stricmp(optarg, "help"))
@@ -2757,8 +3306,11 @@
return prog_exec_usage(EINVAL);
break;
case 'v':
- verbose = 1;
+ xtrace = 1;
break;
+ case 'V':
+ xtrace = 9;
+ break;
case 'q':
xquiet = 1;
break;
@@ -2875,10 +3427,10 @@
SetConsoleCtrlHandler((PHANDLER_ROUTINE)console_handler, TRUE);
if (checkbinary(mainargv[0])) {
- if (verbose)
+ if (xtrace > 1)
fprintf(stdout, "Executing %s\n", mainargv[0]);
rv = _spawnvpe(_P_WAIT, mainargv[0], mainargv, mainenvp);
- if (verbose)
+ if (xtrace)
fprintf(stdout, "%s: exit(%d)\n", mainargv[0], rv);
}
else {
@@ -2907,11 +3459,11 @@
char patern[MAX_PATH];
register char *start, *trv, *suffp;
- while ((ch = getopt(argc, argv, "dquhqv", 1)) != EOF) {
+ while ((ch = getopt(argc, argv, "dquhqvV", 1)) != EOF) {
switch (ch) {
case '.':
if (!stricmp(optarg, "verbose"))
- verbose = 1;
+ xtrace = 1;
else if (!stricmp(optarg, "version"))
return print_banner(1);
else if (!stricmp(optarg, "help"))
@@ -2920,8 +3472,11 @@
return prog_mktemp_usage(1);
break;
case 'v':
- verbose = 1;
+ xtrace = 1;
break;
+ case 'V':
+ xtrace = 9;
+ break;
case 'q':
xquiet = 1;
break;
@@ -2974,15 +3529,15 @@
start = trv + 1;
for (;;) {
- if (access(path, 0)) {
+ if (!x_fattrib(path)) {
if (errno == ENOENT) {
if (mdir) {
- if (mkdir(path)) {
+ if (x_createdir(path)) {
x_perror(0, path);
return 1;
}
if (unsafe)
- rmdir(path);
+ x_rmdir(path);
}
else {
FILE *fp = fopen(path, "w");
@@ -3086,7 +3641,7 @@
switch (ch) {
case '.':
if (!stricmp(optarg, "verbose"))
- verbose = 1;
+ xtrace = 1;
else if (!stricmp(optarg, "version"))
return print_banner(1);
else if (!stricmp(optarg, "help"))
@@ -3097,8 +3652,10 @@
return prog_image_usage(1);
break;
case 'v':
+ xtrace = 1;
+ break;
case 'V':
- verbose = 1;
+ xtrace = 9;
break;
case 'q':
case 'Q':
@@ -3541,11 +4098,151 @@
x_free(pidata);
pidata = NULL;
}
- if (verbose)
+ if (xtrace)
fputc('\n', stdout);
return 0;
}
+static int prog_html(int argc, const char **argv, const char **env)
+{
+ int ch, rv = 0;
+ char *p;
+ char title[MAX_PATH] = { 0 };
+ int w = 0;
+ int h = 0;
+ int t = INFINITE;
+ int flags = 0;
+ char *page = NULL;
+ char *output = NULL;
+ char *params = NULL;
+
+ if (!GuiInitialize()) {
+ return x_perror(0, "Windows GUI");
+ }
+ while ((ch = getopt(argc, argv, "g:n:o:p:st:T:qhqv", 1)) != EOF) {
+ switch (ch) {
+ case '.':
+ if (!stricmp(optarg, "verbose"))
+ xtrace = 1;
+ else if (!stricmp(optarg, "version"))
+ return print_banner(1);
+ else if (!stricmp(optarg, "help"))
+ return prog_html_usage(0);
+ else
+ return prog_html_usage(1);
+ break;
+ case 'v':
+ xtrace = 1;
+ break;
+ case 'V':
+ xtrace = 9;
+ break;
+ case 'q':
+ xquiet = 1;
+ break;
+ case 'h':
+ return prog_html_usage(0);
+ break;
+ case 'g':
+ w = atoi(optarg);
+ if (!(p = strchr(optarg, 'x')))
+ p = strchr(optarg, 'X');
+ if (p++)
+ h = atoi(p);
+ if (w < 1 || h < 1) {
+ return x_perror(EINVAL, "Geometry");
+ }
+ break;
+ case 'n':
+ x_strncpy(title, optarg, MAX_PATH);
+ break;
+ case 'o':
+ output = x_fullpath(optarg);
+ break;
+ case 'p':
+ params = x_strdup(optarg);
+ break;
+ case 's':
+ flags = 1;
+ break;
+ case 't':
+ t = atoi(optarg);
+ break;
+ case 'T':
+ t = atoi(optarg) * 1000;
+ break;
+ case '?':
+ case ':':
+ return 1;
+ break;
+ }
+ }
+ argc -= optind;
+ argv += optind;
+ if (argc < 1) {
+ return prog_html_usage(EINVAL);
+ }
+ if (!(page = x_fullpath(argv[0]))) {
+ return x_perror(EINVAL, argv[0]);
+ }
+ if (!title[0]) {
+ FILE *f;
+ char buff[SIZ_BUFLEN];
+ char lbuf[SIZ_BUFLEN];
+ if (!(f = fopen(page, "r"))) {
+ rv = x_perror(0, page);
+ goto cleanup;
+ }
+ while (fgets(&buff[0], SIZ_BUFLEN, f)) {
+ char *e;
+ strcpy(lbuf, buff);
+ strlwr(lbuf);
+ if ((p = strstr(lbuf, "<title>")) && *(p += 7)) {
+ if ((e = strstr(p, "</title>"))) {
+ size_t ps = p - lbuf;
+ size_t pe = e - lbuf;
+ x_strncpy(lbuf, buff + ps, pe - ps + 1);
+ p = rltrim(lbuf);
+ strcpy(title, p);
+ break;
+ }
+ }
+ }
+ fclose(f);
+ if (!title[0]) {
+ rv = x_perror(EINVAL, "Html <title></title> tag");
+ goto cleanup;
+ }
+ }
+ if (w < 1)
+ w = DEF_WWIDTH;
+ if (h < 1)
+ h = DEF_WHEIGHT;
+
+ if (xtrace > 1) {
+ warnx("Html %s", page);
+ warnx("Title %s", title);
+ warnx("Geometry %d x %d", w, h);
+ }
+
+ if (!RunCustomPage(page,
+ title,
+ params,
+ w,
+ h,
+ t,
+ flags,
+ output)) {
+ rv = x_cerror(0);
+ }
+
+cleanup:
+ x_free(page);
+ x_free(params);
+ x_free(output);
+ return rv;
+}
+
/*
* ---------------------------------------------------------------------
* end of programs
@@ -3567,6 +4264,7 @@
{ "mktemp", prog_mktemp },
{ "image", prog_image },
{ "coff", prog_image },
+ { "html", prog_html },
{ NULL, NULL }
};
@@ -3621,9 +4319,9 @@
if ((e = getenv("XTOOLS_PAUSE")) != NULL)
xtools_pause = 1;
if ((e = getenv("XTOOLS_VERBOSE")) != NULL) {
- verbose = atoi(e);
- if (!verbose)
- verbose = 1;
+ xtrace = atoi(e);
+ if (!xtrace)
+ xtrace = 1;
}
}
@@ -3634,6 +4332,9 @@
if (cleared++)
return;
/* Make any cleanup here */
+
+ /* Finally terminate the GUI */
+ GuiTerminate();
}
int wmain(int argc, const wchar_t **wargv, const wchar_t **wenv)
@@ -3691,7 +4392,7 @@
getch();
fprintf(stdout, "\n");
}
- if (verbose)
+ if (xtrace)
warnx("exit(%d)", rv);
exit(rv);
/*
Modified: trunk/build/install/xtool/xtool.rc
===================================================================
--- trunk/build/install/xtool/xtool.rc 2008-04-04 06:18:32 UTC (rev 1518)
+++ trunk/build/install/xtool/xtool.rc 2008-04-04 16:17:51 UTC (rev 1519)
@@ -26,6 +26,10 @@
#include <windows.h>
+#define IDI_MAINICON 101
+#define IDI_RHELICON 102
+
+
#define STR_COPYRIGHT "Copyright � 2008 Red Hat Middleware, LLC. " \
"or its licensors, as applicable."
@@ -43,6 +47,8 @@
IDI_MAINICON ICON "jboss.ico"
IDI_RHELICON ICON "redhat.ico"
+CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "commonc.manifest"
+
1 VERSIONINFO
FILEVERSION CSV_VERSION
PRODUCTVERSION CSV_VERSION
16 years, 6 months
JBoss Native SVN: r1518 - trunk/build/install/installer.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-04 02:18:32 -0400 (Fri, 04 Apr 2008)
New Revision: 1518
Modified:
trunk/build/install/installer/sinstall.h
trunk/build/install/installer/sinstall.rc
Log:
Add eula files to resources
Modified: trunk/build/install/installer/sinstall.h
===================================================================
--- trunk/build/install/installer/sinstall.h 2008-04-04 06:12:28 UTC (rev 1517)
+++ trunk/build/install/installer/sinstall.h 2008-04-04 06:18:32 UTC (rev 1518)
@@ -105,8 +105,9 @@
#define IDD_ABOUTBOX 250
#define IDC_LICENSE 251
#define IDR_LICENSE 252
-#define IAB_SYSINF 253
-#define IDC_ABOUTAPP 254
+#define IDR_EULA 253
+#define IAB_SYSINF 254
+#define IDC_ABOUTAPP 255
#define SIZ_BUFLEN 1024
#define SIZ_BUFMAX (SIZ_BUFLEN - 1)
Modified: trunk/build/install/installer/sinstall.rc
===================================================================
--- trunk/build/install/installer/sinstall.rc 2008-04-04 06:12:28 UTC (rev 1517)
+++ trunk/build/install/installer/sinstall.rc 2008-04-04 06:18:32 UTC (rev 1518)
@@ -43,6 +43,7 @@
IDI_MAINICON ICON "res/jboss.ico"
IDI_RHELICON ICON "res/redhat.ico"
IDR_LICENSE RTF "res/lgpl.rtf"
+IDR_EULA RTF "res/eula.rtf"
IDB_JBOSSTOP BITMAP "res/jbosstop.bmp"
CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "res/commonc.manifest"
@@ -53,6 +54,8 @@
IMG_JBOSSTOP PNG "res/jbosstop.png"
HTML_LGPLMAIN HTML "res/lgplmain.htm"
HTML_LGPL HTML "res/lgpl.htm"
+HTML_EULAMAIN HTML "res/eulamain.htm"
+HTML_EULA HTML "res/eula.htm"
IDD_ABOUTBOX DIALOGEX 0, 0, 337, 187
STYLE DS_SETFONT | DS_MODALFRAME | WS_CAPTION | WS_SYSMENU
16 years, 6 months
JBoss Native SVN: r1517 - trunk/build/install/installer/res.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-04 02:12:28 -0400 (Fri, 04 Apr 2008)
New Revision: 1517
Added:
trunk/build/install/installer/res/eulamain.htm
Modified:
trunk/build/install/installer/res/lgplmain.htm
Log:
Add eula frame
Added: trunk/build/install/installer/res/eulamain.htm
===================================================================
--- trunk/build/install/installer/res/eulamain.htm (rev 0)
+++ trunk/build/install/installer/res/eulamain.htm 2008-04-04 06:12:28 UTC (rev 1517)
@@ -0,0 +1,147 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<HEAD lang="en">
+ <META http-equiv="Content-Type" content="text/html; charset=windows-1252">
+ <META http-equiv="MSThemeCompatible" content="Yes">
+ <TITLE>Accept License Agreement</TITLE>
+ <STYLE type="text/css">
+ BODY, TABLE, TR, TD, UL, OL, LI, P {
+ font-family: MS Shell Dlg;
+ font-size: 10px;
+ font-style: normal;
+ text-decoration: none;
+ background-color: ButtonFace;
+ color: ButtonText;
+ }
+ INPUT {
+ font-family: MS Shell Dlg;
+ font-size: 10px;
+ }
+ TH {
+ font-family: MS Shell Dlg;
+ font-size: 10px;
+ font-style: normal;
+ text-decoration: none;
+ text-align: left;
+ line-height: 22px;
+ background-color: ActiveCaption;
+ color: CaptionText;
+ }
+ H1 {
+ font-family: Serife, Verdana, Helvetica, Arial, Tahoma;
+ font-size: 24px;
+ }
+ H2 {
+ font-family: Serife, Verdana, Helvetica, Arial, Tahoma;
+ font-size: 20px;
+ }
+ H3 {
+ font-family: Serife, Verdana, Helvetica, Arial, Tahoma;
+ font-size: 18px;
+ }
+ H4 {
+ font-family: Serife, Verdana, Helvetica, Arial, Tahoma;
+ font-size: 13px;
+ }
+ A {
+ color: blue;
+ }
+ IFRAME {
+ border-left:0px;
+ border-right:0px;
+ border-top:1px solid;
+ border-top-color: ActiveBorder;
+ border-bottom:1px solid;
+ border-bottom-color: ActiveBorder;
+ }
+ .hide {
+ display: none;
+ visibility: hidden;
+ }
+ .show {
+ display: block;
+ visibility: visible;
+ }
+ </STYLE>
+ <SCRIPT language="JScript">
+
+ function pageOnLoad()
+ {
+ window.returnValue = null;
+ if (window.dialogArguments != null) {
+ var args;
+ args = window.dialogArguments.split("\t");
+ for (i = 0; i < args.length; i++) {
+ try {
+ obj = eval("val" + i);
+ if (obj != null)
+ obj.value = args[i];
+ } catch (err) {
+ // Nothing
+ }
+ }
+ }
+ iLicense.focus();
+ return true;
+ }
+
+ function okClick()
+ {
+ rv = "OK";
+ for (i = 0; i < 4; i++) {
+ try {
+ obj = eval("val" + i);
+ if (obj != null) {
+ rv = rv + "\t" + obj.value;
+ }
+ } catch (err) {
+ // Nothing
+ }
+ }
+ window.returnValue = rv;
+ window.close();
+ }
+
+ function cancelClick()
+ {
+ window.returnValue = "CANCEL";
+ window.close();
+ }
+
+ function onAcceptClick()
+ {
+ if (accept.checked)
+ ok.disabled=false;
+ else
+ ok.disabled=true;
+ }
+ </SCRIPT>
+</HEAD>
+<BODY scroll="no" topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0"
+ marginwidth="0" marginheight="0" onload="pageOnLoad(); return true;">
+<DIV style="position:absolute; top:0px; left:0px; width=505px; height:360px; border:0px solid;">
+<DIV style="position:absolute; top:0px; left:0px; width=505px; height:48px;">
+<IMG src="PNG/IMG_JBOSSTOP" border="0"/>
+</DIV>
+<DIV style="position:absolute; top:48px; left:0px; width=505px;">
+<IFRAME src="HTML_EULA" id="iLicense" FRAMEBORDER=0 SCROLLING=YES style="width: 100%; height: 240px;"></IFRAME>
+</DIV>
+<DIV style="position:absolute; top:296px; left:6px; width=505px; height:48px;">
+ <strong style="color:red;">Required: </strong> You must accept the License Agreement to install the product.<br/>
+<INPUT type="checkbox" id="accept" onclick="onAcceptClick();"/> Accept License Agreement
+</DIV>
+<DIV style="position:absolute; top:336px; left:10px; width=300px;">
+<IMG src="PNG/IMG_REDHAT16" border="0" width=16 height=16/> Copyright © 2008 Red Hat® Middleware, LLC.
+</DIV>
+<DIV style="position:absolute; top:310px; left:300px;">
+<TABLE cellspacing="0" style="margin:6px;">
+ <TR>
+ <TD align="right">
+ <INPUT type="button" value="Accept" disabled id="ok" style="width: 88px; height: 24px; cursor: hand;" onclick="okClick();"/>
+ <INPUT type="button" value="Decline" id="cancel" style="width: 88px; height: 24px; cursor: hand;" onclick="cancelClick();"/>
+ </TD>
+ </TR>
+</TABLE>
+</DIV>
+</DIV>
+</BODY>
+</HTML>
Modified: trunk/build/install/installer/res/lgplmain.htm
===================================================================
--- trunk/build/install/installer/res/lgplmain.htm 2008-04-04 05:55:43 UTC (rev 1516)
+++ trunk/build/install/installer/res/lgplmain.htm 2008-04-04 06:12:28 UTC (rev 1517)
@@ -126,11 +126,11 @@
<IFRAME src="HTML_LGPL" id="iLicense" FRAMEBORDER=0 SCROLLING=YES style="width: 100%; height: 240px;"></IFRAME>
</DIV>
<DIV style="position:absolute; top:296px; left:6px; width=505px; height:48px;">
- <strong style="color:red;">Required: </strong> You must accept the license agreement to install the product.<br/>
+ <strong style="color:red;">Required: </strong> You must accept the License Agreement to install the product.<br/>
<INPUT type="checkbox" id="accept" onclick="onAcceptClick();"/> Accept License Agreement
</DIV>
<DIV style="position:absolute; top:336px; left:10px; width=300px;">
-<IMG src="PNG/IMG_REDHAT16" border="0" width=16 height=16/> Copyright � 2008 Red Hat� Middleware, LLC.
+<IMG src="PNG/IMG_REDHAT16" border="0" width=16 height=16/> Copyright © 2008 Red Hat® Middleware, LLC.
</DIV>
<DIV style="position:absolute; top:310px; left:300px;">
<TABLE cellspacing="0" style="margin:6px;">
16 years, 6 months
JBoss Native SVN: r1516 - trunk/build/install/installer/res.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-04 01:55:43 -0400 (Fri, 04 Apr 2008)
New Revision: 1516
Added:
trunk/build/install/installer/res/eula.htm
trunk/build/install/installer/res/eula.rtf
Modified:
trunk/build/install/installer/res/lgpl.htm
Log:
Add JBossORG-EULA as html and rtf documents
Added: trunk/build/install/installer/res/eula.htm
===================================================================
--- trunk/build/install/installer/res/eula.htm (rev 0)
+++ trunk/build/install/installer/res/eula.htm 2008-04-04 05:55:43 UTC (rev 1516)
@@ -0,0 +1,225 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<HEAD lang="en">
+ <META http-equiv="Content-Type" content="text/html; charset=windows-1252">
+ <META http-equiv="MSThemeCompatible" content="Yes">
+ <TITLE>License Agreement</TITLE>
+ <STYLE type="text/css">
+ BODY, TABLE, TR, TD, UL, OL, LI, P {
+ font-family: Serife, Verdana, Helvetica, Tahoma;
+ font-size: 11px;
+ font-style: normal;
+ text-decoration: none;
+ background-color: Window;
+ color: WindowText;
+ }
+ PRE {
+ font-size: 10px;
+ font-style: normal;
+ text-decoration: none;
+ background-color: Window;
+ color: WindowText;
+ }
+ H1 {
+ font-family: Serife, Verdana, Helvetica, Tahoma;
+ font-size: 18px;
+ }
+ H2 {
+ font-family: Serife, Verdana, Helvetica, Tahoma;
+ font-size: 13px;
+ }
+ A {
+ color: blue;
+ }
+ </STYLE>
+</HEAD>
+<BODY scroll="auto" topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0"
+ marginwidth="0" marginheight="0">
+<DIV style="position:absolute; top:0px; left:4px; width:482px;">
+<BR/>
+<h1>License Agreement</h1>
+<p>
+<h2>JBoss�</h2>
+</p>
+
+<p>
+This License Agreement governs the use of the Software Packages and
+any updates to the Software Packages, regardless of the delivery mechanism.
+Each Software Package is a collective work under U.S. Copyright Law.
+Subject to the following terms, Red Hat, Inc. ("Red Hat") grants to the
+user ("Client") a license to the applicable collective work(s) pursuant to
+the GNU Lesser General Public License v. 2.1 except for the following Software
+Packages:
+</p>
+<ul>
+ <li><strong>a)</strong>
+ JBoss Portal Forums and JBoss Transactions JTS, each of which is licensed
+ pursuant to the GNU General Public License v.2;
+ </li>
+ <li><strong>b)</strong>
+ JBoss Rules, which is licensed pursuant to the Apache License v.2.0;
+ </li>
+ <li><strong>b)</strong>
+ an optional download for JBoss Cache for the Berkeley DB for Java database,
+ which is licensed under the (open source) Sleepycat License (if Client does
+ not wish to use the open source version of this database, it may purchase a
+ license from Sleepycat Software);
+ <br/><br/>and<br/><br/>
+ </li>
+ <li><strong>d)</strong>
+ the BPEL extension for JBoss jBPM, which is licensed under the Common Public
+ License v.1, and, pursuant to the OASIS BPEL4WS standard, requires parties
+ wishing to redistribute to enter various royalty-free patent licenses.
+ </li>
+</ul>
+<p>
+Each of the foregoing licenses is available at
+<a target="_blank" href="http://www.opensource.org/licenses/index.php">
+http://www.opensource.org/licenses/index.php
+</a>
+</p>
+
+<p><strong>1.</strong>
+The Software. "Software Packages" refer to the various software modules that
+are created and made available for distribution by the JBoss.org open source
+community at
+<a target="_blank" href="http://www.jboss.org">
+http://www.jboss.org.</a> Each of the Software Packages may be
+comprised of hundreds of software components. The end user license agreement
+for each component is located in the component's source code. With the
+exception of certain image files identified in Section 2 below, the license
+terms for the components permit Client to copy, modify, and redistribute the
+component, in both source code and binary code forms. This agreement does not
+limit Client's rights under, or grant Client rights that supersede, the license
+terms of any particular component.
+</p>
+
+<p><strong>2.</strong>
+Intellectual Property Rights.The Software Packages are owned by Red Hat and
+others and are protected under copyright and other laws. Title to the
+Software Packages and any component, or to any copy, modification, or merged
+portion shall remain with the aforementioned, subject to the applicable
+license. The "JBoss" trademark, "Red Hat" trademark, the individual Software
+Package trademarks, and the "Shadowman" logo are registered trademarks of
+Red Hat and its affiliates in the U.S. and other countries.
+This agreement permits Client to distribute unmodified copies of the Software
+Packages using the Red Hat trademarks that Red Hat has inserted in the Software
+Packages on the condition that Client follows Red Hat's trademark guidelines
+for those trademarks located at
+<a target="_blank" href="http://www.redhat.com/about/corporate/trademark/">
+http://www.redhat.com/about/corporate/trademark/.</a>
+Client must abide by these trademark guidelines when distributing the Software
+Packages, regardless of whether the Software Packages have been modified.
+If Client modifies the Software Packages, then Client must replace all Red Hat
+trademarks and logos identified at
+<a target="_blank" href="http://www.jboss.com/company/logos">
+http://www.jboss.com/company/logos</a> unless a
+separate agreement with Red Hat is executed or other permission granted.
+Merely deleting the files containing the Red Hat trademarks may corrupt
+the Software Packages.
+</p>
+
+<p><strong>3.</strong>
+Limited Warranty. Except as specifically stated in this Paragraph 3 or a license
+for a particular component, to the maximum extent permitted under applicable law,
+the Software Packages and the components are provided and licensed "as is"
+without warranty of any kind, expressed or implied, including the implied
+warranties of merchantability, non-infringement or fitness for a particular
+purpose. Red Hat warrants that the media on which Software Packages may be
+furnished will be free from defects in materials and manufacture under normal
+use for a period of 30 days from the date of delivery to Client. Red Hat does
+not warrant that the functions contained in the Software Packages will meet
+Client's requirements or that the operation of the Software Packages will be
+entirely error free or appear precisely as described in the accompanying
+documentation. This warranty extends only to the party that purchases the
+Services pertaining to the Software Packages from Red Hat or a Red Hat
+authorized distributor.
+</p>
+
+<p><strong>4.</strong>
+Limitation of Remedies and Liability. To the maximum extent permitted by
+applicable law, the remedies described below are accepted by Client as its
+only remedies. Red Hat's entire liability, and Client's exclusive remedies,
+shall be: If the Software media is defective, Client may return it within 30
+days of delivery along with a copy of Client's payment receipt and Red Hat,
+at its option, will replace it or refund the money paid by Client for the
+Software. To the maximum extent permitted by applicable law, Red Hat or any
+Red Hat authorized dealer will not be liable to Client for any incidental or
+consequential damages, including lost profits or lost savings arising out of
+the use or inability to use the Software, even if Red Hat or such dealer has
+been advised of the possibility of such damages. In no event shall Red Hat's
+liability under this agreement exceed the amount that Client paid to Red Hat
+under this Agreement during the twelve months preceding the action.
+</p>
+
+<p><strong>5.</strong>
+Export Control. As required by U.S. law, Client represents and
+warrants that it:
+<ul>
+ <li><strong>a)</strong>
+ understands that the Software Packages are subject to export controls under
+ the U.S. Commerce Department's Export Administration Regulations ("EAR");
+ </li>
+ <li><strong>b)</strong>
+ is not located in a prohibited destination country under the EAR or U.S.
+ sanctions regulations (currently Cuba, Iran, Iraq, Libya, North Korea,
+ Sudan and Syria);
+ </li>
+ <li><strong>c)</strong>
+ will not export, re-export, or transfer the Software Packages to any
+ prohibited destination, entity, or individual without the necessary export
+ license(s) or authorizations(s) from the U.S. Government;
+ </li>
+ <li><strong>d)</strong>
+ will not use or transfer the Software Packages for use in any sensitive
+ nuclear, chemical or biological weapons, or missile technology end-uses
+ unless authorized by the U.S. Government by regulation or specific
+ license;
+ </li>
+ <li><strong>e)</strong>
+ understands and agrees that if it is in the United States and exports or
+ transfers the Software Packages to eligible end users, it will, as
+ required by EAR Section 740.17(e), submit semi-annual reports to
+ the Commerce Department's Bureau of Industry & Security (BIS), which
+ include the name and address (including country) of each transferee;
+ </li>
+ <br/><br/>and<br/><br/>
+ <li><strong>f)</strong>
+ understands that countries other than the United States may restrict the
+ import, use, or export of encryption products and that it shall be solely
+ responsible for compliance with any such import, use, or export restrictions.
+ </li>
+</ul>
+</p>
+
+<p><strong>6.</strong>
+Third Party Programs. Red Hat may distribute third party software programs
+with the Software Packages that are not part of the Software Packages and
+which Client must install separately. These third party programs are subject
+to their own license terms. The license terms either accompany the programs
+or can be viewed at
+<a target="_blank" href="http://www.redhat.com/licenses/">
+http://www.redhat.com/licenses/</a>. If Client does not agree
+to abide by the applicable license terms for such programs, then Client may
+not install them. If Client wishes to install the programs on more than one
+system or transfer the programs to another party, then Client must contact
+the licensor of the programs.
+</p>
+
+<p><strong>7.</strong>
+General. If any provision of this agreement is held to be unenforceable,
+that shall not affect the enforceability of the remaining provisions.
+This License Agreement shall be governed by the laws of the State of North
+Carolina and of the United States, without regard to any conflict of laws
+provisions, except that the United Nations Convention on the International
+Sale of Goods shall not apply.
+</p>
+
+<pre>
+Copyright © 2006-2008 Red Hat, Inc. All rights reserved.
+"JBoss" and the JBoss logo are registered trademarks of Red Hat, Inc.
+All other trademarks are the property of their respective owners.
+</pre>
+
+</DIV>
+</BODY>
+</HTML>
Added: trunk/build/install/installer/res/eula.rtf
===================================================================
--- trunk/build/install/installer/res/eula.rtf (rev 0)
+++ trunk/build/install/installer/res/eula.rtf 2008-04-04 05:55:43 UTC (rev 1516)
@@ -0,0 +1,47 @@
+{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fswiss\fprq2\fcharset0 Verdana;}{\f1\fmodern\fprq1\fcharset0 Courier New;}{\f2\fnil\fcharset2 Symbol;}}
+{\*\generator Msftedit 5.41.21.2508;}\viewkind4\uc1\pard\b\f0\fs27 License Agreement\par
+\fs20 JBoss\'ae\b0\fs27\par
+\par
+\fs17 This License Agreement governs the use of the Software Packages and any updates to the Software Packages, regardless of the delivery mechanism. Each Software Package is a collective work under U.S. Copyright Law. Subject to the following terms, Red Hat, Inc. ("Red Hat") grants to the user ("Client") a license to the applicable collective work(s) pursuant to the GNU Lesser General Public License v. 2.1 except for the following Software Packages:\par
+ \par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (a)\b0 JBoss Portal Forums and JBoss Transactions JTS, each of which is licensed pursuant to the GNU General Public License v.2; \par
+\pard\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (b)\b0 JBoss Rules, which is licensed pursuant to the Apache License v.2.0;\par
+\pard\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (c)\b0 an optional download for JBoss Cache for the Berkeley DB for Java database, which is licensed under the (open source) Sleepycat License (if Client does not wish to use the open source version of this database, it may purchase a license from Sleepycat Software); \par
+\pard and\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\tx284\b (d)\b0 the BPEL extension for JBoss jBPM, which is licensed under the Common Public License v.1, and, pursuant to the OASIS BPEL4WS standard, requires parties wishing to redistribute to enter various royalty-free patent licenses. \par
+\pard\par
+Each of the foregoing licenses is available at http://www.opensource.org/licenses/index.php.\par
+\par
+\b 1.\b0 The Software. "Software Packages" refer to the various software modules that are created and made available for distribution by the JBoss.org open source community at http://www.jboss.org. Each of the Software Packages may be comprised of hundreds of software components. The end user license agreement for each component is located in the component's source code. With the exception of certain image files identified in Section 2 below, the license terms for the components permit Client to copy, modify, and redistribute the component, in both source code and binary code forms. This agreement does not limit Client's rights under, or grant Client rights that supersede, the license terms of any particular component.\par
+\par
+\b 2.\b0 Intellectual Property Rights. The Software Packages are owned by Red Hat and others and are protected under copyright and other laws. Title to the Software Packages and any component, or to any copy, modification, or merged portion shall remain with the aforementioned, subject to the applicable license. The "JBoss" trademark, "Red Hat" trademark, the individual Software Package trademarks, and the "Shadowman" logo are registered trademarks of Red Hat and its affiliates in the U.S. and other countries. This agreement permits Client to distribute unmodified copies of the Software Packages using the Red Hat trademarks that Red Hat has inserted in the Software Packages on the condition that Client follows Red Hat's trademark guidelines for those trademarks located at http://www.redhat.com/about/corporate/trademark/. Client must abide by these trademark guidelines when distributing the Software Packages, regardless of whether the Software Packages have been modifi!
ed. If Client modifies the Software Packages, then Client must replace all Red Hat trademarks and logos identified at http://www.jboss.com/company/logos unless a separate agreement with Red Hat is executed or other permission granted. Merely deleting the files containing the Red Hat trademarks may corrupt the Software Packages. \par
+\par
+\b 3.\b0 Limited Warranty. Except as specifically stated in this Paragraph 3 or a license for a particular \par
+component, to the maximum extent permitted under applicable law, the Software Packages and the components are provided and licensed "as is" without warranty of any kind, expressed or implied, including the implied warranties of merchantability, non-infringement or fitness for a particular purpose. Red Hat warrants that the media on which Software Packages may be furnished will be free from defects in materials and manufacture under normal use for a period of 30 days from the date of delivery to Client. Red Hat does not warrant that the functions contained in the Software Packages will meet Client's requirements or that the operation of the Software Packages will be entirely error free or appear precisely as described in the accompanying documentation. This warranty extends only to the party that purchases the Services pertaining to the Software Packages from Red Hat or a Red Hat authorized distributor. \par
+\par
+\b 4.\b0 Limitation of Remedies and Liability. To the maximum extent permitted by applicable law, the remedies described below are accepted by Client as its only remedies. Red Hat's entire liability, and Client's exclusive remedies, shall be: If the Software media is defective, Client may return it within 30 days of delivery along with a copy of Client's payment receipt and Red Hat, at its option, will replace it or refund the money paid by Client for the Software. To the maximum extent permitted by applicable law, Red Hat or any Red Hat authorized dealer will not be liable to Client for any incidental or consequential damages, including lost profits or lost savings arising out of the use or inability to use the Software, even if Red Hat or such dealer has been advised of the possibility of such damages. In no event shall Red Hat's liability under this agreement exceed the amount that Client paid to Red Hat under this Agreement during the twelve months preceding the ac!
tion.\par
+\par
+\b 5.\b0 Export Control. As required by U.S. law, Client represents and warrants that it: \par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (a)\b0 understands that the Software Packages are subject to export controls under the U.S. Commerce Department's Export Administration Regulations ("EAR"); \par
+\pard\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (b)\b0 is not located in a prohibited destination country under the EAR or U.S. sanctions regulations (currently Cuba, Iran, Iraq, Libya, North Korea, Sudan and Syria); \par
+\pard\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (c)\b0 will not export, re-export, or transfer the Software Packages to any prohibited destination, entity, or individual without the necessary export license(s) or authorizations(s) from the U.S. Government; \par
+\pard\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (d)\b0 will not use or transfer the Software Packages for use in any sensitive nuclear, chemical or biological weapons, or missile technology end-uses unless authorized by the U.S. Government by regulation or specific license; \par
+\pard\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (e)\b0 understands and agrees that if it is in the United States and exports or transfers the Software Packages to eligible end users, it will, as required by EAR Section 740.17(e), submit semi-annual reports to the Commerce Department's Bureau of Industry & Security (BIS), which include the name and address (including country) of each transferee; \par
+\pard and\par
+\pard{\pntext\f2\'B7\tab}{\*\pn\pnlvlblt\pnf2\pnindent0{\pntxtb\'B7}}\fi-436\li720\b (f)\b0 understands that countries other than the United States may restrict the import, use, or export of encryption products and that it shall be solely responsible for compliance with any such import, use, or export restrictions.\par
+\pard\par
+\b 6.\b0 Third Party Programs. Red Hat may distribute third party software programs with the Software Packages that are not part of the Software Packages and which Client must install separately. These third party programs are subject to their own license terms. The license terms either accompany the programs or can be viewed at http://www.redhat.com/licenses/. If Client does not agree to abide by the applicable license terms for such programs, then Client may not install them. If Client wishes to install the programs on more than one system or transfer the programs to another party, then Client must contact the licensor of the programs.\par
+\par
+\b 7.\b0 General. If any provision of this agreement is held to be unenforceable, that shall not affect the enforceability of the remaining provisions. This License Agreement shall be governed by the laws of the State of North Carolina and of the United States, without regard to any conflict of laws provisions, except that the United Nations Convention on the International Sale of Goods shall not apply.\par
+\par
+\f1\fs15 Copyright 2006-2008 Red Hat, Inc. All rights reserved. \par
+"JBoss" and the JBoss logo are registered trademarks of Red Hat, Inc. \par
+All other trademarks are the property of their respective owners.\par
+}
+
\ No newline at end of file
Modified: trunk/build/install/installer/res/lgpl.htm
===================================================================
--- trunk/build/install/installer/res/lgpl.htm 2008-04-03 16:46:52 UTC (rev 1515)
+++ trunk/build/install/installer/res/lgpl.htm 2008-04-04 05:55:43 UTC (rev 1516)
@@ -36,7 +36,7 @@
<h1>GNU Lesser General Public License</h1>
<p>
Version 2.1, February 1999
-<p>
+</p>
<pre>
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
@@ -47,15 +47,13 @@
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
</pre>
-
-
<h2>Preamble</h2>
-
<p>
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
+</p>
<p>
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
@@ -63,6 +61,7 @@
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations below.
+</p>
<p>
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
@@ -71,11 +70,13 @@
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
+</p>
<p>
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
+</p>
<p>
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
@@ -84,10 +85,12 @@
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
+</p>
<p>
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
+</p>
<p>
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
@@ -95,6 +98,7 @@
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
+</p>
<p>
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
@@ -102,6 +106,7 @@
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
+</p>
<p>
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
@@ -109,6 +114,7 @@
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
+</p>
<p>
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
@@ -117,6 +123,7 @@
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
+</p>
<p>
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
@@ -125,6 +132,7 @@
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
+</p>
<p>
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it becomes
@@ -133,6 +141,7 @@
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
+</p>
<p>
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
@@ -140,32 +149,35 @@
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
+</p>
<p>
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
+</p>
<p>
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
+</p>
<p>
-
<h2>TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION</h2>
-
-<p>
-<strong>0.</strong>
+</p>
+<p><strong>0.</strong>
This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
+</p>
<p>
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
+</p>
<p>
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
@@ -174,12 +186,14 @@
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
+</p>
<p>
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation
and installation of the library.
+</p>
<p>
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
@@ -188,8 +202,9 @@
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
-<p>
-<strong>1.</strong>
+</p>
+
+<p><strong>1.</strong>
You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
@@ -197,30 +212,33 @@
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
+</p>
<p>
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
-<p>
-<strong>2.</strong>
+</p>
+
+<p><strong>2.</strong>
You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
+</p>
<p>
<ul>
-<li><strong>a)</strong>
-The modified work must itself be a software library.
+ <li><strong>a)</strong>
+ The modified work must itself be a software library.
+ </li>
<li><strong>b)</strong>
-You must cause the files modified to carry prominent notices
- stating that you changed the files and the date of any change.
-
+ You must cause the files modified to carry prominent notices
+ stating that you changed the files and the date of any change.
+ </li>
<li><strong>c)</strong>
-You must cause the whole of the work to be licensed at no
- charge to all third parties under the terms of this License.
-
+ You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License.
+ </li>
<li><strong>d)</strong>
-If a facility in the modified Library refers to a function or a
+ If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
@@ -228,14 +246,15 @@
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
<p>
-(For example, a function in a library to compute square roots has
+ (For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
+ </p>
<p>
-These requirements apply to the modified work as a whole. If
+ These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
@@ -245,19 +264,24 @@
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
+ </p>
<p>
-Thus, it is not the intent of this section to claim rights or contest
+ Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
+ </p>
<p>
-In addition, mere aggregation of another work not based on the Library
+ In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
+ </p>
+ </li>
</ul>
-<p>
-<strong>3.</strong>
+</p>
+
+<p><strong>3.</strong>
You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
@@ -266,40 +290,47 @@
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
+</p>
<p>
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
+</p>
<p>
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
-<p>
-<strong>4.</strong>
+</p>
+
+<p><strong>4.</strong>
You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
+</p>
<p>
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
-<p>
-<strong>5.</strong>
+</p>
+
+<p><strong>5.</strong>
A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
+</p>
<p>
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
+</p>
<p>
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
@@ -307,6 +338,7 @@
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
+</p>
<p>
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
@@ -314,19 +346,22 @@
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
+</p>
<p>
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
-<p>
-<strong>6.</strong>
+</p>
+
+<p><strong>6.</strong>
As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
+</p>
<p>
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
@@ -335,9 +370,11 @@
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
+</p>
<p>
<ul>
-<li><strong>a)</strong> Accompany the work with the complete corresponding
+<li><strong>a)</strong>
+ Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
@@ -349,7 +386,8 @@
Library will not necessarily be able to recompile the application
to use the modified definitions.)
- <li><strong>b)</strong> Use a suitable shared library mechanism for linking with the
+ <li><strong>b)</strong>
+ Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
@@ -357,18 +395,22 @@
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
- <li><strong>c)</strong> Accompany the work with a written offer, valid for at
+ <li><strong>c)</strong>
+ Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
- <li><strong>d)</strong> If distribution of the work is made by offering access to copy
+ <li><strong>d)</strong>
+ If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
- <li><strong>e)</strong> Verify that the user has already received a copy of these
+ <li><strong>e)</strong>
+ Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
</ul>
+</p>
<p>
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
@@ -378,40 +420,49 @@
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
+</p>
<p>
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
-<p>
-<strong>7.</strong> You may place library facilities that are a work based on the
+</p>
+
+<p><strong>7.</strong>
+You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
+</p>
<p>
<ul>
-<li><strong>a)</strong> Accompany the combined library with a copy of the same work
+<li><strong>a)</strong>
+ Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
- <li><strong>b)</strong> Give prominent notice with the combined library of the fact
+ <li><strong>b)</strong>
+ Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
</ul>
-<p>
-<strong>8.</strong> You may not copy, modify, sublicense, link with, or distribute
+</p>
+
+<p><strong>8.</strong>
+You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
-<p>
-<strong>9.</strong>
+</p>
+
+<p><strong>9.</strong>
You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
@@ -420,8 +471,9 @@
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
-<p>
-<strong>10.</strong>
+</p>
+
+<p><strong>10.</strong>
Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
@@ -429,8 +481,9 @@
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
-<p>
-<strong>11.</strong>
+</p>
+
+<p><strong>11.</strong>
If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
@@ -443,10 +496,12 @@
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
+</p>
<p>
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
+</p>
<p>
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
@@ -458,11 +513,13 @@
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
+</p>
<p>
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
-<p>
-<strong>12.</strong>
+</p>
+
+<p><strong>12.</strong>
If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License may add
@@ -470,12 +527,14 @@
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
-<p>
-<strong>13.</strong>
+</p>
+
+<p><strong>13.</strong>
The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
+</p>
<p>
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
@@ -484,8 +543,9 @@
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
-<p>
-<strong>14.</strong>
+</p>
+
+<p><strong>14.</strong>
If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
@@ -494,10 +554,11 @@
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
-<p>
-<strong>NO WARRANTY</strong>
-<p>
-<strong>15.</strong>
+</p>
+<p><strong>NO WARRANTY</strong>
+</p>
+
+<p><strong>15.</strong>
BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
@@ -507,8 +568,9 @@
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
-<p>
-<strong>16.</strong>
+</p>
+
+<p><strong>16.</strong>
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
@@ -519,8 +581,10 @@
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
-<p>
+</p>
+
<h2>END OF TERMS AND CONDITIONS</h2>
+
</DIV>
</BODY>
</HTML>
16 years, 6 months
JBoss Native SVN: r1515 - branches.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-03 12:46:52 -0400 (Thu, 03 Apr 2008)
New Revision: 1515
Removed:
branches/JBNATIVE_2_0_4/
Log:
Remove premature tag
16 years, 6 months
JBoss Native SVN: r1514 - in trunk/utils/windows/native/service: jbosssvc and 1 other directory.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-03 12:45:27 -0400 (Thu, 03 Apr 2008)
New Revision: 1514
Modified:
trunk/utils/windows/native/service/examples/service.bat
trunk/utils/windows/native/service/jbosssvc/jboss.c
Log:
Fix shutting down service on logoff event
Modified: trunk/utils/windows/native/service/examples/service.bat
===================================================================
--- trunk/utils/windows/native/service/examples/service.bat 2008-04-03 12:25:19 UTC (rev 1513)
+++ trunk/utils/windows/native/service/examples/service.bat 2008-04-03 16:45:27 UTC (rev 1514)
@@ -22,6 +22,9 @@
set SVCDESC=JBoss Application Server @VERSION@/Platform: @VERSION_PLATFORM@
set NOPAUSE=Y
+REM Suppress killing service on logoff event
+set JAVA_OPTS=-Xrs
+
REM Figure out the running mode
if /I "%1" == "install" goto cmdInstall
Modified: trunk/utils/windows/native/service/jbosssvc/jboss.c
===================================================================
--- trunk/utils/windows/native/service/jbosssvc/jboss.c 2008-04-03 12:25:19 UTC (rev 1513)
+++ trunk/utils/windows/native/service/jbosssvc/jboss.c 2008-04-03 16:45:27 UTC (rev 1514)
@@ -841,7 +841,7 @@
return TRUE;
break;
case CTRL_LOGOFF_EVENT:
- if (_service_mode == mode_run) {
+ if (_service_mode == mode_debug) {
ServiceStop();
}
return TRUE;
16 years, 6 months
JBoss Native SVN: r1513 - branches.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-03 08:25:19 -0400 (Thu, 03 Apr 2008)
New Revision: 1513
Added:
branches/JBNATIVE_2_0_4/
Log:
Tag native version 2.0.4
Copied: branches/JBNATIVE_2_0_4 (from rev 1512, trunk)
16 years, 6 months
JBoss Native SVN: r1512 - trunk/build/unix.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-03 08:13:02 -0400 (Thu, 03 Apr 2008)
New Revision: 1512
Modified:
trunk/build/unix/buildbin.jboss-native.windows.sh
Log:
Do not build jbosssch. It's not used anywhere (for now)
Modified: trunk/build/unix/buildbin.jboss-native.windows.sh
===================================================================
--- trunk/build/unix/buildbin.jboss-native.windows.sh 2008-04-03 12:00:23 UTC (rev 1511)
+++ trunk/build/unix/buildbin.jboss-native.windows.sh 2008-04-03 12:13:02 UTC (rev 1512)
@@ -74,9 +74,10 @@
nmake -f NMAKEmakefile WITH_APR=${win_common_loc} ${add_conf} SRCDIR=${src_dir} install
)
-(cd service/jbosssch
- nmake -f NMAKEmakefile PREFIX=${win_prefix_loc} install
-)
+# Uncomment to build jbosssch
+# (cd service/jbosssch
+# nmake -f NMAKEmakefile PREFIX=${win_prefix_loc} install
+# )
(cd service/jbosssvc
nmake -f NMAKEmakefile PREFIX=${win_prefix_loc} install
16 years, 6 months
JBoss Native SVN: r1511 - trunk/utils/windows/native/service/procrun.
by jbossnative-commits@lists.jboss.org
Author: mladen.turk(a)jboss.com
Date: 2008-04-03 08:00:23 -0400 (Thu, 03 Apr 2008)
New Revision: 1511
Removed:
trunk/utils/windows/native/service/procrun/NMAKEcommon.inc
Modified:
trunk/utils/windows/native/service/procrun/NMAKEmgr
trunk/utils/windows/native/service/procrun/NMAKEsvc
Log:
Decorate output files with correct cpu suffix
Deleted: trunk/utils/windows/native/service/procrun/NMAKEcommon.inc
===================================================================
--- trunk/utils/windows/native/service/procrun/NMAKEcommon.inc 2008-04-03 11:58:52 UTC (rev 1510)
+++ trunk/utils/windows/native/service/procrun/NMAKEcommon.inc 2008-04-03 12:00:23 UTC (rev 1511)
@@ -1,344 +0,0 @@
-# Copyright 2001-2006 The Apache Software Foundation or its licensors, as
-# applicable.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# ====================================================================
-#
-# NMAKEcommon.inc Master makefile definitions.
-# This file defines CPU architecture and basic compiler
-# and linker parameters.
-# Common params:
-# CPU Compile for specified CPU. Supported CPU's are:
-# X86 (Common x86 architecture)
-# X64 (AMD64/EMT64 architecture)
-# I64 (Intel IA64 architecture)
-# If not specified it will default to the
-# PROCESSOR_ARCHITECTURE environment variable
-# or to the X86 if not specified.
-# WINVER Compile for specified Windows version
-# WINNT for Windows 2000 and up(default)
-# WINXP for Windows XP and up
-# WIN2003 for Windows 2003 and up
-# VSITA for Windows Vista and up
-# Deprecated targets (may not even compile):
-# NT4 for Windows NT4 and up
-# WIN9X for Windows 95, 98 and Me
-# BUILD Build version
-# RETAIL or RELEASE (default)
-# DEBUG
-# TARGET Build application target
-# EXE Console executable (default)
-# GUI Windows GUI executable
-# DLL Dynamic Link Library
-# LIB Static library
-# Environment variables used:
-# CFLAGS Added to the common CFLAGS
-# CPPFLAGS Added to the common CPPFLAGS
-# LIBS Added to the common LIBS
-# INCLUDES Added to the common INCLUDES
-# LFLAGS Added to the common LFLAGS
-# RCFLAGS Added to the common RCFLAGS
-#
-# Compiler tools environment variables:
-# CC C compiler (defaults to cl.exe)
-# LINK Linker (defaults to link.exe)
-# RC Resource compiler (defaults to rc.exe)
-# MT Manifest toolkit (defaults to mt.exe)
-# ML Assembler (defaults to ml.exe or ml64.exe)
-#
-# Originally contributed by Mladen Turk <mturk jboss.com>
-#
-# ====================================================================
-#
-
-!IF !DEFINED(CC) || "$(CC)" == ""
-CC = cl.exe
-!ENDIF
-
-!IF !DEFINED(LINK) || "$(LINK)" == ""
-LINK = link.exe
-!ENDIF
-
-!IF !DEFINED(RC) || "$(RC)" == ""
-RC = rc.exe
-!ENDIF
-
-!IF !DEFINED(MT) || "$(MT)" == ""
-MT = mt.exe
-!ENDIF
-
-# Read the PROCESSOR_ARCHITECTURE environment value for a CPU type
-
-!IF "$(BUILD_CPU)" == "i386" || "$(BUILD_CPU)" == "x86" || "$(BUILD_CPU)" == "i686"
-CPU=X86
-!ENDIF
-!IF "$(BUILD_CPU)" == "amd64" || "$(BUILD_CPU)" == "x86_64" || "$(BUILD_CPU)" == "x64"
-CPU=X64
-!ENDIF
-!IF "$(BUILD_CPU)" == "ia64" || "$(BUILD_CPU)" == "i64"
-CPU=I64
-!ENDIF
-
-!IF !DEFINED(CPU) || "$(CPU)" == ""
-!IF "$(PROCESSOR_ARCHITECTURE)" == ""
-!IF "$(PROCESSOR_ARCHITEW6432)" == ""
-CPU=X86
-!ELSE
-CPU=$(PROCESSOR_ARCHITEW6432)
-!ENDIF
-!ELSE
-CPU=$(PROCESSOR_ARCHITECTURE)
-!ENDIF
-!ENDIF
-
-
-!IF "$(CPU)" == "I386"
-CPU=X86
-!ENDIF
-!IF "$(CPU)" == "AMD64"
-CPU=X64
-!ENDIF
-!IF "$(CPU)" == "IA64"
-CPU=I64
-!ENDIF
-
-!IF "$(CPU)" != "X86"
-!IF "$(CPU)" != "X64"
-!IF "$(CPU)" != "I64"
-!ERROR Must specify CPU environment variable (X86, X64, I64) $(CPU)
-!ENDIF
-!ENDIF
-!ENDIF
-
-!IF !DEFINED(TARGET) || "$(TARGET)" == ""
-TARGET=EXE
-!ENDIF
-
-!IF "$(TARGET)" != "EXE"
-!IF "$(TARGET)" != "GUI"
-!IF "$(TARGET)" != "DLL"
-!IF "$(TARGET)" != "LIB"
-!ERROR Must specify TARGET environment variable (EXE, GUI, DLL, LIB)
-!ENDIF
-!ENDIF
-!ENDIF
-!ENDIF
-
-!IF !DEFINED(WINVER) || "$(WINVER)" == ""
-WINVER=WINXP
-!ENDIF
-
-
-!IF "$(WINVER)" != "WINNT"
-!IF "$(WINVER)" != "WINXP"
-!IF "$(WINVER)" != "WIN2003"
-!IF "$(WINVER)" != "NT4"
-!IF "$(WINVER)" != "WIN9X"
-!IF "$(WINVER)" != "WVSITA"
-!ERROR Must specify WINVER environment variable (WINNT, WINXP, WIN2003, VSITA, NT4, WIN9X)
-!ENDIF
-!ENDIF
-!ENDIF
-!ENDIF
-!ENDIF
-!ENDIF
-
-!IF "$(WINVER)" == "WINNT"
-NMAKE_WINVER = 0x0500
-_WIN32_IE = 0x0500
-!ELSEIF "$(WINVER)" == "WINXP"
-NMAKE_WINVER = 0x0501
-_WIN32_IE = 0x0600
-!ELSEIF "$(WINVER)" == "WIN2003"
-NMAKE_WINVER = 0x0502
-_WIN32_IE = 0x0600
-!ELSEIF "$(WINVER)" == "VSITA"
-NMAKE_WINVER = 0x0600
-_WIN32_IE = 0x0700
-!ELSEIF "$(WINVER)" == "NT4"
-NMAKE_WINVER = 0x0400
-_WIN32_IE = 0x0400
-!ELSE
-!ERROR Must specify WINVER environment variable (WINNT, WINXP, WIN2003, VSITA, NT4, WIN9X)
-!ENDIF
-
-!IF !DEFINED(NMAKE_WINVER) || "$(NMAKE_WINVER)" == ""
-NMAKE_WINVER = 0x0400
-_WIN32_IE = 0x0400
-NMAKE_WINNT = -D_WIN95 -D_WIN32_WINDOWS=$(NMAKE_WINVER) -DWINVER=$(NMAKE_WINVER) -D_WIN32_IE=$(_WIN32_IE)
-!ELSE
-NMAKE_WINNT = -D_WINNT -D_WIN32_WINNT=$(NMAKE_WINVER) -DWINVER=$(NMAKE_WINVER) -D_WIN32_IE=$(_WIN32_IE)
-!ENDIF
-
-!IF !DEFINED(BUILD) || "$(BUILD)" == ""
-BUILD=RELEASE
-!ENDIF
-
-!IFDEF RELEASE
-BUILD=RELEASE
-!ENDIF
-
-!IFDEF DEBUG
-BUILD=DEBUG
-!ENDIF
-
-!IFDEF NODEBUG
-BUILD=RELEASE
-!ENDIF
-
-!IF "$(BUILD)" != "RELEASE"
-!IF "$(BUILD)" != "DEBUG"
-!ERROR Must specify BUILD environment variable (RELEASE, DEBUG)
-!ENDIF
-!ENDIF
-
-# Common flags for all platforms
-CMN_CFLAGS = -c -nologo -DWIN32 -D_WIN32 -D_WINDOWS $(NMAKE_WINNT) -W3
-!IF "$(TARGET)" == "EXE"
-CMN_CFLAGS = $(CMN_CFLAGS) -D_CONSOLE
-!ENDIF
-
-!IF "$(CPU)" == "X86"
-CPU_CFLAGS = -D_X86_=1
-MACHINE=X86
-!ELSEIF "$(CPU)" == "X64"
-CPU_CFLAGS = -D_AMD64_=1 -DWIN64 -D_WIN64 -Wp64
-MACHINE=AMD64
-!ELSEIF "$(CPU)" == "I64"
-CPU_CFLAGS = -D_IA64_=1 -DWIN64 -D_WIN64 -Wp64
-MACHINE=IA64
-!ENDIF
-
-!IF "$(INCLUDE_PRE64PRA)" == "1"
-!IF "$(CPU)" != "X86"
-CPU_CFLAGS = $(CPU_CFLAGS) /FIPRE64PRA.H
-!ENDIF
-!ENDIF
-
-!IF "$(BUILD)" == "RELEASE"
-!IF "$(CPU)" == "X86"
-OPT_CFLAGS = -O2 -Ob2 -Oy- -Zi -DNDEBUG
-!ELSE
-OPT_CFLAGS = -O2 -Ob2 -Zi -DNDEBUG
-!ENDIF
-!ELSE
-OPT_CFLAGS = -Od -Zi -DDEBUG -D_DEBUG
-!ENDIF
-
-!IF DEFINED(STATIC_CRT)
-CRT_CFLAGS = -D_MT -MT
-!ELSE
-CRT_CFLAGS = -D_MT -MD
-!ENDIF
-
-!IF "$(BUILD)" == "DEBUG"
-CRT_CFLAGS = $(CRT_CFLAGS)d
-!ENDIF
-
-CFLAGS = $(CMN_CFLAGS) $(CPU_CFLAGS) $(OPT_CFLAGS) $(CRT_CFLAGS) $(CFLAGS)
-
-!IF DEFINED(EXTRA_CFLAGS)
-CFLAGS = $(CFLAGS) $(EXTRA_CFLAGS)
-!ENDIF
-
-
-# Linker section
-LIBS = kernel32.lib advapi32.lib ws2_32.lib mswsock.lib ole32.lib shell32.lib rpcrt4.lib $(LIBS)
-!IF "$(INCLUDE_BUFFEROVERFLOWU)" == "1"
-!IF "$(CPU)" != "X86"
-LIBS = $(LIBS) bufferoverflowu.lib
-!ENDIF
-!ENDIF
-
-!IF DEFINED(EXTRA_LIBS)
-LIBS = $(LIBS) $(EXTRA_LIBS)
-!ENDIF
-
-COMMON_LFLAGS = /NOLOGO
-
-# Always add debugging to the linker
-OPT_LFLAGS = /INCREMENTAL:NO /DEBUG
-!IF "$(BUILD)" == "RELEASE"
-OPT_LFLAGS = /OPT:REF
-!ENDIF
-
-!IF "$(TARGET)" == "EXE"
-LFLAGS = $(COMMON_LFLAGS) /SUBSYSTEM:CONSOLE /MACHINE:$(MACHINE)
-!ELSEIF "$(TARGET)" == "GUI"
-LFLAGS = $(COMMON_LFLAGS) /SUBSYSTEM:WINDOWS /MACHINE:$(MACHINE)
-!ELSEIF "$(TARGET)" == "DLL"
-LFLAGS = $(COMMON_LFLAGS) /DLL /SUBSYSTEM:WINDOWS /MACHINE:$(MACHINE)
-!ELSEIF "$(TARGET)" == "LIB"
-LFLAGS = -lib $(COMMON_LFLAGS)
-!ENDIF
-
-!IF DEFINED(EXTRA_LFLAGS)
-LFLAGS = $(LFLAGS) $(EXTRA_LFLAGS)
-!ENDIF
-
-!IF "$(TARGET)" != "LIB"
-LFLAGS = $(LFLAGS) $(OPT_LFLAGS)
-!ENDIF
-
-# Resource compiler flags
-
-BASE_RCFLAGS=/l 0x409
-!IF "$(BUILD)" == "RELEASE"
-BASE_RCFLAGS = $(BASE_RCFLAGS) /d "NDEBUG"
-!ELSE
-BASE_RCFLAGS = $(BASE_RCFLAGS) /d "_DEBUG" /d "DEBUG"
-!ENDIF
-RCFLAGS = $(BASE_RCFLAGS) $(RCFLAGS)
-
-# Build Target dir e.g. WINNT_I386_RELEASE_DLL
-!IF !DEFINED(WORKDIR) || "$(WORKDIR)" == ""
-!IF !DEFINED(WORKDIR_EXT) || "$(WORKDIR_EXT)" == ""
-WORKDIR = $(WINVER)_$(CPU)_$(TARGET)_$(BUILD)
-WORKDIR_DLL = $(WINVER)_$(CPU)_DLL_$(BUILD)
-WORKDIR_LIB = $(WINVER)_$(CPU)_LIB_$(BUILD)
-WORKDIR_EXE = $(WINVER)_$(CPU)_EXE_$(BUILD)
-!ELSE
-WORKDIR = $(WINVER)_$(CPU)_$(BUILDIR_EXT)_$(BUILD)
-!ENDIF
-!ENDIF
-
-!IF "$(OS)" == "Windows_NT"
-CLEANTARGET=if exist "$(WORKDIR)\$(NULL)" rd /s /q $(WORKDIR)
-!ELSE
-CLEANTARGET=deltree /y $(BUILDIR)
-!ENDIF
-
-MAKEWORKDIR=if not exist "$(WORKDIR)\$(NULL)" mkdir $(WORKDIR)
-MAKEINSTALL=if not exist "$(INSTALLLOC)" mkdir $(INSTALLLOC)
-
-!IF DEFINED(JAVA_HOME) && "$(JAVA_HOME)" != ""
-JAVA_INCLUDES=-I "$(JAVA_HOME)\include"
-!IF "$(CPU)" != "X86"
-JAVA_INCLUDES=$(JAVA_INCLUDES) -I "$(JAVA_HOME)\include\win64"
-!ENDIF
-JAVA_INCLUDES=$(JAVA_INCLUDES) -I "$(JAVA_HOME)\include\win32"
-!ENDIF
-
-!IF !DEFINED(ML) || "$(ML)" == ""
-!IF "$(CPU)" == "X86"
-ML = ml.exe
-AFLAGS = /coff /Zi /c
-!ELSEIF "$(CPU)" == "X64"
-ML = ml64.exe
-AFLAGS = /Zi /c
-!ELSEIF "$(CPU)" == "I64"
-ML = ml64.exe
-AFLAGS = /coff /Zi /c
-!ENDIF
-!ENDIF
Modified: trunk/utils/windows/native/service/procrun/NMAKEmgr
===================================================================
--- trunk/utils/windows/native/service/procrun/NMAKEmgr 2008-04-03 11:58:52 UTC (rev 1510)
+++ trunk/utils/windows/native/service/procrun/NMAKEmgr 2008-04-03 12:00:23 UTC (rev 1511)
@@ -23,7 +23,7 @@
TARGET = GUI
PROJECT = jbosswebw
-!include <NMAKEcommon.inc>
+!include <..\..\NMAKEcommon.inc>
!IF !DEFINED(SRCDIR) || "$(SRCDIR)" == ""
SRCDIR = .
@@ -49,7 +49,13 @@
$(WORKDIR)\prunmgr.obj
BUILDLOC = $(PREFIX)\bin
+!IF "$(CPU)" == "X86"
BUILDEXE = $(WORKDIR)\$(PROJECT).exe
+!ELSEIF "$(CPU)" == "X64"
+BUILDEXE = $(WORKDIR)\$(PROJECT).x64.exe
+!ELSEIF "$(CPU)" == "I64"
+BUILDEXE = $(WORKDIR)\$(PROJECT).i64.exe
+!ENDIF
BUILDPDB = $(WORKDIR)\$(PROJECT).pdb
BUILDRES = $(WORKDIR)\$(PROJECT).res
BUILDMAN = $(BUILDEXE).manifest
Modified: trunk/utils/windows/native/service/procrun/NMAKEsvc
===================================================================
--- trunk/utils/windows/native/service/procrun/NMAKEsvc 2008-04-03 11:58:52 UTC (rev 1510)
+++ trunk/utils/windows/native/service/procrun/NMAKEsvc 2008-04-03 12:00:23 UTC (rev 1511)
@@ -23,7 +23,7 @@
TARGET = EXE
PROJECT = jbossweb
-!include <NMAKEcommon.inc>
+!include <..\..\NMAKEcommon.inc>
!IF !DEFINED(SRCDIR) || "$(SRCDIR)" == ""
SRCDIR = .
@@ -53,7 +53,13 @@
$(WORKDIR)\prunsrv.obj
BUILDLOC = $(PREFIX)\bin
+!IF "$(CPU)" == "X86"
BUILDEXE = $(WORKDIR)\$(PROJECT).exe
+!ELSEIF "$(CPU)" == "X64"
+BUILDEXE = $(WORKDIR)\$(PROJECT).x64.exe
+!ELSEIF "$(CPU)" == "I64"
+BUILDEXE = $(WORKDIR)\$(PROJECT).i64.exe
+!ENDIF
BUILDPDB = $(WORKDIR)\$(PROJECT).pdb
BUILDRES = $(WORKDIR)\$(PROJECT).res
BUILDMAN = $(BUILDEXE).manifest
16 years, 6 months