2001-12-11 00:02 UTC+0100 Viktor Szakats <viktor.szakats@syenar.hu>

This commit is contained in:
Viktor Szakats
2001-12-10 23:18:13 +00:00
parent 18ae662b32
commit ff8174fb93
13 changed files with 119 additions and 526 deletions

View File

@@ -1,3 +1,63 @@
/*
* $Id$
*/
/* Use this format for the entry headers:
YYYY-MM-DD HH:MM UTC[-|+]hhmm Your Full Name <your_email@address>
For example:
2002-12-01 23:12 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2001-12-11 00:02 UTC+0100 Viktor Szakats <viktor.szakats@syenar.hu>
+ ChangeLog
+ Added CVS ID
+ Added comment about the standard entry header.
- source/vm/borinit.c
- source/vm/borsym.asm
- source/vm/startup.asm
- source/vm/symbols.asm
* source/vm/hvm.c
* makefile.bc
* makefile.vc
! Removed assembler parts. TASM is no longer required to
build Harbour.
- source/common/hash.c
+ source/common/hbhash.c
* source/common/Makefile
* makefile.vc
* makefile.bc
* File hash.c renamed to hbhash.c.
+ source/common/hbfhnd.c
* source/common/hbfsapi.c
* source/common/Makefile
* makefile.vc
* makefile.bc
! File handle tweaking functions moved to a separate
source file.
* source/common/hbgete.c
* Some tweaks.
* source/vm/hvm.c
- Removed some line not needed anymore, related to
Windows exception handler.
* source/vm/estack.c
- Removed a faulty #define.
* makefile.bc
* makefile.vc
+ Added note to not modify these files to add
optional command line switches.
* makefile.bc
- Removed explicit debug switches from on PDF
related file and from the 16 bit branch.
2001-12-10 19:55 GMT+1 Antonio Linares <alinares@fivetech.com>
* harbour/source/common/hbgete.c
* some fixes

View File

@@ -6,6 +6,12 @@
# Makefile for Harbour Project for Borland C/C++ 3.x, 4.x, 5.x compilers
#
# ---------------------------------------------------------------
# If you need to set additional compiler/linker options use the
# environment variables below, but please DON'T MODIFY THIS FILE
# for this purpose.
# ---------------------------------------------------------------
#
# NOTE: You can use these envvars to configure the make process:
# (note that these are all optional)
@@ -59,7 +65,7 @@ CC = bcc
AS = tasm
# Borland C/C++ (DOS 16 bits)
CFLAGS = -mh $(CFLAGS) -v -y
CFLAGS = -mh $(CFLAGS)
BIN_DIR = bin\b16
OBJ_DIR = obj\b16
@@ -497,12 +503,13 @@ DEBUG_LIB_OBJS = \
#
COMMON_LIB_OBJS = \
$(OBJ_DIR)\hbfhnd.obj \
$(OBJ_DIR)\hbfsapi.obj \
$(OBJ_DIR)\hbgete.obj \
$(OBJ_DIR)\hbhash.obj \
$(OBJ_DIR)\hbstr.obj \
$(OBJ_DIR)\hbtrace.obj \
$(OBJ_DIR)\hbver.obj \
$(OBJ_DIR)\hash.obj \
$(OBJ_DIR)\expropt1.obj \
$(OBJ_DIR)\expropt2.obj \
$(OBJ_DIR)\reserved.obj
@@ -737,6 +744,10 @@ $(GTWIN_LIB) : $(GTWIN_LIB_OBJS)
# COMMON.LIB dependencies
#
$(OBJ_DIR)\hbfhnd.obj : $(COMMON_DIR)\hbfhnd.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\hbfsapi.obj : $(COMMON_DIR)\hbfsapi.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
@@ -745,6 +756,10 @@ $(OBJ_DIR)\hbgete.obj : $(COMMON_DIR)\hbgete.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\hbhash.obj : $(COMMON_DIR)\hbhash.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\hbstr.obj : $(COMMON_DIR)\hbstr.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
@@ -757,10 +772,6 @@ $(OBJ_DIR)\hbver.obj : $(COMMON_DIR)\hbver.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\hash.obj : $(COMMON_DIR)\hash.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\expropt1.obj : $(COMMON_DIR)\expropt1.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(COMMON_LIB) $(ARFLAGS) -+$@,,
@@ -1139,22 +1150,6 @@ $(OBJ_DIR)\runner.obj : $(VM_DIR)\runner.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(VM_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\borinit.obj : $(VM_DIR)\borinit.c
$(CC) $(CLIBFLAGS) -o$@ $**
tlib $(VM_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\borsym.obj : $(VM_DIR)\borsym.asm
$(AS) -ml $**, $@
tlib $(VM_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\startup.obj : $(VM_DIR)\startup.asm
$(AS) -ml $**, $@
tlib $(VM_LIB) $(ARFLAGS) -+$@,,
$(OBJ_DIR)\symbols.obj : $(VM_DIR)\symbols.asm
$(AS) -ml $**, $@
tlib $(VM_LIB) $(ARFLAGS) -+$@,,
#
# RTL.LIB dependencies
#
@@ -2610,7 +2605,7 @@ $(OBJ_DIR)\genpdf1.obj : $(OBJ_DIR)\genpdf1.c
$(CC) $(CLIBFLAGS) -o$@ $**
$(OBJ_DIR)\pdfhbdoc.obj : $(HBPDF_DIR)\pdfhbdoc.c
$(CC) $(CLIBFLAGS) -v -y -I$(HBPDF_DIR) -o$@ $**
$(CC) $(CLIBFLAGS) -I$(HBPDF_DIR) -o$@ $**
!endif
$(HBMAKE_EXE) : $(HBMAKE_EXE_OBJS)

View File

@@ -6,6 +6,12 @@
# Makefile for Harbour Project for Microsoft Visual C (32 bit)
#
# ---------------------------------------------------------------
# If you need to set additional compiler/linker options use the
# environment variables below, but please DON'T MODIFY THIS FILE
# for this purpose.
# ---------------------------------------------------------------
#
# NOTE: You can use these envvars to configure the make process:
# (note that these are all optional)
@@ -599,11 +605,12 @@ DEBUG_LIB_OBJS = \
$(CC) $(CLIBFLAGS) -Fo$(OBJ_DIR)\ $<
COMMON_LIB_OBJS = \
$(OBJ_DIR)\hbhash.obj \
$(OBJ_DIR)\hbfhnd.obj \
$(OBJ_DIR)\hbfsapi.obj \
$(OBJ_DIR)\hbstr.obj \
$(OBJ_DIR)\hbtrace.obj \
$(OBJ_DIR)\hbver.obj \
$(OBJ_DIR)\hash.obj \
$(OBJ_DIR)\expropt1.obj \
$(OBJ_DIR)\expropt2.obj \
$(OBJ_DIR)\reserved.obj
@@ -612,11 +619,6 @@ COMMON_LIB_OBJS = \
# VM.LIB rules
#
{$(VM_DIR)}.asm{$(OBJ_DIR)}.obj:
rem lib /extract:$(OBJ_DIR)\symbols.obj /out:$(OBJ_DIR)\symbols.obj \harb35\lib\vm.lib
rem $(AS) $< $@ nul nul
$(AS) /c /Fo$@ $<
{$(VM_DIR)}.c{$(OBJ_DIR)}.obj:
$(CC) $(CLIBFLAGS) -Fo$(OBJ_DIR)\ $<

View File

@@ -5,11 +5,12 @@
ROOT = ../../
C_SOURCES=\
hbfhnd.c \
hbfsapi.c \
hbhash.c \
hbstr.c \
hbtrace.c \
hbver.c \
hash.c \
reserved.c \
expropt1.c \
expropt2.c \

View File

@@ -49,28 +49,10 @@
* If you do not wish that, delete this exception notice.
*
*/
#include "hbapi.h"
#include "hbapifs.h"
#if defined(__BORLANDC__)
#define ___NFILE_H
#ifdef _NFILE_
#undef _NFILE_
#endif
#define _NFILE_ 600
#include <fcntl.h>
#include <stdio.h>
void _hbfilessetup(void);
#pragma startup _hbfilessetup
extern void _RTLENTRY _init_handles(void);
#pragma startup _init_handles 4
extern void _RTLENTRY _init_streams(void);
#pragma startup _init_streams 5
#endif
/*
* Function that adds at most one path to a list of pathnames to search
*/
@@ -271,43 +253,3 @@ char * hb_fsFNameMerge( char * pszFileName, PHB_FNAME pFileName )
return pszFileName;
}
#if defined(__BORLANDC__)
/*----------------------------------------------------------------------
* The following external reference forces _init_handles (in handles.c)
* to be called at startup.
*/
unsigned int _RTLENTRY _openfd[_NFILE_] =
{
O_RDONLY | O_TEXT | O_DEVICE,
O_WRONLY | O_TEXT | O_DEVICE,
O_WRONLY | O_TEXT | O_DEVICE
};
unsigned int _RTLENTRY _pidtab[_NFILE_];
#ifdef __WIN32__
unsigned long _RTLENTRY _handles[_NFILE_];
#endif
#define _F_STDIN (_F_READ | _F_TERM | _F_LBUF)
#define _F_STDOUT (_F_WRIT | _F_TERM | _F_LBUF)
#define _F_STDERR (_F_WRIT | _F_TERM)
FILE _RTLENTRY _EXPDATA _streams [_NFILE_] =
{
{ NULL, NULL, 0, 0, 0, _F_STDIN, 0, 0, 0 },
{ NULL, NULL, 0, 0, 0, _F_STDOUT, 0, 1, 0 },
{ NULL, NULL, 0, 0, 0, _F_STDERR, 0, 2, 0 }
};
void _hbfilessetup(void)
{
_nfile = _NFILE_;
}
#endif

View File

@@ -6,7 +6,7 @@
* Harbour Project source code:
* environment variables access
*
* Copyright 2001 Antonio Linares <alinares@fivetech.com>
* Copyright 2001-2002 Antonio Linares <alinares@fivetech.com>
* www - http://www.harbour-project.org
*
* This program is free software; you can redistribute it and/or modify
@@ -50,9 +50,8 @@
*
*/
/* Notice that this code is needed as ANSI C getenv() crashes
* so badly when used from a Windows DLL
*/
/* NOTE: Notice that this code is needed as ANSI C getenv() crashes
so badly when used from a Windows DLL. */
#define HB_OS_WIN_32_USED
@@ -61,21 +60,30 @@
char * hb_getenv( const char * name )
{
char * pszBuffer = ( char * ) hb_xgrab( 255 );
char * pszTemp;
#ifdef HB_OS_WIN_32
DWORD nSize;
GetEnvironmentVariable( name, pszBuffer,
( nSize = GetEnvironmentVariable( name, pszBuffer, 0 ) ) );
#ifdef HB_OS_WIN_32
{
DWORD nSize = GetEnvironmentVariable( name, pszBuffer, 0 );
if( nSize == 0 )
pszBuffer[ 0 ] = '\0';
#else
pszTemp = getenv( name );
if( pszTemp != NULL )
strcpy( pszBuffer, pszTemp );
else
GetEnvironmentVariable( name, pszBuffer, nSize );
}
#else
{
char * pszTemp = getenv( name );
if( pszTemp == NULL )
pszBuffer[ 0 ] = '\0';
#endif
else
strcpy( pszBuffer, pszTemp );
}
#endif
return pszBuffer;
}
}

View File

@@ -6,7 +6,7 @@
* Harbour Project source code:
* Harbour simple hash table implementation
*
* Copyright 1999 Ryszard Glab <rglab@imid.med.pl>
* Copyright 1999-2002 Ryszard Glab <rglab@imid.med.pl>
* www - http://www.harbour-project.org
*
* This program is free software; you can redistribute it and/or modify

View File

@@ -1,79 +0,0 @@
/*
* $Id$
*/
/*
* Harbour Project source code:
* Borland _INIT_ segment initialization when not using Borland C startup
*
* Copyright 1999 Antonio Linares <alinares@fivetech.com>
* www - http://www.harbour-project.org
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this software; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
* Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
*
* As a special exception, the Harbour Project gives permission for
* additional uses of the text contained in its release of Harbour.
*
* The exception is that, if you link the Harbour libraries with other
* files to produce an executable, this does not by itself cause the
* resulting executable to be covered by the GNU General Public License.
* Your use of that executable is in no way restricted on account of
* linking the Harbour library code into it.
*
* This exception does not however invalidate any other reasons why
* the executable file might be covered by the GNU General Public License.
*
* This exception applies only to the code released by the Harbour
* Project under the name Harbour. If you copy code from other
* Harbour Project or Free Software Foundation releases into a copy of
* Harbour, as the General Public License permits, the exception does
* not apply to the code that you add in this way. To avoid misleading
* anyone as to the status of such modified files, you must delete
* this exception notice from them.
*
* If you write modifications of your own for Harbour, it is your choice
* whether to permit this exception to apply to your modifications.
* If you do not wish that, delete this exception notice.
*
*/
#if (__BORLANDC__ > 1040) /* Use this only above Borland C++ 3.1 */
#pragma option -a1 /* byte alignment */
#endif
typedef struct
{
char calltype;
char priority;
void ( * pFunc )( void );
} HB_BORINITSYMBOL, * HB_PBORINITSYMBOL;
extern HB_BORINITSYMBOL hb_BorFirstSymbol, hb_BorLastSymbol;
void hb_vmProcessBorlandInitSegment( void )
{
HB_PBORINITSYMBOL pFirst = &hb_BorFirstSymbol;
while( pFirst < ( &hb_BorLastSymbol - 1 ) )
{
( pFirst++ )->pFunc();
while( * ( ( char * ) pFirst ) == 0 ) /* specially for Borland _INIT_ */
( ( char * ) pFirst )++; /* segment alignment */
( ( char * ) pFirst )--;
}
}

View File

@@ -1,73 +0,0 @@
;
; $Id$
;
; Harbour Project source code:
; Borland _INIT_ segment bounds when not using Borland startup
;
; Copyright 1999 Antonio Linares <alinares@fivetech.com>
; www - http://www.harbour-project.org
;
; This program is free software; you can redistribute it and/or modify
; it under the terms of the GNU General Public License as published by
; the Free Software Foundation; either version 2, or (at your option)
; any later version.
;
; This program is distributed in the hope that it will be useful,
; but WITHOUT ANY WARRANTY; without even the implied warranty of
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
; GNU General Public License for more details.
;
; You should have received a copy of the GNU General Public License
; along with this software; see the file COPYING. If not, write to
; the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
; Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
;
; As a special exception, the Harbour Project gives permission for
; additional uses of the text contained in its release of Harbour.
;
; The exception is that, if you link the Harbour libraries with other
; files to produce an executable, this does not by itself cause the
; resulting executable to be covered by the GNU General Public License.
; Your use of that executable is in no way restricted on account of
; linking the Harbour library code into it.
;
; This exception does not however invalidate any other reasons why
; the executable file might be covered by the GNU General Public License.
;
; This exception applies only to the code released by the Harbour
; Project under the name Harbour. If you copy code from other
; Harbour Project or Free Software Foundation releases into a copy of
; Harbour, as the General Public License permits, the exception does
; not apply to the code that you add in this way. To avoid misleading
; anyone as to the status of such modified files, you must delete
; this exception notice from them.
;
; If you write modifications of your own for Harbour, it is your choice
; whether to permit this exception to apply to your modifications.
; If you do not wish that, delete this exception notice.
;
.386
HB_STARTBORSYMBOLS segment dword use32 public 'INITDATA'
HB_STARTBORSYMBOLS ends
_INIT_ segment dword use32 public 'INITDATA'
_INIT_ ends
HB_ENDBORSYMBOLS segment dword use32 public 'INITDATA'
HB_ENDBORSYMBOLS ends
BORLAND group HB_STARTBORSYMBOLS, _INIT_, HB_ENDBORSYMBOLS
public _hb_BorFirstSymbol, _hb_BorLastSymbol
HB_STARTBORSYMBOLS segment
_hb_BorFirstSymbol label byte
HB_STARTBORSYMBOLS ends
HB_ENDBORSYMBOLS segment
_hb_BorLastSymbol label byte
HB_ENDBORSYMBOLS ends
end

View File

@@ -51,7 +51,6 @@
*/
#if defined(HARBOUR_OBJ_GENERATION) || defined(HB_INCLUDE_WINEXCHANDLER)
#define HB_OS_WIN_32
#define HB_OS_WIN_32_USED
#endif
@@ -62,14 +61,16 @@
#include "hbapierr.h"
/* ------------------------------- */
#if !defined( STACK_INITHB_ITEMS )
#define STACK_INITHB_ITEMS 200
#define STACK_INITHB_ITEMS 200
#endif
#if !defined( STACK_EXPANDHB_ITEMS )
#define STACK_EXPANDHB_ITEMS 20
#define STACK_EXPANDHB_ITEMS 20
#endif
HB_STACK hb_stack;
/* ------------------------------- */
void hb_stackPop( void )

View File

@@ -66,10 +66,6 @@
*
*/
#if defined(HARBOUR_OBJ_GENERATION) || defined(HB_INCLUDE_WINEXCHANDLER)
#define HB_OS_WIN_32_USED
#endif
#ifndef __MPW__
#include <malloc.h>
#endif
@@ -198,36 +194,6 @@ static void hb_vmDoInitFunctions( void ); /* executes all defined PRGs I
static void hb_vmDoExitFunctions( void ); /* executes all defined PRGs EXIT functions */
static void hb_vmReleaseLocalSymbols( void ); /* releases the memory of the local symbols linked list */
#ifdef HARBOUR_OBJ_GENERATION
/* TODO: Remove these (WORD/DWORD) when the compiler is cleaned up from them. */
#if defined(__IBMCPP__)
#undef WORD /* 2 bytes unsigned */
typedef unsigned short int WORD;
#else
#if ! defined(HB_DONT_DEFINE_BASIC_TYPES)
#undef WORD /* 2 bytes unsigned */
typedef unsigned short int WORD;
#endif
#endif
static void hb_vmProcessObjSymbols( void ); /* process Harbour generated OBJ symbols */
extern void hb_vmProcessBorlandInitSegment( void ); /* process Borland _INIT_ segment functions when not using Borland startup */
extern void hb_startup( void ); /* Harbour startup when not using a C compiler startup */
typedef struct
{
WORD wSymbols; /* module local symbol table symbols amount */
PHB_SYMB pSymbols; /* module local symbol table address */
} OBJSYMBOLS, * POBJSYMBOLS; /* structure used from Harbour generated OBJs */
#ifdef __cplusplus
extern "C" POBJSYMBOLS hb_firstsymbol, hb_lastsymbol;
#else
extern POBJSYMBOLS hb_firstsymbol, hb_lastsymbol;
#endif
#endif
extern void * hb_mthRequested( void ); /* profiler from classes.c */
extern void hb_mthAddTime( void *, ULONG ); /* profiler from classes.c */
@@ -310,10 +276,6 @@ void hb_vmInit( BOOL bStartMainProc )
hb_setInitialize(); /* initialize Sets */
hb_conInit(); /* initialize Console */
hb_memvarsInit();
#ifdef HARBOUR_OBJ_GENERATION
hb_vmProcessObjSymbols(); /* initialize Harbour generated OBJs symbols */
hb_vmProcessBorlandInitSegment(); /* initialize Borland _INIT_ segment if Borland OBJs linked */
#endif
hb_vmSymbolInit_RT(); /* initialize symbol table with runtime support functions */
/* Set the language to the default */
@@ -4315,20 +4277,8 @@ void hb_vmProcessSymbols( PHB_SYMB pModuleSymbols, USHORT uiModuleSymbols ) /* m
PSYMBOLS pNewSymbols;
USHORT ui;
#ifdef HARBOUR_OBJ_GENERATION
static BOOL s_bObjChecked = FALSE;
#endif
HB_TRACE(HB_TR_DEBUG, ("hb_vmProcessSymbols(%p, %hu)", pModuleSymbols, uiModuleSymbols));
#ifdef HARBOUR_OBJ_GENERATION
if( ! s_bObjChecked )
{
s_bObjChecked = TRUE;
hb_vmProcessObjSymbols(); /* to asure Harbour OBJ symbols are processed first */
}
#endif
pNewSymbols = ( PSYMBOLS ) hb_xgrab( sizeof( SYMBOLS ) );
pNewSymbols->pModuleSymbols = pModuleSymbols;
pNewSymbols->uiModuleSymbols = uiModuleSymbols;
@@ -4362,28 +4312,6 @@ void hb_vmProcessSymbols( PHB_SYMB pModuleSymbols, USHORT uiModuleSymbols ) /* m
}
}
#ifdef HARBOUR_OBJ_GENERATION
static void hb_vmProcessObjSymbols( void )
{
static BOOL s_bDone = FALSE;
HB_TRACE(HB_TR_DEBUG, ("hb_vmProcessObjSymbols()"));
if( ! s_bDone )
{
POBJSYMBOLS pObjSymbols = ( POBJSYMBOLS ) &hb_firstsymbol;
while( pObjSymbols < ( POBJSYMBOLS ) ( &hb_lastsymbol - 1 ) )
{
hb_vmProcessSymbols( pObjSymbols->pSymbols, pObjSymbols->wSymbols );
pObjSymbols++;
}
s_bDone = TRUE;
}
}
#endif
static void hb_vmReleaseLocalSymbols( void )
{
HB_TRACE(HB_TR_DEBUG, ("hb_vmReleaseLocalSymbols()"));
@@ -4516,16 +4444,13 @@ static void hb_vmDoInitFunctions( void )
/* NOTE: We should make sure that these get linked.
Don't make this function static, because it's not called from
this file. */
this file. [vszakats] */
void hb_vmForceLink( void )
{
HB_TRACE(HB_TR_DEBUG, ("hb_vmForceLink()"));
HB_FUNCNAME( SYSINIT )();
#ifdef HARBOUR_OBJ_GENERATION
hb_startup();
#endif
}
/* ----------------------------- */

View File

@@ -1,116 +0,0 @@
;
; $Id$
;
; Harbour Project source code:
; Harbour startup for Win32 when not using any C compiler startup
;
; Copyright 1999 Antonio Linares <alinares@fivetech.com>
; www - http://www.harbour-project.org
;
; This program is free software; you can redistribute it and/or modify
; it under the terms of the GNU General Public License as published by
; the Free Software Foundation; either version 2, or (at your option)
; any later version.
;
; This program is distributed in the hope that it will be useful,
; but WITHOUT ANY WARRANTY; without even the implied warranty of
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
; GNU General Public License for more details.
;
; You should have received a copy of the GNU General Public License
; along with this software; see the file COPYING. If not, write to
; the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
; Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
;
; As a special exception, the Harbour Project gives permission for
; additional uses of the text contained in its release of Harbour.
;
; The exception is that, if you link the Harbour libraries with other
; files to produce an executable, this does not by itself cause the
; resulting executable to be covered by the GNU General Public License.
; Your use of that executable is in no way restricted on account of
; linking the Harbour library code into it.
;
; This exception does not however invalidate any other reasons why
; the executable file might be covered by the GNU General Public License.
;
; This exception applies only to the code released by the Harbour
; Project under the name Harbour. If you copy code from other
; Harbour Project or Free Software Foundation releases into a copy of
; Harbour, as the General Public License permits, the exception does
; not apply to the code that you add in this way. To avoid misleading
; anyone as to the status of such modified files, you must delete
; this exception notice from them.
;
; If you write modifications of your own for Harbour, it is your choice
; whether to permit this exception to apply to your modifications.
; If you do not wish that, delete this exception notice.
;
.386
_TEXT segment para use32 public 'CODE'
_TEXT ends
_NULL segment dword use32 public 'DATA'
_NULL ends
_DATA segment dword use32 public 'DATA'
_DATA ends
_BSS segment dword use32 public 'BSS'
_BSS ends
FLAT group
DGROUP group _NULL, _BSS, _DATA
extrn GetModuleHandleA:near
extrn WinMain:near
public _hb_startup
_NULL segment
db 16 dup (0) ;Windows
db 4 dup (0) ;destructor count
db 2 dup (0) ;exception list
db 4 dup (0) ;exception vptr
db 6 dup (0) ;reserved
db 2 dup (0) ;VBX control jump vector
;MUST be at SS:20h
db 2 dup (0) ;reserved
db 50 dup (0) ;antonio
ends
_BSS segment
__bss label word
_BSS ends
_DATA segment
public __hInstance
__hInstance dw 0
public __hPrev
__hPrev dw 0
public __pszCmdLine
__pszCmdLine dw 0
public __CmdShow
__CmdShow dw 0
public __PSP
__PSP dw 0
_DATA ends
_TEXT segment
assume CS:_TEXT, DS:DGROUP
_hb_startup: push 0
call near ptr GetModuleHandleA
mov dword ptr __hInstance, eax
push 0
push 0
push 0
push 0
call near ptr WinMain
ret
_TEXT ends
end _hb_startup

View File

@@ -1,73 +0,0 @@
;
; $Id$
;
; Harbour Project source code:
; Symbol Initialization Support
;
; Copyright 1999 Antonio Linares <alinares@fivetech.com>
; www - http://www.harbour-project.org
;
; This program is free software; you can redistribute it and/or modify
; it under the terms of the GNU General Public License as published by
; the Free Software Foundation; either version 2, or (at your option)
; any later version.
;
; This program is distributed in the hope that it will be useful,
; but WITHOUT ANY WARRANTY; without even the implied warranty of
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
; GNU General Public License for more details.
;
; You should have received a copy of the GNU General Public License
; along with this software; see the file COPYING. If not, write to
; the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
; Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
;
; As a special exception, the Harbour Project gives permission for
; additional uses of the text contained in its release of Harbour.
;
; The exception is that, if you link the Harbour libraries with other
; files to produce an executable, this does not by itself cause the
; resulting executable to be covered by the GNU General Public License.
; Your use of that executable is in no way restricted on account of
; linking the Harbour library code into it.
;
; This exception does not however invalidate any other reasons why
; the executable file might be covered by the GNU General Public License.
;
; This exception applies only to the code released by the Harbour
; Project under the name Harbour. If you copy code from other
; Harbour Project or Free Software Foundation releases into a copy of
; Harbour, as the General Public License permits, the exception does
; not apply to the code that you add in this way. To avoid misleading
; anyone as to the status of such modified files, you must delete
; this exception notice from them.
;
; If you write modifications of your own for Harbour, it is your choice
; whether to permit this exception to apply to your modifications.
; If you do not wish that, delete this exception notice.
;
.386
HB_STARTSYMBOLS segment dword use32 public 'DATA'
HB_STARTSYMBOLS ends
HB_SYMBOLS segment dword use32 public 'DATA'
HB_SYMBOLS ends
HB_ENDSYMBOLS segment dword use32 public 'DATA'
HB_ENDSYMBOLS ends
DGROUP group HB_STARTSYMBOLS, HB_SYMBOLS, HB_ENDSYMBOLS
public _hb_firstsymbol, _hb_lastsymbol
HB_STARTSYMBOLS segment
_hb_firstsymbol label byte
HB_STARTSYMBOLS ends
HB_ENDSYMBOLS segment
_hb_lastsymbol label byte
HB_ENDSYMBOLS ends
end