Jump to page: 1 2
Thread overview
GDC & Pandaboard/QEMU & Framebuffer
Oct 06, 2014
John A
Oct 06, 2014
Joakim
Oct 11, 2014
John A
Oct 11, 2014
Mike Parker
Oct 12, 2014
John A
Oct 12, 2014
Mike Parker
Oct 12, 2014
Mike Parker
Oct 12, 2014
John A
Oct 22, 2014
John A
Oct 22, 2014
Johannes Pfau
Oct 23, 2014
John A
Oct 23, 2014
John A
Oct 24, 2014
John A
Oct 11, 2014
Iain Buclaw
Oct 12, 2014
John A
October 06, 2014
Not sure where to post this; it's not a question, just some info.

I have created a set of pages here:

  http://arrizza.org/wiki/index.php/Dlang

with instructions which include:
  - how to create a GDC cross-compiler using crosstool-ng
  - how to create some sample applications to test out GDC
  - how to create a sample app that writes to the framebuffer via GDC
  - how to set up and run these apps on QEMU
  - how to run the same apps on a Pandaboard

There is nothing new here. Others have written it already, some of which worked as advertised for me, some didn't. I've just gathered it up, tried it out and wrote down very specific instructions about what I needed to do to get it to work. Hopefully it works well for you.

Note I use Ubuntu 12.04 for everything, so these pages won't help Windows folks.

John
October 06, 2014
On Monday, 6 October 2014 at 04:39:03 UTC, John A wrote:
> Not sure where to post this; it's not a question, just some info.
>
> I have created a set of pages here:
>
>   http://arrizza.org/wiki/index.php/Dlang
>
> with instructions which include:
>   - how to create a GDC cross-compiler using crosstool-ng
>   - how to create some sample applications to test out GDC
>   - how to create a sample app that writes to the framebuffer via GDC
>   - how to set up and run these apps on QEMU
>   - how to run the same apps on a Pandaboard
>
> There is nothing new here. Others have written it already, some of which worked as advertised for me, some didn't. I've just gathered it up, tried it out and wrote down very specific instructions about what I needed to do to get it to work. Hopefully it works well for you.
>
> Note I use Ubuntu 12.04 for everything, so these pages won't help Windows folks.
>
> John

Nice, I have ldc working at pretty much the same level on linux/arm, tested on a Cubieboard2.  Have you tried running any of the druntime/phobos unit tests?  All but two modules of druntime, as of the dmd 2.066 release, pass for me, while only three modules pass from phobos.  I'll put up instructions for cross-compiling with ldc once I have more of it working, as cross-compiling with ldc is easier.
October 11, 2014
> Nice, I have ldc working at pretty much the same level on linux/arm, tested on a Cubieboard2.  Have you tried running any of the druntime/phobos unit tests?
No, it's on my todo list.

One thing I'll do first is see if I can modify Derelict3 to be Phobos free. If so the opengl3 library will probably be more useful to me. There might even be a mid-point where only a portion of Phobos needs porting.

> All but two modules of druntime, as of the dmd 2.066 release, pass for me, while only three modules pass from phobos.  I'll put up instructions for cross-compiling with ldc once I have more of it working, as cross-compiling with ldc is easier.

Cool. All useful work in the end...


October 11, 2014
On 6 Oct 2014 11:15, "Joakim via Digitalmars-d" <digitalmars-d@puremagic.com> wrote:
>
> On Monday, 6 October 2014 at 04:39:03 UTC, John A wrote:
>>
>> Not sure where to post this; it's not a question, just some info.
>>
>> I have created a set of pages here:
>>
>>   http://arrizza.org/wiki/index.php/Dlang
>>
>> with instructions which include:
>>   - how to create a GDC cross-compiler using crosstool-ng
>>   - how to create some sample applications to test out GDC
>>   - how to create a sample app that writes to the framebuffer via GDC
>>   - how to set up and run these apps on QEMU
>>   - how to run the same apps on a Pandaboard
>>
>> There is nothing new here. Others have written it already, some of which
worked as advertised for me, some didn't. I've just gathered it up, tried it out and wrote down very specific instructions about what I needed to do to get it to work. Hopefully it works well for you.
>>
>> Note I use Ubuntu 12.04 for everything, so these pages won't help
Windows folks.
>>
>> John
>
>
> Nice, I have ldc working at pretty much the same level on linux/arm,
tested on a Cubieboard2.  Have you tried running any of the druntime/phobos unit tests?  All but two modules of druntime, as of the dmd 2.066 release, pass for me, while only three modules pass from phobos.  I'll put up instructions for cross-compiling with ldc once I have more of it working, as cross-compiling with ldc is easier.

At the last time I tested, all unittests and testsuite had been passing on ARM.  There were a number of forward ported tests. And a few disabled (ie: evaluation order of array operations differ between x86 and every other architecture).

Iain.


October 11, 2014
On 10/11/2014 2:27 PM, John A wrote:

> One thing I'll do first is see if I can modify Derelict3 to be Phobos
> free. If so the opengl3 library will probably be more useful to me.
> There might even be a mid-point where only a portion of Phobos needs
> porting.

I would recommended using the packages from DerelictOrg [1] rather than Derelict 3, as the latter is no longer maintained.


[1] https://github.com/DerelictOrg

---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

October 12, 2014
> I would recommended using the packages from DerelictOrg [1] rather than Derelict 3, as the latter is no longer maintained.

I did get Derelict3 to compile. I had to use a Makefile instead of dub but all the files compiled cleanly with no warnings. I did not add any unit tests as of yet, so I don't know if anything runs.

I took your recommendation and cloned from DerelictOrg. It failed to compile in a couple of files: arb.d and ext.d. All the failures were due to the same error, e.g.:

source/derelict/opengl3/arb.d:933: error: user defined attributes cannot appear as postfixes

The original line in Derelict3 is:
  private __gshared bool _ARB_depth_buffer_float;
  bool ARB_depth_buffer_float() @property { return _ARB_depth_buffer_float; }

The line in DerelictOrg is:
  private __gshared bool _ARB_depth_buffer_float;
  bool ARB_depth_buffer_float() @nogc nothrow @property { return _ARB_depth_buffer_float; }
October 12, 2014
> At the last time I tested, all unittests and testsuite had been passing on ARM.

Very nice. I'd like to replicate what you did. I haven't looked at Phobos at all yet, I'm working on getting opengl up and going first.

Any chance you can post instructions on exactly how you did that? Or point me to a url with those instructions? That would be fantastic!

Example of some things I think are relevant:
- I'm assuming gdc or did you use ldc instead? Which version of gdc+gcc?
- Was Phobos cross-compiled or did you compile on the devkit itself?
- If cross-compiled, for which ARM architecture (cortex a8, a9, M3, other)?
- What was the Host environment and it's configuration (linux vs Win)? If Linux, which version and did you have to install additional packages?
- Which repository and revision of Phobos did you use?
- Did you make any changes to the Phobos source to get it to compile?
- What were the exact command lines you used to compile Phobos? Can you supply a Makefile?
- What environment and configuration did you use to run the tests (Bare-metal, linux, qemu, etc.)? If not qemu, which devkit/board did you use (beagleboard, pandaboard, Raspberry PI, etc.)?
- What was the OS and configuration of the devkit?
- Did you have to update or install any additional libraries (.a or .so) onto the board?

Thanks in advance!
John
October 12, 2014
On 10/12/2014 8:08 PM, John A wrote:

>
> I took your recommendation and cloned from DerelictOrg. It failed to
> compile in a couple of files: arb.d and ext.d. All the failures were due
> to the same error, e.g.:
>
> source/derelict/opengl3/arb.d:933: error: user defined attributes cannot
> appear as postfixes
>
> The original line in Derelict3 is:
>    private __gshared bool _ARB_depth_buffer_float;
>    bool ARB_depth_buffer_float() @property { return
> _ARB_depth_buffer_float; }
>
> The line in DerelictOrg is:
>    private __gshared bool _ARB_depth_buffer_float;
>    bool ARB_depth_buffer_float() @nogc nothrow @property { return
> _ARB_depth_buffer_float; }

That means you're using an older version of the D frontend and I didn't take that into account when I added @nogc to the extension modules. A bugfix release is imminent.

For the curious, to get backward-compatible nogc support into Derelict, I've implemented it as a UDA for versions less than 2.066 of the D frontend (see derelict.util.system). Until recently, it compiled fine on pre-2.066, but when I applied it to the property functions in the extension modules, I had no idea that UDAs could not be postfixes and that it would break on pre-2.066.

I'm curious about the rationale behind allowing built-in attributes as postfixes but not UDAs. I'll see if it's in the docs, but if not, I'd like to know what it is. On the surface, it seems unintuitive to distinguish between the two.

---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

October 12, 2014
On 10/12/2014 9:45 PM, Mike Parker wrote:
> On 10/12/2014 8:08 PM, John A wrote:
>
>>
>> I took your recommendation and cloned from DerelictOrg. It failed to
>> compile in a couple of files: arb.d and ext.d. All the failures were due
>> to the same error, e.g.:
>>
>> source/derelict/opengl3/arb.d:933: error: user defined attributes cannot
>> appear as postfixes
>>
>> The original line in Derelict3 is:
>>    private __gshared bool _ARB_depth_buffer_float;
>>    bool ARB_depth_buffer_float() @property { return
>> _ARB_depth_buffer_float; }
>>
>> The line in DerelictOrg is:
>>    private __gshared bool _ARB_depth_buffer_float;
>>    bool ARB_depth_buffer_float() @nogc nothrow @property { return
>> _ARB_depth_buffer_float; }
>

Fixed in master. Tag 1.0.10 for those using DUB.


---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

October 12, 2014
> Fixed in master. Tag 1.0.10 for those using DUB.

Just did a git pull and recompile. It built clean. Mike thanks for the very quick response!

Next step for me, is to create a small opengl test app:
- does it cross-compile (on Ubunutu)?
- does it run in QEMU?
- does it run on a Pandaboard?

After that, I'll try the derelict gflw and see how that goes...


John
« First   ‹ Prev
1 2