Linux compiling under SuSE 9.3

Collapse
X
 
  • Time
  • Show
Clear All
new posts

  • TJA
    replied
    Oh.

    That did it

    Configuration:

    Install path: /usr/local
    lib/ path: /usr/local/share/angband/

    Even the "make install" worked!

    Strange thing

    Edit: Needed to add chmod g+s on angband to be able to read savefiles ...

    The development environment is in a bad condition, IMHO.
    Last edited by TJA; August 16, 2007, 07:57.

    Leave a comment:


  • pav
    replied
    Hehe, yeah a lot of people expect --prefix to ./configure will do that.

    But not here! I don't grok how takkaria managed to rip out such a basic functionality of autoconf/automake (grin) but you will have to pass magic argument --with-setgid=games to have it install under --prefix...

    Leave a comment:


  • TJA
    replied
    And "Esc" does not seem to work ...

    Edit: Found the "Backtick" workaround (`´`) - still strange.

    Leave a comment:


  • TJA
    replied
    Sadly, i discover more problems with compiling VA:


    ./configure --prefix=/usr/local --disable-x11


    gives

    Configuration:

    Install path: /usr/local
    lib/ path: ./lib/

    -- Frontends --
    - Curses Yes
    - GTK 2.x Disabled
    - X11 Disabled
    - SDL Disabled


    A "make install" does nothing but copy "angband" one level up:

    make install
    INSTALL angband (-> ..)


    No installation in /usr/local - and if i do that manually, this copy does not run:

    angband
    angband: Cannot access the './lib/file/news.txt' file!

    The 'lib' directory is probably missing or broken.
    Perhaps the archive was not extracted correctly.
    See the 'readme.txt' file for more information.

    So, there are more things that need to be copied to /usr/local ...
    But even then, this will not work as "angband" searches them in the current directory!!!

    Very strange.

    :-O

    Leave a comment:


  • Daven_26d1
    replied
    The 3.0.9 borg is unfinished as of yet, but I think you can get a test version. The maintainer of the bot has a thread in the V forums here.

    Leave a comment:


  • TJA
    replied
    Don“t want to bug you with more questions - just one:

    Is it possible to compile and use a bot / borg for VA 3.0.9?
    If yes, can you point me to a documentation?
    If not, sad

    Thanx!

    Leave a comment:


  • takkaria
    replied
    Originally posted by TJA
    Now i tried to add the borg:
    You're trying to add the 3.0.6 borg to the game. Don't do that.

    Leave a comment:


  • TJA
    replied
    Now i tried to add the borg:

    Code:
            CC     cmd0.c
    cmd0.c:281: error: conflicting types for `do_cmd_try_borg'
    cmd0.c:44: error: previous declaration of `do_cmd_try_borg'
    cmd0.c: In function `do_cmd_try_borg':
    cmd0.c:292: warning: `return' with no value, in function returning non-void
    make[2]: *** [cmd0.o] Error 1
    make[1]: *** [build] Error 2
    make: *** [build] Error 2

    Edit: "BORG" is only mentioned in Makefile.osx and Makefile.ros

    :-O

    Or do i need more than the regular VA to use this option in config.h?!?

    Leave a comment:


  • TJA
    replied
    Yep, problem is, that i read his answer only now after you mentioned it - did not notice it before and was just trying myself ...


    Now i just comment out the HAVE_STDBOOL_H line in src/autoconf.h.in and am ready for all situation and re-configures and compiles

    Works like a charm.

    Leave a comment:


  • Daven_26d1
    replied
    heh, well done - but you should never have had to do this!

    Anyway, after that headache of an install, basic V will be far too simple for you; may I suggest pt-based mode, with ironman_stairs, artifact_no_preserve and all the AI options set ('cept maybe smart_cheat - that one is *sick*). With a kobold. You know you want too!

    Glad you're up and running; enjoy yourself - and welcome to oook!

    EDIT - I have to say takkaria's fix is probably a better idea than your own hack; it's mostly sensible to modify source/makefiles etc in your target, not generic dependant libs.
    Last edited by Daven_26d1; August 15, 2007, 13:53.

    Leave a comment:


  • TJA
    replied
    Found and fixed it!

    I am not sure if that can be fixed from Angand and it´s Makefiles or not.

    I change one line in ncurses.h:

    Code:
    typedef unsigned char NCURSES_BOOL;
    
    #if defined(__cplusplus)        /* __cplusplus, etc. */
    
    /* use the C++ compiler's bool type */
    #define NCURSES_BOOL bool
    
    #else                   /* c89, c99, etc. */
    
    #if 1
    #include <stdbool.h>
    /* use whatever the C compiler decides bool really is */
    #define NCURSES_BOOL bool
    #else
    /* there is no predefined bool - use our own */
    #undef bool
    #define bool NCURSES_BOOL
    #endif
    
    #endif /* !__cplusplus, etc. */
    
    #ifdef __cplusplus
    extern "C" {
    #endif
    Do you see that "#if 1" line?
    I changed it to "#if 0", forcing the definition of "bool" by ncurses ...

    Result:

    Code:
            CC     main-gcu.c
            CC     main-gtk.c
            CC     main-ros.c
            CC     main-sdl.c
            CC     main-win.c
            CC     main-x11.c
            CC     main-xaw.c
            CC     snd-sdl.c
            CC     z-file.c
            CC     z-form.c
            CC     z-rand.c
            CC     z-term.c
            CC     z-type.c
            CC     z-util.c
            CC     z-virt.c
          LINK     angband
    So, my OLD, old ncurses 5.4 is still young enough to compile Angband

    Thanx!

    Leave a comment:


  • TJA
    replied
    I had a look at ncurses.h and found nothing special.
    The syntax error occurs at a "bool" line ...
    And about this, i found the following:


    /* XSI and SVr4 specify that curses implements 'bool'. However, C++ may also
    * implement it. If so, we must use the C++ compiler's type to avoid conflict
    * with other interfaces.
    *
    * A further complication is that <stdbool.h> may declare 'bool' to be a
    * different type, such as an enum which is not necessarily compatible with
    * C++. If we have <stdbool.h>, make 'bool' a macro, so users may #undef it.
    * Otherwise, let it remain a typedef to avoid conflicts with other #define's.
    * In either case, make a typedef for NCURSES_BOOL which can be used if needed
    * from either C or C++.
    */
    So, this may be a problem with ncurses and the defintion of "bool" itself?!?
    Trying to force the cplusplus Variant did not help either.

    Leave a comment:


  • takkaria
    replied
    Originally posted by TJA
    This does not look like "just a wrong ncurses" ...
    It is. Note all the errors occur around use of "bool". I have a fix for you, though: re-run "./configure", run "make clean"; edit autoconf.h in src/ and remove the lines mentioning HAVE_STDBOOL_H; recompile. It should work fine.

    Leave a comment:


  • TJA
    replied
    Thanx for this tip, Daven!

    My ncurses libraries are here:

    Code:
    rpm -qil ncurses-devel-5.4-68 ncurses-5.4-68 | grep ^\/ | grep lib | grep ncurs
    /usr/lib/libncurses++.a
    /usr/lib/libncurses++w.a
    /usr/lib/libncurses.a
    /usr/lib/libncurses.so
    /usr/lib/libncursesw.so
    /lib/libncurses.so.5
    /lib/libncurses.so.5.4
    /usr/lib/libncursesw.so.5
    /usr/lib/libncursesw.so.5.4

    So, i changed Makefile.std like this:

    Code:
    LIBS = -L/usr/X11R6/lib -L/usr/lib -L/lib
    That did not help ...


    Code:
    In file included from main-gcu.c:63:
    /usr/include/ncurses.h:337: error: syntax error before "bool"
    /usr/include/ncurses.h:339: error: syntax error before "_leaveok"
    /usr/include/ncurses.h:340: error: syntax error before "_scroll"
    /usr/include/ncurses.h:341: error: syntax error before "_idlok"
    /usr/include/ncurses.h:342: error: syntax error before "_idcok"
    /usr/include/ncurses.h:343: error: syntax error before "_immed"
    /usr/include/ncurses.h:344: error: syntax error before "_sync"
    /usr/include/ncurses.h:345: error: syntax error before "_use_keypad"
    /usr/include/ncurses.h:372: error: syntax error before '}' token
    /usr/include/ncurses.h:393: error: syntax error before "is_term_resized"
    /usr/include/ncurses.h:399: error: syntax error before "bool"
    /usr/include/ncurses.h:521: error: syntax error before "can_change_color"
    /usr/include/ncurses.h:525: error: syntax error before "bool"
    /usr/include/ncurses.h:557: error: syntax error before "has_colors"
    /usr/include/ncurses.h:558: error: syntax error before "has_ic"
    /usr/include/ncurses.h:559: error: syntax error before "has_il"
    /usr/include/ncurses.h:561: error: syntax error before "bool"
    /usr/include/ncurses.h:562: error: syntax error before "bool"
    /usr/include/ncurses.h:563: error: syntax error before "bool"
    /usr/include/ncurses.h:577: error: syntax error before "bool"
    /usr/include/ncurses.h:578: error: syntax error before "isendwin"
    /usr/include/ncurses.h:579: error: syntax error before "is_linetouched"
    /usr/include/ncurses.h:580: error: syntax error before "is_wintouched"
    /usr/include/ncurses.h:582: error: syntax error before "bool"
    /usr/include/ncurses.h:584: error: syntax error before "bool"
    /usr/include/ncurses.h:586: error: syntax error before "bool"
    /usr/include/ncurses.h:645: error: syntax error before "bool"
    /usr/include/ncurses.h:650: error: syntax error before "bool"
    /usr/include/ncurses.h:677: error: syntax error before "bool"
    /usr/include/ncurses.h:703: error: syntax error before "bool"
    /usr/include/ncurses.h:1413: error: syntax error before "wenclose"
    /usr/include/ncurses.h:1415: error: syntax error before "wmouse_trafo"
    /usr/include/ncurses.h:1415: error: syntax error before "bool"
    /usr/include/ncurses.h:1416: error: syntax error before "mouse_trafo"
    /usr/include/ncurses.h:1416: error: syntax error before "bool"
    main-gcu.c: In function `Term_xtra_gcu_alive':
    main-gcu.c:290: error: dereferencing pointer to incomplete type
    main-gcu.c:290: error: dereferencing pointer to incomplete type
    main-gcu.c:290: warning: left-hand operand of comma expression has no effect
    main-gcu.c: In function `Term_nuke_gcu':
    main-gcu.c:383: error: dereferencing pointer to incomplete type
    main-gcu.c:383: error: dereferencing pointer to incomplete type
    main-gcu.c:383: warning: left-hand operand of comma expression has no effect
    main-gcu.c: In function `Term_xtra_gcu':
    main-gcu.c:505: error: dereferencing pointer to incomplete type
    main-gcu.c: In function `Term_text_gcu':
    main-gcu.c:616: error: dereferencing pointer to incomplete type
    main-gcu.c:630: error: dereferencing pointer to incomplete type
    main-gcu.c: In function `init_gcu':
    main-gcu.c:712: error: `bool' undeclared (first use in this function)
    main-gcu.c:712: error: (Each undeclared identifier is reported only once
    main-gcu.c:712: error: for each function it appears in.)
    main-gcu.c:712: error: syntax error before "use_big_screen"
    main-gcu.c:720: error: `use_big_screen' undeclared (first use in this function)
    make[2]: *** [main-gcu.o] Error 1
    make[1]: *** [build] Error 2
    make: *** [build] Error 2
    This does not look like "just a wrong ncurses" ...

    :-O

    I will try more and report here

    Leave a comment:


  • Daven_26d1
    replied
    The errors you got when compiling via make -f..etc is a problem I encountered on SuSE 10.1 with v3.0.8, tho the issue is fixed for me in v3.0.9.

    Basically, the makefile hasn't detected your x-libs, or has incorrectly used the path.
    Assuming that novell didn't change the tree structure between 9.3 & 10.1, see:



    for a workaround that should get you up and running. Beware that I had a typo in the path I reported, but pav slyly corrects me right underneath my fix.

    Leave a comment:

Working...
😀
😂
🥰
😘
🤢
😎
😞
😡
👍
👎
☕