Skip to content

Commit

Permalink
mention lack of i 7.1 support, revise formatting and layout
Browse files Browse the repository at this point in the history
  • Loading branch information
NattyNarwhal committed Feb 10, 2018
1 parent c002a8b commit d08a816
Showing 1 changed file with 61 additions and 41 deletions.
102 changes: 61 additions & 41 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Mono on i Project February 7, 2018
*Mono on i Project February 9, 2018*

2/7/18 Binary Preview Package Notes and Instructions
# 2/7/18 Binary Preview Package Notes and Instructions

The Mono on i Project began porting Mono to PASE on IBM i on January 19, 2018.
There are still numerous bugs to fix, and the port is hardly production-ready
Expand All @@ -19,10 +19,10 @@ appreciate feedback.

## Required system

Either AIX 6.1 TL9 or i 7.1. The JIT compiler will automatically adjust
Either AIX 6.1 TL9 or i 7.2. The JIT compiler will automatically adjust
parameters to optimize for the current CPU. We have primarily done PASE
testing on 7.2, but we see no reason why it would not run on 7.1. The
team is interested in hearing any reports regarding compatibility.
testing on 7.2, and work is being done to make it run on 7.1. The team
is interested in hearing any reports regarding compatibility.

It is extremely critical to ensure that the system QCCSID value is
properly set. Check your QCCSID value with "DSPSYSVAL QCCSID". If it is
Expand All @@ -32,11 +32,11 @@ installing Mono.
It is strongly recommended that the following IBM LPPs and PTFs are
installed:

LPP 5733-SC1 OpenSSH/OpenSSL
* LPP 5733-SC1 OpenSSH/OpenSSL

LPP 5733-OPS Open Source Solutions Option 7 (Tools)
* LPP 5733-OPS Open Source Solutions Option 7 (Tools)

Open Source Solutions PTF Group SF99123 (7.1), SF99223 (7.2),
* Open Source Solutions PTF Group SF99123 (7.1), SF99223 (7.2),
or SF99725 (7.3) Level 5 (or later)

## Included contents
Expand All @@ -57,26 +57,48 @@ or SF99725 (7.3) Level 5 (or later)

## Known issues

### Missing features

* Roslyn won't run and will immediately throw a SIGTRAP. Due to the
complexity debugging and porting Roslyn, this will have to wait.

* Debugging a dynamically linked Mono may cause issues with GDB. A
statically linked Mono may be shipped later.
* Shared performance counters have been disabled due to lack of POSIX
shared memory functions on PASE.

* The interpeter is enabled, but will not run due to lack of support for
POWER for interpeter-generated trampolines.

* System.Drawing will not work yet, due to missing libgdiplus.

* FastCGI and mod_mono servers are shipped, but untested. XSP can be
used as a development server in the meantime. Be aware that many ASP.net
controls refer to System.Drawing, which means that all but the smallest
ASP.net pages will likely run into the aforementioned problems with
System.Drawing.

### Compatibility

* i 7.1 is not supported at the moment, but the team is actively
working in this.

* NuGet (not included) may not run on PASE, when it does on AIX. This
will be investigated.

### Native interop and system support

* Debug messages such as below will be printed during normal operation.
This is expected, often due to semantic differences between other Unices
and AIX/PASE. The team is working to resolve these issues.

```
mono_thread_internal_set_priority: pthread_setschedparam failed, error:
"Operation not permitted." (1)

* System.Drawing will not work yet. This will affect ASP.NET
applications.
```

* Due to differences in how AIX/PASE handle shared libraries, many
applications may crash attempting to load native libraries. As such, you
may have to alter the application's DLL mappings, either for the
assembly in its .config file, or the global /opt/mono/etc/config file.
assembly in its `.config` file, or the global `/opt/mono/etc/config` file.
Consult <http://www.mono-project.com/docs/advanced/pinvoke/dllmap/> for
how DLL mappings work on Mono. Issues with the global DLL mapping are
due to packaging toolchain defiencies and will be fixed in a later
Expand All @@ -86,24 +108,6 @@ release.
support for AIX/PASE. Users are encouraged to report these incidents to
the team.

* The Ahead of Time compiler and bundling have not been tested, and
likely do not function due to binary format differences in AIX/PASE.

* Shared performance counters have been disabled due to lack of POSIX
shared memory functions on PASE.

* The interpeter is enabled, but will not run due to lack of support for
POWER for interpeter-generated trampolines.

* FastCGI and mod_mono servers are shipped, but untested. XSP can be
used as a development server in the meantime. Be aware that many ASP.net
controls refer to System.Drawing, which means that all but the smallest
ASP.net pages will likely run into the aforementioned problems with
System.Drawing.

* NuGet (not included) may not run on PASE, when it does on AIX. This
will be investigated.

* Calling between ILE and PASE code is currently not possible. The team
expects to eventually solve this problem, but has not crossed that
bridge as of this time.
Expand All @@ -113,28 +117,40 @@ provider included within iACS calls into a Win32 DLL, which
unfortunately means that we cannot use it on the IBM i. The team is
looking into alternative solutions currently.

### Runtime and JIT

* Exceptions in class constructors that would throw
`TypeInitializationException` can crash the runtime. This is being
investigated.

* Debugging a dynamically linked Mono may cause issues with GDB. A
statically linked Mono may be shipped later.

* The Ahead of Time compiler and bundling have not been tested, and
likely do not function due to binary format differences in AIX/PASE.

## Installation instructions

* The latest release is available from
<https://github.com/MonoOni/binarydist/releases>

* Create an empty save file with which to receive the save file that you
downloaded to your PC. To do so, open up a 5250 "green screen" session
and run the command "CRTSAVF SAVF(QGPL/MONO0207)" on your system.
and run the command `CRTSAVF SAVF(QGPL/MONO0207)` on your system.

* Transfer the save file using a command line FTP client in binary mode
to QGPL/MONO0207.

* Restore the Mono on i binaries by running "RST
DEV('/QSYS.LIB/QGPL.LIB/MONO0207.FILE') OBJ('/QOpenSys/opt/mono')" on
your system.
* Restore the Mono on i binaries by running
`RST DEV('/QSYS.LIB/QGPL.LIB/MONO0207.FILE') OBJ('/QOpenSys/opt/mono')`
on your system.

* After unpacking the save file, it is important to make sure that a
symbolic link to /QOpenSys/opt is present at /opt. If you have used the
YiPS package scripts to install AIX RPMs on PASE, this symbolic link has
already been created for you. To check if it exists, run the command
"WRKLNK '/opt'". If you get "Object not found.", create it by running
"ADDLNK OBJ('/QOpenSys/opt') NEWLNK('/opt')" on your system.
`WRKLNK '/opt'`. If you get "Object not found.", create it by running
`ADDLNK OBJ('/QOpenSys/opt') NEWLNK('/opt')` on your system.

## Compile and run your first Mono program

Expand All @@ -146,13 +162,15 @@ session into a PASE shell, or, less optimally, CALL QP2TERM. Once you
are in the PASE shell, run the following commands to make the Mono
commands available to your shell:

$ PATH=/opt/mono/bin:$PATH

$ export PATH
```
$ export PATH=/opt/mono/bin:$PATH
```

* Now, invoke the Mono C# compiler to compile hello.cs:

```
$ mcs /opt/mono/samples/hello.cs
```

* A file named hello.exe will be created in your current directory. This
is a Mono/.NET "managed code assembly" containing the compiled bytecode,
Expand All @@ -161,9 +179,11 @@ file to your PC and then run it on Windows. Try it!

* Now, to run the program:

```
$ mono hello.exe
Hello from Mono for the IBM i!
```

* Similarly, you can compile a .NET program on Visual Studio for
Windows, copy it to your IBM i system, and run it using the "mono"
Expand Down

0 comments on commit d08a816

Please sign in to comment.