Thursday, 2 January 2014

SYSTEMS PROGRAMMING AND HARDWARE LAB

HOW TO RUN MASM ON UBUNTU/WINDOWS

Firstly, Download MASM (click on the link, goto "File" and choose "download") and extract it from zip.

1. Create a folder named 'splab' in the home folder

2. move (cut-paste) the extracted "MASM" folder inside splab folder in home.

Using DOSBOX for MASM (FOR UBUNTU):
1. Open terminal, type dosbox. (If not found, install it by typing "sudo apt-get install dosbox".
2. Run the command dosbox from terminal
3. At Z prompt type
        'mount c  /home/yourLoginName/splab'
4. Type C:  ,you will get C prompt
5. Change directory to MASM to assemble masm programs (cd MASM)

How to Assemble MASM program:
1. masm program.asm         (create .obj file)
2. link program.obj               (create .exe file)
3. program                           (execute your program)

Test if MASM is working fine:

( c2e1.asm is an example program included in the folder )
1. open terminal, type dosbox
2. in dosbox type, mount c /home/yourLoginName/splab
3. type, C:
4. type, cd MASM
5. type, masm c2e1.asm
6. type, link c2e1.obj
7. type, c2e1 to run it






Thursday, 28 November 2013

LANGUAGE PROCESSING: COMPILER PROGRAMMING

HOW TO INSTALL LEX AND YACC IN LINUX:
Type following in Terminal.
LEX
sudo apt-get install flex-old

YACC
sudo apt-get install bison

HOW TO INSTALL LEX AND YACC IN WINDOWS:
Check Here [External Link]

Study Materials :
LEX AND YACC TUTORIAL
YYPARSE INTERNALLY

Basic Programs: Language C, LEX, YACC


YACC

For more Programs, refer following blogs from our senior: