Page 2 of 2

Re: Missing PDF component?

Posted: Fri Apr 07, 2017 3:56 pm
by FourthWorld
dunbarx wrote:It turns out that the "revpdfprinter.dll" was of course included in the standalone build, but that another file, of about 4K, named "_revpdfprinter.dll" was as well. No idea where this could have come from, but it was placed in the folder which the other files, and did not work. I did not create this thing, and I have it.
Did you build on a Mac, zip the app bundle, and then unzip it?

MacOS is notorious for adding "_*" files in Zip archives it creates, which I believe are there in an effort to preserve Mac-specific metadata when moving across platforms with different file systems.

Re: Missing PDF component?

Posted: Fri Apr 07, 2017 4:40 pm
by dunbarx
Richard.
Did you build on a Mac, zip the app bundle, and then unzip it?
I did not.

So I made a new standalone. On the Mac I develop, the "Windows" folder shows the .exe file, the working stack, the "revPDFPrinter.dll" file. And an "Extensions" folder with a "revFont.dll" file.

When I bring that folder to a Windows 7 machine, the "Windows" folder has all those and three more:

A "_revPDFPrinter.dll" file
A "_revFont.dll" file in the "extensions folder
A "_myWorkingStack" file

It was the "_revPDFPrinter.dll" file that I inadvertently placed in the Documents folder, not paying attention to the redundancy, or the clue that the underscore might cause problems.

Simple one-shot creation of a standalone. No side trips. So why do I deserve these extras? I am not that nice a guy. I am still in v6.7.9, of course.

Craig

Re: Missing PDF component?

Posted: Fri Apr 07, 2017 5:12 pm
by FourthWorld
Are you copying from your Mac to your Windows machine via SMB?

If so, what we see most often is the creation of files beginning with "._". E.g. "MyStack.livecode" would be accompanied by "._MyStack.livecode".

Background on that, with links to some tools to remedy this (everyone seems mystified as to why Apple provides no Preferences setting for this) here:
https://superuser.com/questions/212896/ ... core-files

For "_" files (no leading "."), I've only seen those in Zip archives. Sounds related to the Mac's insistence on creating these metadata files, but since it doesn't have the "." and isn't in a Zip archive I'm not exactly sure what's happening in your case.

Re: Missing PDF component?

Posted: Fri Apr 07, 2017 7:30 pm
by dunbarx
Nothing so fancy. I take the files made on my Mac. Put them on a thumb drive, and copied to the Windows machine.

Re: Missing PDF component?

Posted: Fri Apr 07, 2017 7:36 pm
by FourthWorld
Unless the thumb drive is formatted for HFS+ it's probably using NTFS or Fat32; with either of those macOS will detect it's a non-Mac file system and create the dreaded "._*" files.

But the weird part is that yours don't have the ".", so I'm still not entirely sure what's happening in your case.

Re: Missing PDF component?

Posted: Fri Apr 07, 2017 10:43 pm
by [-hh]
Hi all.

May be this is from the OS transition from 10.4.11 to 10.5 (and later)?
Are the zips generated in 10.4.x?
For a while some helper software removed leading dots from "._" names to make
invisible files visible in the zip.

Hermann

p.s.
For me works the following, when I'm sure to NOT need dot-underscore-files (sometimes they contain metadata for Mac apps that use deprecated OS features).
Also I never remove ".Spotlight" files. Else loading media from a slow thumb drive may become painful on Mac.

(One may do the same for a folder on a hardDrive immediately before zipping the folder. Always give the full folder path.)

Code: Select all

-- removes recursively apple's dot-underscore-files from an USBThumb
-- and optionally (by rightClick) leading-underscore-files -- be careful with that
on mouseUp b
  put "yourUSBthumbName" into v2
  put v2 & ":" into rprt
  put cr&shell("find /Volumes/"&v2&" -name '._*' -print0 | xargs -t0 rm") after rprt
  put cr&shell("find /Volumes/"&v2&" -name '.DS_Store' -print0 | xargs -t0 rm") after rprt
  if (b=3) then # <----------------------------- switch
    put cr&shell("find /Volumes/"&v2&" -name '_*' -print0 | xargs -t0 rm") after rprt
  end if
  put rprt
end mouseUp

Re: Missing PDF component?

Posted: Sat Apr 08, 2017 3:34 pm
by jacque
I thought those underscore files were the old OS 9 resource forks. They're useless on Windows but should be ignored by the OS, they're just an unused file in the same folder. It's odd they'd cause a problem.

Re: Missing PDF component?

Posted: Sat Apr 08, 2017 3:58 pm
by FourthWorld
I haven't read the boot script in revCommon in a long time, but as I recall it's very, shall we say, "thorough". ;) It may be that it's attempting to load anything in that folder ending in ".dll".

Re: Missing PDF component?

Posted: Sat Apr 08, 2017 4:36 pm
by jacque
FourthWorld wrote:I haven't read the boot script in revCommon in a long time, but as I recall it's very, shall we say, "thorough". ;) It may be that it's attempting to load anything in that folder ending in ".dll".
Got it. That makes sense.

Re: Missing PDF component?

Posted: Sat Apr 08, 2017 4:55 pm
by [-hh]
It's not always clever to remove or ignore the dot-underscore-files:

Perhaps it is best to use the OS-built-in utility "dot_clean"
(see "man dot_clean" in terminal)
that does the best with it (merges all ._* files with their corresponding native files following given rules).

That's also what some "google-top-utilities" internally use -- but you don't know what they really do ...

Re: Missing PDF component?

Posted: Sat Apr 08, 2017 4:58 pm
by Klaus
Hey, cool, didn't know that this exists, thanks a lot!