wok-current view linld/stuff/src/HEADER.ASM @ rev 23810

syslinux/iso2exe: use isoboot
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon May 25 10:10:30 2020 +0000 (2020-05-25)
parents
children 555bcdab610b
line source
1 ;***************************************************************
2 ;****** This file is distributed under GPL
3 ;***************************************************************
4 ideal
5 %PAGESIZE 1000
6 %crefref
7 %noincl
8 %nomacs
9 p8086
11 group DGROUP _TEXT
12 assume cs:DGROUP,ds:DGROUP
14 segment _TEXT byte public use16 'CODE'
16 org 100h
17 global _text_start:byte
18 label _text_start byte
20 mov di,80h
21 cmp [byte di],1
22 ja notfound
23 ifdef WITH_LONG_FILENAME
24 mov si,offset tazboot_cmd
25 mov ax,716Ch
26 xor bx,bx ; R/O
27 xor cx,cx ; attributes
28 cwd ; action = open
29 stc
30 int 21h
31 jnc found
32 mov dx,si
33 else
34 mov dx,offset tazboot_cmd
35 endif
36 mov ax,3d00h ; read-only+compatibility
37 ;mov cl,0 ; attribute mask
38 int 21h
39 jc notfound
40 found:
41 xchg ax,bx
42 mov ah,3Eh
43 int 21h
44 mov cx,endcmd-begcmd+1
45 mov si,offset default_arg
46 rep
47 movsb
48 notfound:
49 mov di,9000h
50 mov si,offset tomove
51 mov ch,1
52 jmp move
53 tomove:
54 cld
55 mov di,100h
56 mov si,offset endcmd
57 mov ch,40h
58 move:
59 push di
60 rep
61 movsw
62 ret
64 default_arg db endcmd-begcmd
65 begcmd db " @"
66 tazboot_cmd db "tazboot.cmd",0
67 endcmd:
69 ;***************************************************************
71 ends _TEXT
74 end _text_start
76 ;###### END OF FILE ############################################