Error message under Wine when installing Pac Converters

All except GUI problems

Error message under Wine when installing Pac Converters

Postby HansKlaver » Thu Jun 14, 2018 8:04 pm

Recently I tried to install subsystem Pac (from the CPC website) in a new installation of BlackBox (version 1.7.1.1014 running under Wine in macOS) and ran into an error message of BlackBox when activating command PacConverters.Install: "command error: corrupted code file for PacAPI". I have used BlackBox under Wine for several years now and this never gives any problems, so I was a bit surprised.

Because I thought it might have something to do with differences between CPC and Center versions I did a fresh install of version 1.7.1805 (Core) from the CPC website, and the same problem occurred. I reported it to Helmut Zinn, and he could not reproduce the problem when running BlackBox under Windows.

So I did some further tests. Deleting the Sym & Code files and recompiling subsystem Pac doesn't help. It appears to be a Wine-specific thing!

I could reproduce the problem using at least two Wine versions under macOS 10.13.4 (Wine 1.8-rc4 from Mike Kronenberg (https://mike.kronenberg.org/) and Wine 3.0.1 from http://www.winehq.org). Using a dual boot setup I could confirm that the problem does not occur when using BlackBox under Windows 10.

I installed my BlackBox working directory on an exFAT partition shared between macOS and Windows. I did the installation of the Pac converters from within the Windows installation of BlackBox to the shared working directory, and now I am also able to open PACked files from within BlackBox running under Wine in macOS!

Actually I needed subsystem Pac to be able to use Benchmark from the CPC, which is dependent on the Dos subsystem and Dos depends on Pac...

What is causing the problem under Wine is unclear to me, but at least now I have a work-around. Maybe there is no real file corruption of the PacAPI code file involved, but it is erroneously reported by Wine and hence by BlackBox?

Could someone who uses BlackBox under Wine in Linux see if the problem is reproducible there also?

--
Hans Klaver
HansKlaver
 
Posts: 14
Joined: Sun Oct 13, 2013 10:46 pm
Location: Aerdenhout, The Netherlands

Re: Error message under Wine when installing Pac Converters

Postby Josef Templ » Fri Jun 15, 2018 6:07 am

I have tested it under Debian running in a VirtualBox and didn't find any problems.

Can you look at the size of the broken and unbroken code files?
Any difference?

Can you look at the contents of the broken and unbroken code files?
Use Info->Repository and click on the code file.
Compare the code listing of the broken and the unbroken version with F9 (Info->Compare Texts).

Which file system are you using when there is an error.

- Josef
Josef Templ
 
Posts: 206
Joined: Tue Sep 17, 2013 6:50 am

Re: Error message under Wine when installing Pac Converters

Postby HansKlaver » Fri Jun 15, 2018 10:37 am

Josef Templ wrote:I have tested it under Debian running in a VirtualBox and didn't find any problems.

Can you look at the size of the broken and unbroken code files?
Any difference?

Stupid I didn't look into that, because there's a difference indeed: the broken file has 0 bytes... (the unbroken 24.688 bytes).

Josef Templ wrote:Can you look at the contents of the broken and unbroken code files?
Use Info->Repository and click on the code file.
Compare the code listing of the broken and the unbroken version with F9 (Info->Compare Texts).

The Repository shows "wrong file tag: 00000000"

Josef Templ wrote:Which file system are you using when there is an error.

My BlackBox working directory is on a partition that uses ExFAT file system, which I chose because it is easiest to share between macOS, Windows and Linux; this is where BlackBox writes new files, both working in macOS and in Windows 10. I didn't install Wine on Linux (yet).
On the macOS (10.13.4, 'High Sierra') side BlackBox is on an APFS volume, on the Windows 10 side on an HPFS volume.

So I presume Wine (and hence BlackBlox) sometimes has trouble writing to the ExFAT filesystem, and Windows hasn't...

--
Hans Klaver
HansKlaver
 
Posts: 14
Joined: Sun Oct 13, 2013 10:46 pm
Location: Aerdenhout, The Netherlands

Re: Error message under Wine when installing Pac Converters

Postby Zinn » Sat Jun 16, 2018 5:41 am

The steps of my test:
- download BlackBox 1.7.1805
- unpack it to an empty directory
- download pac.txt by clicking on StdCoded File, select all, copy and paste it to an empty document in BlackBox
- unpack it via Tools -> Decode
- Open the Quick-Start and following the installation steps
- After restart of BlackBox I unpack Ctls.pac

First I tested it on Windows 1803 and it works.
I repeated my test on Ubuntu 18.04 with Wine 3.0 The result is the same.

I have no problem to use subsystem Pac on Windows and on Wine.

My guess it is a permission, access or disk full problem.
Your file is not available for reading or you have no write access during compilation and you can't create the directory or the file.
- Helmut
Zinn
 
Posts: 58
Joined: Mon Nov 24, 2014 10:47 am

Re: Error message under Wine when installing Pac Converters

Postby Josef Templ » Sat Jun 16, 2018 11:43 am

HansKlaver wrote:So I presume Wine (and hence BlackBlox) sometimes has trouble writing to the ExFAT filesystem, and Windows hasn't...

--
Hans Klaver


Is the file system on a local disc or is it mounted using something like NFS or any other
network file system?

I am asking this because I know that NFS for example is not completely transparent, i.e. there are some
file operations that fail to work via NFS but work well on a local file system.

- Josef
Josef Templ
 
Posts: 206
Joined: Tue Sep 17, 2013 6:50 am

Re: Error message under Wine when installing Pac Converters

Postby HansKlaver » Sat Jun 16, 2018 5:43 pm

Josef Templ wrote:
HansKlaver wrote:So I presume Wine (and hence BlackBlox) sometimes has trouble writing to the ExFAT filesystem, and Windows hasn't...

Is the file system on a local disc or is it mounted using something like NFS or any other
network file system?

I am asking this because I know that NFS for example is not completely transparent, i.e. there are some
file operations that fail to work via NFS but work well on a local file system.

All three filesystems are on one local "disc" (SSD), each in its own partition.

I did two new tests, now more as you did (completely fresh installs; last time I only emptied the Pac/Code and Pac/Sym directories); the only difference is that I used a newly downloaded build 1014 setup file from blackboxframework.org:
- one on the ExFAT partition (now the whole BlackBox installation on that partition, no separate working directory)
- another on the APFS partition (macOS-specific). Also a whole new installation without working directory, with subsystem Pac as a first extra.

On the ExFAT partition the file (Pac)API.ocf remains empty (0 bytes) after compilation; during compilation there is no message or warning from BlackBox that something went wrong... (see screenprints), but otherwise the BlackBox installation on the ExFAT partition functions flawlessly (as far as I can tell).
On the APFS partition the file was written normally and subsystem Pac functions as expected.

So it definitely has something to do with the ExFAT file system and Wine on macOS. Also when used from Windows 10 on this same ExFAT partition there is no problem, as said. But why only a problem with this particular file??

Anyway, it's not a big problem, and there are workarounds. But it is quite interesting, isn't it?

Now I'll try and install Wine and BlackBox on my Linux Mint partition and do some tests from there to the same shared ExFAT partition and to my Linux partition. Stay tuned.

--
Hans Klaver

After Install step 4.png
After Installation step 4

(Pac)API.ocf empty.png
(Pac)API.ocf stays empty after compilation on filesystem ExFAT under Wine on macOS.
HansKlaver
 
Posts: 14
Joined: Sun Oct 13, 2013 10:46 pm
Location: Aerdenhout, The Netherlands

Re: Error message under Wine when installing Pac Converters

Postby Josef Templ » Sun Jun 17, 2018 7:41 am

Compile the PacAPI module again as the only module.
Does it change anything?

If the problem persists, rename it in the source code to something very similar (PacApi), then compile.
If the problem persists, rename it in the source code again (PacApi2), compile.
etc.
At some point the problem must disappear, I guess.
It would be good to know at which point and if this is reproducible.

- Josef
Josef Templ
 
Posts: 206
Joined: Tue Sep 17, 2013 6:50 am

Re: Error message under Wine when installing Pac Converters

Postby HansKlaver » Tue Jun 19, 2018 6:34 pm

Changed the name of PacAPI and recompiled the module as you indicated several times, using names like PacApi, Pac...:
Api2, Api3, Api4, Api10, Api11, BPI, ZPI, Apl, AAPI, AAAAAAAPI, Hello
In each and every instance the resulting code files were size 0 bytes.

Interestingly, when I tried to compile the same module twice I got a File Error dialog window saying something like:
...\Pac\Code\API.ocf could not be replaced because it is in use

Maybe this error message is a clue to what's going on...

--
Hans

PacAPI -> PacHello.png
After renaming and recompiling PacAPI several times the code files remain 0 bytes.

FileError_In_Use.png
Trying to compile PacHello twice.
After clicking Cancel ("Annuleren") the compilation proceeds normally.
HansKlaver
 
Posts: 14
Joined: Sun Oct 13, 2013 10:46 pm
Location: Aerdenhout, The Netherlands

Re: Error message under Wine when installing Pac Converters

Postby Josef Templ » Wed Jun 20, 2018 5:23 am

OK, the error persists for PacAPI but other modules do compile.
It may be related to the contents of the code file.
Do you have a virus tool installed that clears the contents because it thinks that the file contains a virus?

- Josef
Josef Templ
 
Posts: 206
Joined: Tue Sep 17, 2013 6:50 am

Re: Error message under Wine when installing Pac Converters

Postby Zinn » Wed Jun 20, 2018 5:58 am

There is somewhere a race condition. The file of the first compilation is not closed. May be an error condition is not checked or the messages dialog is not displayed and the system still waits for the answer. Add a dummy PRCOCEDURE to the PacAPI (change the contents of PacAPI) and see if the error still exist.
And add some text behind END PacAPI.

- Helmut
Zinn
 
Posts: 58
Joined: Mon Nov 24, 2014 10:47 am

Next

Return to BlackBox Framework

Who is online

Users browsing this forum: No registered users and 0 guests

cron