Changeset 6533 for branches/mini/src


Ignore:
Timestamp:
Aug 15, 2001, 3:50:14 AM (24 years ago)
Author:
bird
Message:

down to 293 bytes.

Location:
branches/mini/src/win32k/test
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/mini/src/win32k/test/minihll.c

    r6532 r6533  
    11#ifdef __IBMC__
    2 #pragma strings(readonly)
     2#pragma strings(writeable)
    33#endif
    44
     5/*
     6 * Config
     7 */
    58//#define LIBC
    69
     10
     11
     12/*******************************************************************************
     13*   External Functions                                                         *
     14*******************************************************************************/
    715#ifndef LIBC
    8 
    9 #define INCL_DOSMISC
    10 #include <os2.h>
    11 /*unsigned long _System
    12 DosPutMessage(
    13     unsigned long hFile,
    14     unsigned long cchMsg,
    15     const char *  pszMsg);
    16 */
     16unsigned long _System DosPutMessage(unsigned long hFile,
     17                                    unsigned long cchMsg,
     18                                    char *  pszMsg);
    1719#else
    18 #include <stdio.h>
     20extern int    _Optlink printf( char * pszMsg, ...);
    1921#endif
    2022
    21 #ifdef __IBMC__
    22 #pragma entry(entry)
     23/*******************************************************************************
     24*   Global Variables                                                           *
     25*******************************************************************************/
     26#ifdef __WATCOMC__
     27#pragma data_seg("STACK32", "CODE")
     28#endif
     29char szMsg[19] = {"I'm really small!\n"};
     30
     31#ifdef __WATCOMC__
     32#pragma data_seg("MYSTACK", "STACK")
     33int dummy;
    2334#endif
    2435
     36
     37#ifdef __IBMC__
     38#pragma entry(minihll)
     39#endif
    2540
    2641
     
    2843 * Main entry potin etc.
    2944 */
    30 void entry(void)
     45void _Optlink minihll(void)
    3146{
    32     DosPutMessage(0, 18, "I'm really small!\r");
     47    #ifndef LIBC
     48    DosPutMessage(0, 18, szMsg);
     49    #else
     50    printf(szMsg);
     51    #endif
    3352}
     53
     54
  • branches/mini/src/win32k/test/minihll.def

    r6532 r6533  
    1 ; $Id: minihll.def,v 1.1.2.1 2001-08-14 22:56:04 bird Exp $
     1; $Id: minihll.def,v 1.1.2.2 2001-08-15 01:50:13 bird Exp $
    22NAME ''
    33
     
    88    'CODE32'      CLASS 'CODE'    SHARED EXECUTEREAD
    99    'CONST32_RO'  CLASS 'CODE'    SHARED EXECUTEREAD
     10    'CODEDATA32'  CLASS 'CODE'    SHARED EXECUTEREAD
    1011
     12IMPORTS
     13    printf = LIBCN.1082
    1114
  • branches/mini/src/win32k/test/minihll.mak

    r6532 r6533  
    1 # $Id: minihll.mak,v 1.1.2.1 2001-08-14 22:56:05 bird Exp $
     1# $Id: minihll.mak,v 1.1.2.2 2001-08-15 01:50:14 bird Exp $
    22
    33#
     
    2424# Tools and Flags Addjustments.
    2525#
     26!ifndef WAT
    2627LD2FLAGS = $(LD2FLAGS) /BASE:0x10000 /Stack:0x1000
     28!endif
     29!ifdef WAT
     30CFLAGS += /Os -s /NTSTACK32
     31!endif
    2732
    2833
     
    5156#
    5257$(OBJDIR)\$(TARGET).exe: $(OBJS)  $(DEFFILE) $(OBJDIR)\$(TARGET).lrf
     58!ifndef WAT
    5359    -8 $(LD2) /FORCE $(LD2FLAGS) /BASE:0x10000 /PACKCODE /PACKDATA /NOEXEPACK \
    5460        /ALIGNMENT:1 @$(OBJDIR)\$(TARGET).lrf
     61!else
     62    wlink system os2v2 file {$(OBJS)} name $(OBJDIR)\.exe \
     63    import printf LIBCN.1082 \
     64    import DosPutMessage MSG.5   \
     65#        segment{'STACK32' READWRITE} \
     66#        segment{'MYSTACK' CLASS 'STACK' READWRITE} \
     67        option offset=0x10000 option alignment=1 option stack=4060 option start=minihll \
     68        option map=$(OBJDIR)\$(TARGET).map
     69    mv $(OBJDIR)\.exe $@
     70!endif
    5571    $(LXLITE) /AN:1 /ZS:1024 /ZX:1024 /MF3 /YXD /YND $@
    5672
     
    5975
    6076
     77
    6178#
    6279# Exe: Linker file - creates the parameter file passed on to the linker.
    6380#
     81!ifndef WAT
    6482$(OBJDIR)\$(TARGET).lrf: makefile
    6583    @echo Creating file <<$@
     
    7391<<keep
    7492
     93!else
     94$(OBJDIR)\$(TARGET).lrf: makefile
     95    echo $@
     96!endif
    7597
    7698
    7799
     100
Note: See TracChangeset for help on using the changeset viewer.