English Amiga Board


Go Back   English Amiga Board > Support > support.WinUAE

 
 
Thread Tools
Old 28 February 2013, 13:26   #21
mark_k
Registered User
 
Join Date: Aug 2004
Location:
Posts: 3,343
Quote:
Originally Posted by prowler View Post
Toni, would you have an .ADF image you could upload featuring at least one AmigaDOS soft link and preferably at least one hard link too?

I'm sorry to post this request here. I have been reading The .ADF (Amiga Disk File) FAQ, but the way links are implemented in AmigaDOS is still an area of mystery to me and it would be useful to see one or two examples.
The Amiga Guru Book (2nd Ed) has some info on links starting at page 369. Also see the AmigaDOS Manual (3rd Ed) starting at page 346.

You should be able to easily make an ADF with hard and soft links yourself, using the CLI MakeLink command.
mark_k is offline  
Old 28 February 2013, 14:35   #22
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,517
Quote:
Originally Posted by mark_k View Post
Also, it may be a good idea to not make the .lnk suffix visible on the Amiga side. If on the Amiga side you rename the soft link/shortcut so it doesn't end in .lnk, WinUAE renames the .lnk file on the Windows side, which turns it into a regular file that Windows no longer recognises as a shortcut.
Hiding it or not hiding won't prevent it getting messed up when renaming.. It still needs extra code...

Quote:
Originally Posted by mark_k View Post
You should be able to easily make an ADF with hard and soft links yourself, using the CLI MakeLink command.
At least 3.1 MakeLink only wants to make hardlinks for some reason. Thats why ACTION_MAKE_LINK is not yet supported, also I haven't decided if it should create Windows-side softlinks or shortcuts..
Toni Wilen is online now  
Old 28 February 2013, 14:53   #23
mark_k
Registered User
 
Join Date: Aug 2004
Location:
Posts: 3,343
There are some tools on Aminet which can make soft links.
util/boot/fixslinks-0.5 (also includes a program which is supposed to make soft links work better???), util/dir/2b_FileLink15, util/misc/beckermakelink, util/sys/LN, util/sys/MakeLink.TV, util/sys/mlinkrep, util/sys/MSys-1.2

Do Windows side soft links only work on NTFS volumes? Shortcuts presumably work on both NTFS and FAT, but using soft links if possible would be a less ugly solution. There might be problems if the user e.g. moves their shared directory from an NTFS to a FAT volume though.
mark_k is offline  
Old 28 February 2013, 16:23   #24
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,517
I think I'll keep it "read-only" for now, this was just an interesting experiment

I am not even sure (haven't bothered to test) if ACTION_RENAME is supposed to rename the link or target.. Only ACTION_DELETE is documented as deleting the link, most other dos packets that take path as a parameter seem to always return ERROR_SOFT_LINK = target path is resolved by dos (open, lock, setcomment, filedate,..)
Toni Wilen is online now  
Old 28 February 2013, 21:18   #25
prowler
Global Moderator
 
prowler's Avatar
 
Join Date: Aug 2008
Location: Sidcup, England
Posts: 10,300
Quote:
Originally Posted by mark_k View Post
The Amiga Guru Book (2nd Ed) has some info on links starting at page 369. Also see the AmigaDOS Manual (3rd Ed) starting at page 346.

You should be able to easily make an ADF with hard and soft links yourself, using the CLI MakeLink command.
Quote:
Originally Posted by mark_k View Post
There are some tools on Aminet which can make soft links.
util/boot/fixslinks-0.5 (also includes a program which is supposed to make soft links work better???), util/dir/2b_FileLink15, util/misc/beckermakelink, util/sys/LN, util/sys/MakeLink.TV, util/sys/mlinkrep, util/sys/MSys-1.2
Thanks for the info and links, Mark. I'll check those sources.

Quote:
Originally Posted by Toni Wilen View Post
At least 3.1 MakeLink only wants to make hardlinks for some reason. Thats why ACTION_MAKE_LINK is not yet supported, also I haven't decided if it should create Windows-side softlinks or shortcuts..
From The .ADF (Amiga Disk File) FAQ (Paragraph 4.6):

"With the FFS, links were introduced. Alas, Commodore blundered again: soft links were terribly broken, so they removed support for them in AmigaDOS 3.0. Hard links are seen as files, and hard links to directories are allowed, which opens the way to endless recursion...
In short, the whole implmentation is a mess."
prowler is offline  
Old 01 March 2013, 10:41   #26
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,517
Quote:
Originally Posted by prowler View Post
removed support for them in AmigaDOS 3.0
This can't be true. DevCD V38_V39_OS_CHANGE and V40_RELEASE_NOTES mention FFS softlink fixes. RAM handler softlink support was removed in 3.0 (to save ROM space says the changelog)

Unless "removed support" means C:MakeLink does only create hardlinks
Toni Wilen is online now  
Old 01 March 2013, 12:43   #27
mark_k
Registered User
 
Join Date: Aug 2004
Location:
Posts: 3,343
Quote:
Originally Posted by prowler View Post
From The .ADF (Amiga Disk File) FAQ (Paragraph 4.6):

"With the FFS, links were introduced...
I'd be inclined to view the ADF FAQ as not necessarily entirely accurate. For one thing, FFS was first introduced with Workbench 1.3 and didn't support links then. Links were first implemented in AmigaDOS 2.0. And links work on OFS volumes too, it's just that the filesystem used to access the volume needs to support links otherwise problems may occur. (To see that, make some soft and hard links on a Workbench 1.3 disk, then boot the disk under Kickstart 1.2/1.3. If you try CDing to a soft link, you get a software failure requester.)
mark_k is offline  
Old 01 March 2013, 21:23   #28
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,517
ACTION_MAKE_LINK implemented if attempting to create softlinks. Creates .lnk shortcut files (Creating real softlinks seem to require higher privileges).

Tested using MakeLink from fixslink-0.5 package.

Note that this isn't full implementation, according to documentation it is allowed to create softlinks that don't point to existing filesystem entry. My implementation requires valid target because invalid shortcuts would be confusing outside of emulation and I am not sure if Windows even allows them.
Toni Wilen is online now  
Old 01 March 2013, 21:28   #29
prowler
Global Moderator
 
prowler's Avatar
 
Join Date: Aug 2008
Location: Sidcup, England
Posts: 10,300
Quote:
Originally Posted by Toni Wilen View Post
This can't be true. DevCD V38_V39_OS_CHANGE and V40_RELEASE_NOTES mention FFS softlink fixes. RAM handler softlink support was removed in 3.0 (to save ROM space says the changelog)

Unless "removed support" means C:MakeLink does only create hardlinks
Quote:
Originally Posted by mark_k View Post
I'd be inclined to view the ADF FAQ as not necessarily entirely accurate. For one thing, FFS was first introduced with Workbench 1.3 and didn't support links then. Links were first implemented in AmigaDOS 2.0. And links work on OFS volumes too, it's just that the filesystem used to access the volume needs to support links otherwise problems may occur. (To see that, make some soft and hard links on a Workbench 1.3 disk, then boot the disk under Kickstart 1.2/1.3. If you try CDing to a soft link, you get a software failure requester.)
Thanks, Toni and Mark, for your guidance on this. I guess I should be able to get my head round this now.
prowler is offline  
Old 30 June 2013, 13:13   #30
tbone
 
Posts: n/a
Hi all!.. o)

I hope you don't mind me jumping in, but I have a question regarding "makelink" and windows-folders (ntfs) mounted on the amiga side.

I have a set of scripts that make use of "c:makelink" to create some kind of multiboot configuration - for example:

makelink envarc:sys/screenmode.prefs envarc:prefs/presets/winuae/envarc/sys/screenmode.prefs

That way, the linked prefs-file is transparent to screenmode prefs and "save/use" functionality works as normal, without always remembering to put special "winuae" prefs-files in that presets folder (which content will be relinked to envarc: etc. whenever the config/hardware changes).

When using ntfs-folders mounted to the amiga, that "makelink" command does create some kind of link, but you can imagine, I cannot make screenmode-prefs or iprefs automatically load "screenmode.prefs*.lnk*".. o)

Is there a way around that appended "*.lnk" extension somehow ?!

thanks for reading!.. o)

Last edited by tbone; 30 June 2013 at 13:14. Reason: gfx-smiley interfering
 
Old 30 June 2013, 15:11   #31
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,517
Windows Shell links always have .lnk (even if Explorer does not show them), not sure if this works but try http://www.winuae.net/files/b/winuae.zip

It removes .lnk extension from Amiga side. It can cause other side-effects, please report if you find any
Toni Wilen is online now  
Old 30 June 2013, 20:05   #32
tbone
 
Posts: n/a
Hi Toni.. thx for helping!.. o)

I did test that beta version, but it makes no difference to the visibility of *.lnk" files to version 2.6 i used before.

With the beta version, a *.lnk file created with windows directly, is still visible with its extension (btw: plz watch the file size, a screenmode.prefs is 62 bytes normally).
> list envarc:sys/screenmode#?
screenmode.prefs.lnk 1831 ----rwed Today 19:56:44

Addionally, when trying to create a softlink on the amiga side, the first time I try I get the attached little popup window, telling me about an "Unimplemented Error 0" (in both WinUAE versions).

This is how I called the various makelink(s):
>makelink from sys:testlink.prefs to sys:prefs/Presets/uaegfx/screenmode.prefs (hard|soft)

It always results in an error: "makelink: function not implemented".

Another strange thing is, that no "makelink" tool did works at all in my latest attempts. I was able to create those *.lnk files from the amiga side, but suddenly i cannot create them anymore. Is there a special makelink replacement I shall try again? I think I used the original C= version, but that as well, does not cut it right now.

Thx your for reading.. o)
Rob.
Attached Thumbnails
Click image for larger version

Name:	Clipboard Image.png
Views:	126
Size:	1.4 KB
ID:	35833  

Last edited by tbone; 30 June 2013 at 21:15. Reason: clarification, gfx icon interfering
 
Old 30 June 2013, 20:13   #33
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,517
Hmm.. Works for me.

Note that AOS C:MakeLink does not want to create soft links for some reason. (Hardlinks are not supported = "function not implemented", but you can use native ntfs hardlinks if you want) Use some other MakeLink version that supports SOFT parameter.

Which Windows version? (Shortcut/softlink may use APIs that are Vista or later only) Does *.lnk shortcuts work correctly if you use Windows Explorer to browse them?
Toni Wilen is online now  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Screen dragging zevs support.FS-UAE 2 25 November 2012 19:33
D3D windowed / full window switch -> black emulation screen Maccara support.WinUAE 4 15 May 2010 15:17
Solid Window dragging WB Retro1234 request.Apps 11 24 January 2010 11:09
Screen dragging MickJT request.UAE Wishlist 2 02 January 2008 18:25
Transparent icon dragging oldpx support.Apps 2 05 September 2002 06:17

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 12:43.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.16442 seconds with 14 queries