#1 2017-04-18 02:23:04

te
Member
Registered: 2017-04-18
Posts: 6

error using fpcupdeluxe under linux subsystem for windows

After I saw that the lazarus (1.0.4) that an apt-get install lazarus installs under the linux subsystem for windows seems to run pretty well (once you install an xserver in windows, e.g. Xming and execute an "export DISPLAY=:0" on the linux prompt), I wanted to try out the latest newpascal fpc/lazarus.

I downloaded the latest fpcupdeluxe: fpcupddeluxe-x86_64-linux and it initially seems to run fine.

But after a while the log ends in:

Type 'svn help' for usage.
Executing : /usr/bin/svn "update" "--quiet" "--non-interactive" "--trust-server-cert" "-r" "HEAD" "/mnt/p/fpcup/fpcsrc" (working dir: )
svn: E235000: In file '/build/subversion-0NcZK7/subversion-1.8.8/subversion/libsvn_wc/update_editor.c' line 1550: assertion failed (action == svn_wc_conflict_action_delete)
Executing : /usr/bin/svn "checkout" "--quiet" "--non-interactive" "--trust-server-cert" "-r" "HEAD" "https://github.com/newpascal/freepascal/branches/release/" "/mnt/p/fpcup/fpcsrc" (working dir: )
svn: E155004: Run 'svn cleanup' to remove locks (type 'svn help cleanup' for details)
svn: E155004: Working copy '/mnt/p/fpcup/fpcsrc' locked.
svn: E155004: '/mnt/p/fpcup/fpcsrc' is already locked.
Executing : /usr/bin/svn "cleanup" "--non-interactive" "/mnt/p/fpcup/fpcsrc" (working dir: )
Executing : /usr/bin/svn "cleanup" "--non-interactive" "--remove-unversioned" "--remove-ignored" "/mnt/p/fpcup/fpcsrc" (working dir: )
svn: invalid option: --remove-unversioned
Type 'svn help' for usage.
Executing : /usr/bin/svn "update" "--quiet" "--non-interactive" "--trust-server-cert" "-r" "HEAD" "/mnt/p/fpcup/fpcsrc" (working dir: )
svn: E235000: In file '/build/subversion-0NcZK7/subversion-1.8.8/subversion/libsvn_wc/update_editor.c' line 1550: assertion failed (action == svn_wc_conflict_action_delete)
Executing : /usr/bin/svn "info" "/mnt/p/fpcup/fpcsrc" (working dir: )
Path: /mnt/p/fpcup/fpcsrc
Working Copy Root Path: /mnt/p/fpcup/fpcsrc
URL: https://github.com/newpascal/freepascal/branches/release
Relative URL: ^/branches/release
Repository Root: https://github.com/newpascal/freepascal
Repository UUID: b06cf4e9-28d3-451c-dbe9-ce57b7db7bff
Revision: 29651
Node Kind: directory
Schedule: normal

fpcupdeluxe: info: DownloadFromSVN: SVN gave error code: 134

fpcupdeluxe: info: DownloadFromSVN: SVN gave error message: Path: /mnt/p/fpcup/fpcsrc
Working Copy Root Path: /mnt/p/fpcup/fpcsrc
URL: https://github.com/newpascal/freepascal/branches/release
Relative URL: ^/branches/release
Repository Root: https://github.com/newpascal/freepascal
Repository UUID: b06cf4e9-28d3-451c-dbe9-ce57b7db7bff
Revision: 29651
Node Kind: directory
Schedule: normal


fpcupdeluxe: info: FPC was at: failure
fpcupdeluxe: info: FPC is now at: branch revision up/fpc (repository revision 29651)
fpcupdeluxe: info: Error running fpcup. Technical details: error executing sequence fpc; line: 4, param: FPC
fpcupdeluxe: info: Error running fpcup. Technical details: error executing sequence Only; line: 1, param: fpc

Has anyone an idea what's going wrong here and how to fix it?

Offline

#2 2017-04-18 04:52:01

te
Member
Registered: 2017-04-18
Posts: 6

Re: error using fpcupdeluxe under linux subsystem for windows

I updated my subversion to 1.9 (following https://tecadmin.net/install-subversion-1-9-on-ubuntu/ ) and now get a slightly different error message, but at the same location:

fpcupdeluxe: info: Running SVN checkout or update.
Executing : /usr/bin/svn "info" "/mnt/p/fpcup/fpcsrc" (working dir: )
Path: /mnt/p/fpcup/fpcsrc
Working Copy Root Path: /mnt/p/fpcup/fpcsrc
URL: https://github.com/newpascal/freepascal/branches/release
Relative URL: ^/branches/release
Repository Root: https://github.com/newpascal/freepascal
Repository UUID: b06cf4e9-28d3-451c-dbe9-ce57b7db7bff
Revision: 29651
Node Kind: directory
Schedule: normal

Executing : /usr/bin/svn "cleanup" "--non-interactive" "/mnt/p/fpcup/fpcsrc" (working dir: )
Executing : /usr/bin/svn "cleanup" "--non-interactive" "--remove-unversioned" "--remove-ignored" "/mnt/p/fpcup/fpcsrc" (working dir: )
Executing : /usr/bin/svn "update" "--quiet" "--non-interactive" "--trust-server-cert" "-r" "HEAD" "/mnt/p/fpcup/fpcsrc" (working dir: )
svn: E175009: The XML response contains invalid XML
svn: E130003: Malformed XML: no element found
Executing : /usr/bin/svn "info" "/mnt/p/fpcup/fpcsrc" (working dir: )
Path: /mnt/p/fpcup/fpcsrc
Working Copy Root Path: /mnt/p/fpcup/fpcsrc
URL: https://github.com/newpascal/freepascal/branches/release
Relative URL: ^/branches/release
Repository Root: https://github.com/newpascal/freepascal
Repository UUID: b06cf4e9-28d3-451c-dbe9-ce57b7db7bff
Revision: 29652
Node Kind: directory
Schedule: normal

fpcupdeluxe: info: DownloadFromSVN: SVN gave error code: 256

fpcupdeluxe: info: DownloadFromSVN: SVN gave error message: Path: /mnt/p/fpcup/fpcsrc
Working Copy Root Path: /mnt/p/fpcup/fpcsrc
URL: https://github.com/newpascal/freepascal/branches/release
Relative URL: ^/branches/release
Repository Root: https://github.com/newpascal/freepascal
Repository UUID: b06cf4e9-28d3-451c-dbe9-ce57b7db7bff
Revision: 29652
Node Kind: directory
Schedule: normal


fpcupdeluxe: info: FPC was at: branch revision up/fpc (repository revision 29651)
fpcupdeluxe: info: No updates for FPC found.
fpcupdeluxe: info: Error running fpcup. Technical details: error executing sequence fpc; line: 4, param: FPC
fpcupdeluxe: info: Error running fpcup. Technical details: error executing sequence Only; line: 1, param: fpc


ERROR: Fpcupdeluxe failed.

Offline

#3 2017-04-18 06:28:23

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 9,268
Website

Re: error using fpcupdeluxe under linux subsystem for windows

Are you talking about the Windows 10 Ubutuntu sub-system?
This is not supported, and pretty weird to use in such case, since there is no GUI available.
Did you try to use GIT as alternative to SVN?

To compile for Linux from Windows, just install the Linux cross-compilers.
But nothing beats installing lazarus on a Linux VM, for proper debugging.

Offline

#4 2017-04-18 20:55:44

te
Member
Registered: 2017-04-18
Posts: 6

Re: error using fpcupdeluxe under linux subsystem for windows

Yes, indeed, I'm talking about the the ubuntu based linux subsystem in windows 10. And as I explained above, running GUI applications works ok as long as you install a X Server under windows (I'm using http://www.straightrunning.com/XmingNotes/ ) and execute a "export DISPLAY=:0" on the bash prompt before starting them.

After installing the the lazarus version available from the ubuntu repository (only 1.0.4 unfortunately), I found it to run ok (with the lazarus windows showing up as individual windows on my windows desktop instead of being confined to the windows of a VM). I could compile, run, and debug (breakpoints, single stepping, inspecting variables) some test projects.

The GUI of fpcupdeluxe also shows just fine (otherwise I could hardly be asking about problems while running it...)

Given the advantage of being able to compile, run, and debug linux applications directly on the windows desktop, I don't think wanting to use the linux subsystem for windows instead of a VM is that "weird".

And yes, I understand that it's not officially "supported", but that doesn't mean I can't ask if someone has an idea why fpcupdeluxe isn't working, right?

Offline

#5 2017-04-18 21:27:07

te
Member
Registered: 2017-04-18
Posts: 6

Re: error using fpcupdeluxe under linux subsystem for windows

Ok, trying to use git fails a bit later when it tries to download the 3.0.0 bootstrap compiler using SVN.

BUT, good news, it seems I found the problem.

SVN doesn't work well when trying to run on /mnt/<windows drive letter>/ directories, as the DriveFS for these behaves similar to an NTFS partition mounted under normal linux.

When running from a directory in the root fs SVN works correctly, and it has right now progressed through compiling the bootstrap compiler to now compiling the latest fpc version. So I'm hopeful that it will now run through to the end...

Offline

#6 2017-04-18 23:30:38

te
Member
Registered: 2017-04-18
Posts: 6

Re: error using fpcupdeluxe under linux subsystem for windows

A freshly build linux newpascal lazarus running under the linux subsystem directly on the windows desktop without the need for a vm, having compiled, run, and is now debugging (stopped at a breakpoint) a simple Hello World GUI application:
1492557600776.jpg?dl=0

Last edited by te (2017-04-18 23:31:10)

Offline

#7 2017-04-19 11:38:32

te
Member
Registered: 2017-04-18
Posts: 6

Re: error using fpcupdeluxe under linux subsystem for windows

in case anyone is interested, here are the steps from start to finish that give me a (seemingly) working and up-to-date Linux lazarus running on windows 10 v1703 without a VM:

Install XMing from http://www.straightrunning.com/XmingNotes/
I'm using the Snapshot Xming-x64 7.7.0.18 version (requires 10 GBP "donation"), but the public Xming 6.9.0.31 version should be enough.
Make sure it's running after installing.

Windows "as administrator" prompt:

(only required if linux subsystem was installed before upgrading to windows version 1703, make sure you got no files you can't lose in the linux file system first)

>lxrun /uninstall /full

>lxrun /install

windows normal (not elevated) prompt:

>bash

linux prompt:

>sudo bash
(we got a root prompt now, no need to sudo every individual command)
>apt update
>apt dist-upgrade
>apt install unzip
>apt install subversion
>apt install build-essential
>apt install lazarus
(we aren't going to use THIS lazarus later, but installing it ensures all pre-reqs are installed)
>exit
(we are back to the normal user shell now)
>export DISPLAY=:0
>startlazarus
(this should start lazarus and verify that the x server is working, close it down again, we aren't going to use this version)
>cd ~
>mkdir fpcupdeluxe
>cd fpcupdeluxe
>mkdir installer
>cd installer
>wget https://github.com/newpascal/fpcupdeluxe/releases/download/v1.2.0m/fpcupdeluxe-x86_64-linux
>chmod +x fpcupdeluxe-x86_64-linux
>./fpcupdeluxe-x86_64-linux
(this should have started a new gui application)

in fpcupdeluxe:

select "newpascal" as fpc and lazarus version
click install/update fpc+Laz button
it should end with a SUCCESS message
close the window

back at the linux prompt:

>cd ~
>./Lazarus_fpcupdeluxe
(newly compiled linux newpascal lazarus should be running on the windows desktop now)

Last edited by te (2017-04-19 16:30:01)

Offline

#8 2017-04-19 12:23:26

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 9,268
Website

Re: error using fpcupdeluxe under linux subsystem for windows

Nice!
roll

Thanks for sharing!

Offline

#9 2017-04-19 13:54:43

AOG
Member
Registered: 2014-02-24
Posts: 346

Re: error using fpcupdeluxe under linux subsystem for windows

Very nice indeed !
And I must say (confess) that the Lazarus-trick (installing / de-installing Lazarus) is also used by me  ... ;-)

Offline

Board footer

Powered by FluxBB