Re: [AD] Patch to allow Allegro 4.3.10plus to build on Haiku

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


>> It looks like a problem with our (crappy) depend scripts.  Can you rerun
>> `make depend' and send me a copy of `obj/beos/alleg/makefile.dep'
>> (privately)?  Adding the new empty directory would only be a workaround,
>> and we'd also have to make obj/beos/{alld,allp}/beos as well.
>
> That wasn't it.
>
> On Linux, when I do `fix.sh haiku; make -n'
> I get the expected command line:
>
>    gcc -DALLEGRO_LIB_BUILD -Wall -Wno-unused -Wno-multichar
>    -Wno-ctor-dtor-privacy -mtune=i586 -O6 -funroll-loops -ffast-math
>    -fomit-frame-pointer -DALLEGRO_NO_ASM -I. -I./include -o
>    obj/beos/alleg/bfixicon.o -c tools/beos/bfixicon.cpp
>
>
> To reproduce the line that you got, I have to fiddle around with the two
> rules in makefile.be beginning with:
>
>    */%: $(OBJ_DIR)/%.o $(LIB_NAME)
> and
>    tools/beos/%: $(OBJ_DIR)/%.o $(LIB_NAME)
>
>
> Otherwise, this might work:
>
> diff --git a/makefile.be b/makefile.be
> index b9e5711..e5b032c 100644
> --- a/makefile.be
> +++ b/makefile.be
> @@ -316,7 +316,7 @@ define LINK_WITH_PLUGINS
>  $(CC) $(LFLAGS) -o $@ $< $(strip $(PLUGIN_LIB) $(addprefix @,$(PLUGIN_SCRIPTS)) $(LIB_NAME))
>  endef
>
> -tools/beos/%: $(OBJ_DIR)/%.o $(LIB_NAME)
> +tools/beos/bfixicon: $(OBJ_DIR)/bfixicon.o $(LIB_NAME)
>        $(CC) $(LFLAGS) -o $@ $< $(LIB_NAME) $(LIBRARIES)
>
>
> Peter
>

When checking the svn version of libSDL I ran into a problem with it
building the bjoystick module, so I posted a ticket on haiku for it:
http://dev.haiku-os.org/ticket/2904
Turns out this was something that Kaliber (Grzegorz) had patched in
our recent Allegro patch.  Haiku fixed the issue, which means we need
to undo that part of the patch that we applied to Allegro.  You'll
find that patch attached.  I also just tested out your one line patch
above and it worked, so I guess that can be added.  I am however
getting an error at the end of make:
make: *** No rule to make target `docs/src/build/haiku._tx', needed by
`docs/htmk/build/haiku.html'.  Stop.

As for the TRACE issue, I filed a ticket with Haiku for that one also,
we'll see if anything comes of it:
http://dev.haiku-os.org/ticket/2909

-scottmc
diff -urN allegro/src/beos/bjoyapi.cpp allegro-haiku/src/beos/bjoyapi.cpp
--- allegro/src/beos/bjoyapi.cpp	2008-10-20 23:05:58.000000000 +0000
+++ allegro-haiku/src/beos/bjoyapi.cpp	2008-10-23 18:12:22.000000000 +0000
@@ -64,12 +64,12 @@
    device_config = get_config_string("joystick", "joystick_device", "");
    
    /* Let's try to open selected device */
-   if ((device_config[0] == '\0') || (be_joy->Open(device_config, true) < 0)) {
+   if ((device_config[0] == '\0') || (be_joy->Open(device_config) < 0)) {
       /* ok, let's try to open first available device */
       if (be_joy->GetDeviceName(0, device_name) != B_OK) {
          goto cleanup;
       }
-      if (be_joy->Open(device_name, true) == B_ERROR) {
+      if (be_joy->Open(device_name) == B_ERROR) {
          goto cleanup;
       }
    }


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/