param: It's GObject.ParamSpec, not GLib.ParamSpec

https://bugzilla.gnome.org/show_bug.cgi?id=665432
param: Rip out JSResolve op

This was preventing proper property access, and it's not doing
anything.

https://bugzilla.gnome.org/show_bug.cgi?id=665432
param: Implement property lookup for ParamSpecs

https://bugzilla.gnome.org/show_bug.cgi?id=665432
Add a common way to grab a GType for an object

This is only hooked up for objects, enums and flags right now, but it's
absolutely possible that more will be hooked up in the future.

https://bugzilla.gnome.org/show_bug.cgi?id=665432
Indent enum test properly
param: Allow creating new ParamSpecs
Add a new "GObject" override module to aid us in creating ParamSpecs

https://bugzilla.gnome.org/show_bug.cgi?id=665432
test: Add new tests to test ParamSpecs
arg: Wrap GParamSpec values when sending them to JS

We need to do this, otherwise a property handler can't get its own pspec.

https://bugzilla.gnome.org/show_bug.cgi?id=665432
Release 1.31.6
function: Correctly convert from ffi return values to GIArgument on big-endian

ffi always returns a long value even if a function's return type is
e.g. guint8.  We can't just directly give ffi_call a GIArgument to
store its return value because when the size of the return type is
smaller than long, it will write into the wrong address.

Instead cast the value at the C level.

Based on a patch from Ray Strode <rstrode@redhat.com>

https://bugzilla.gnome.org/show_bug.cgi?id=665152
Add native JSClass for interfaces

This allows us to retrieve static methods and methods from the prototype.
This also lays the foundation for when we want to implement implementing
interfaces.

https://bugzilla.gnome.org/show_bug.cgi?id=666360
interface: Fix build

I had a future patch changing gjs_define_function to include
a GType argument. Unfortunately, I forgot to remove it when
rebasing for master.
Fix build with automake 1.11.2

libdir_DATA is not allowed anymore with automake 1.11.2
installing gir and typelib to the standard location instead

Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

https://bugzilla.gnome.org/show_bug.cgi?id=667250
drop JS_LOCALETOUNICODE_NEEDS_CONST_CHAR check and silence warnings

Since we now require mozjs185, it always needs a const char*
Silence btw warnings about argv sometimes not being used

https://bugzilla.gnome.org/show_bug.cgi?id=666331

Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
function: Fix ffi return value handling on 32 bit

We had two major problems in marshaling.  One is that our conversion
routine took an unsigned ffi_arg value, which we put signed values
into. Also, our fallback case was copying from ffi_arg (which is
always 64 bit on architectures we support) into the pointer member of
the GIArgument union, but on 32 bit architecture pointers are just 32
bit.

Fix both of these by creating a new union, and then passing in a
pointer to the correct member of it for the given return value type
we're supplying to ffi.  We then need to again convert from this union
type into a GIArgument.

Debugged with lots of help from Ray Strode <rstrode@redhat.com>

https://bugzilla.gnome.org/show_bug.cgi?id=665152
Add support for flat GValue arrays

https://bugzilla.gnome.org/show_bug.cgi?id=657767
object: Don't crash when given a GObject singleton

Some GObject libraries, like IBus, implement singletons by adding a custom
construct vfunc, from which they return an existing GObject. This means that
g_object_newv may not always return a new object. In these cases, returning the
existing wrapper JS object should be enough to help clients out.
object.c: Fix leak of parameters when handling a singleton

When we find an existing JSObject, don't forget to free the
parameters we passed to g_object_newv().
object.c: correct memory management for singletons

Make sure we don't try to remove a toggle reference that we
don't add, and unreference the extra reference created by
g_object_new().