News:

2026.08.23 The "Files" area is now visible to guests/spiders

Main Menu

Missing libraries when linking a program.

Started by dmac1267, Today at 12:23:07 AM

Previous topic - Next topic

dmac1267

I am using LisaEm under Windows 11. I have made a series of test codes to learn pascal, but I seemed to have hit a wall.

Program LisaTest4;
 (*This is an example of a remark*)

 var
  i:integer;

 begin
  begin
   For i = 1 to 5 do
   WriteLn ('Hello from Apple Lisa. Line:' :i);
  end;
 end.

I know this program probably has some errors regarding the formatting. I corrected it in LPW and it compiled successfully. When it comes to linking it to create the executable program everything goes to pot. It appears that I am missing most or all libraries. I have tried linking it with normal inputs, I have also tried to use the option function to specifically declare sys1lib, iospaslib, and qd/support, to no avail. I am new to LOS and LPW so I am trying my best to work out my own problems. I have gotten some invaluable help from TorZidan with the LisaEm, but now I am stuck.

Any suggestions?

bmwcyclist

The linker needs IOSPASLIB.OBJ, SYS1LIB.OBJ and SYS2LIB.OBJ as inputs (the intrinsic units come through INTRINSIC.LIB automatically). If it says they're missing, check they're actually on the Workshop volume you booted in LisaEm — some Workshop images don't include them, and then no amount of naming them helps. Our exec files list them right after the program's own .OBJ files, then a blank line, then the output name.

I ran into this issue also.
Using my LISA for writing blogs and other work projects, and for fun and games at home.
Visit my shares on GlobalTalk! LISAGamingZone
Check out the NEW Lisa Software! https://github.com/GyroPilot
telnet theapplelisabbs.duckdns.org 1983


AlexTheCat123

Quote from: bmwcyclist on <strong>Today</strong> at 09:42:48 AMThe linker needs IOSPASLIB.OBJ, SYS1LIB.OBJ and SYS2LIB.OBJ as inputs (the intrinsic units come through INTRINSIC.LIB automatically). If it says they're missing, check they're actually on the Workshop volume you booted in LisaEm — some Workshop images don't include them, and then no amount of naming them helps. Our exec files list them right after the program's own .OBJ files, then a blank line, then the output name.

Every Workshop image should include IOSPASLIB, SYS1LIB, and SYS2LIB. If your install doesn't have them, then something's wrong with your installation. The Workshop can't even boot at all if IOSPASLIB and SYS1LIB aren't present.

Also, you don't need to link with all three when writing a program as simple as this. For your demo program here, you should only need IOSPASLIB. SYS1LIB will start becoming necessary when you start doing anything much more complicated, but SYS2LIB will really only be needed if you're developing LOS apps as opposed to Workshop stuff. If you're doing anything with floating-point types, you'll need IOSFPLIB.

To give a library to the Linker, you don't use any options; you just specify the name of the libary as if it's another input object file.

Make sure that, if your volume has both LOS and the Workshop installed, you installed LOS first and the Workshop second, not the other way round. The Workshop's libraries are the unpacked versions that the Linker requires, whereas LOS installs the packed versions, which the Linker will reject with a rather cryptic error.