www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Help needed to actualizing allegro bindings (or this bindings are complex and I am dumb)

reply g <L MF.ao.com> writes:
I have been trying to actualize the http://www.dsource.org/projects/dallegro
binings to the lastest D2 version.
The main problems are:
*TLS
*volatile isn't here anymore ( neither with -d ) 

One of the most hard things to understand was things like:

mixin(_volatile("int", "key_shifts"));
and  _volatile_setter things.

Especially when you have things like:

char* allegro_id;

and  then:

import allegro.internal.dintern;
static this() {
   allegro_id = allegro.internal.dintern.allegro_id.ptr;
   allegro_error = allegro.internal.dintern.allegro_error.ptr;
   cpu_vendor = allegro.internal.dintern.cpu_vendor.ptr;
   //_system_driver_list = allegro.misc._system_driver_list.ptr;
}
A strange way of wraping.

Sooooooooo...
Are there other bindings to allegro?
Does anyone has actualized this bindings?
Is Someone interested in helping?
Should i abdicate? 

g
Nov 14 2009
next sibling parent reply g <L MF.ao.com> writes:
g Wrote:

 I have been trying to actualize the http://www.dsource.org/projects/dallegro
binings to the lastest 
typo: it is bindings, not binings
Nov 14 2009
parent reply div0 <div0 users.sourceforge.net> writes:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

g wrote:
 g Wrote:
 
 I have been trying to actualize the http://www.dsource.org/projects/dallegro
binings to the lastest 
typo: it is bindings, not binings
Downgrade your compiler version. Every version after 2.028 has bugs which prevent non trivial programmes compiling or have language changes which break just about ever existing library. - -- My enormous talent is exceeded only by my outrageous laziness. http://www.ssTk.co.uk -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iD8DBQFLABCdT9LetA9XoXwRAnpDAJ9gaBI5dKWGUzUPLgbIXCYzwy1gcQCeMFnr Wxyc0hHCOS1b+fC0KOWOqmo= =h7KQ -----END PGP SIGNATURE-----
Nov 15 2009
parent g <nospam spam.ironic> writes:
div0 Wrote:

 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
 g wrote:
 g Wrote:
 
 I have been trying to actualize the http://www.dsource.org/projects/dallegro
binings to the lastest 
typo: it is bindings, not binings
Downgrade your compiler version. Every version after 2.028 has bugs which prevent non trivial programmes compiling or have language changes which break just about ever existing library. - -- My enormous talent is exceeded only by my outrageous laziness. http://www.ssTk.co.uk -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iD8DBQFLABCdT9LetA9XoXwRAnpDAJ9gaBI5dKWGUzUPLgbIXCYzwy1gcQCeMFnr Wxyc0hHCOS1b+fC0KOWOqmo= =h7KQ -----END PGP SIGNATURE-----
actually i have engine code that only compiles with new features.
Nov 15 2009
prev sibling parent torhu <no spam.invalid> writes:
On 15.11.2009 08:53, g wrote:
 I have been trying to actualize the http://www.dsource.org/projects/dallegro
binings to the lastest D2 version.
 The main problems are:
 *TLS
 *volatile isn't here anymore ( neither with -d )
You can remove volatile by just building with -version=NoVolatile. But I suppose it won't work unless you add __gshared to all the non-const globals. Or something, I'm not using D 2 myself.
 One of the most hard things to understand was things like:

 mixin(_volatile("int", "key_shifts"));
 and  _volatile_setter things.
It's to make it easy to build both with and without volatile. Most of this stuff is explained in the readme or somewhere in the code itself.
 Especially when you have things like:

 char* allegro_id;

 and  then:

 import allegro.internal.dintern;
 static this() {
     allegro_id = allegro.internal.dintern.allegro_id.ptr;
     allegro_error = allegro.internal.dintern.allegro_error.ptr;
     cpu_vendor = allegro.internal.dintern.cpu_vendor.ptr;
     //_system_driver_list = allegro.misc._system_driver_list.ptr;
 }
 A strange way of wraping.

 Sooooooooo...
 Are there other bindings to allegro?
 Does anyone has actualized this bindings?
 Is Someone interested in helping?
 Should i abdicate?

 g
I know there's someone working on allegro 5 bindings, but I don't think they're done yet. No announcement has been made. But if you want to update dallegro, I'll try to answer questions at least.
Nov 15 2009