Compiling NPP on Ubuntu questions

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Nick
    Vanilla maintainer
    • Apr 2007
    • 9634

    #31
    Originally posted by nppangband
    I was afraid of that, because it simply isn't working. Maybe I need to manually create all the directories in '/usr/local/share/angband?

    Altenatively, what make command keeps the whole thing in the (linux account)/Documents/Angband directory, so I don't have to create anything is usr/local?
    IIRC you run configure as
    Code:
    ./configure --use-local-dirs
    On a different note, once I get this working, to run the various different versions, don't I add an extension at the end, right? ./angband -sdl, or ./angband -x11.
    It's
    Code:
    ./angband -msdl
    The code will try to find a display module - it runs though x11, gcu, sdl if it's enabled, I think in that order.

    Is there anyone out there on Linux who willing to take a quick 5-10 minutes and download the NPP source (work-in-progress branch) from github and see if they have any difficulties in getting it to execute? At least then I can eliminate the NPP source as the problem. (The fact that I am blocked from running Angband 3.3 either should be a pretty good indicator) I have spent hours on this, RTFM repeatedly, and I am just not having any success. This is crazy.

    https://github.com/nppangband/NPPAng...rk_in_progress
    Don't be disheartened - Linux takes a while to get used to, but in my experience that pays off.

    As far as the bone error goes, the problem is trailing whitespace at the end of the CONFIG line (ie after bone.147) - yes, I'm serious

    Apart from that, there are references in the lib/* Makefiles to some files that you don't have.

    I have made a fork, and fixed it to the point where it compiles for me - here is the relevant branch:
    A variant of Angband, a roguelike game https://github.com/angband - GitHub - NickMcConnell/NPPAngband at Work_in_progress


    EDIT: Actually tried running it, and had Eddie's font problem; running with -msdl worked fine, though, as does -mgcu.
    Last edited by Nick; February 12, 2012, 00:02.
    One for the Dark Lord on his dark throne
    In the Land of Mordor where the Shadows lie.

    Comment

    • nppangband
      NPPAngband Maintainer
      • Dec 2008
      • 926

      #32
      @powerdiver - thank you very much. Someday I will name an artifact after you or make you a player ghost or something like that.

      I am as far as you are. I definitely had a permissions issue, and I finally resolved it. I can fix the fonts thing. It is trying to load a windows-specific font instead of the linux-specific .bdf fonts in NPP. So I just need to specify different defualt fonts for the various linux main files and recompile.

      edit:
      @Nick - thank you as well. I think you are already a player ghost. If you aren't, you will be soon.
      NPPAngband current home page: http://nppangband.bitshepherd.net/
      Source code repository:
      https://github.com/nppangband/NPPAngband_QT
      Downloads:
      https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57

      Comment

      • PowerDiver
        Prophet
        • Mar 2008
        • 2820

        #33
        If you plan to do any development under Ubuntu, I have some important advice for you. Do not copy the executable up a level. Use a symbolic link instead. In the earlier post I used: ln -s src/nppangband

        You do not want it to be possible that you run make, forget to copy up [or equivalent], and then invoke the previous executable. You go crazy wondering why your changes aren't doing what you want.

        If you want to get fancy, an alternative is to put in extra rules in your makefile. For example "make play" to play, which depends upon the installed executable, which in turn depends on the compiled executable.

        Comment

        • nppangband
          NPPAngband Maintainer
          • Dec 2008
          • 926

          #34
          Originally posted by PowerDiver
          If you plan to do any development under Ubuntu, I have some important advice for you. Do not copy the executable up a level. Use a symbolic link instead. In the earlier post I used: ln -s src/nppangband

          You do not want it to be possible that you run make, forget to copy up [or equivalent], and then invoke the previous executable. You go crazy wondering why your changes aren't doing what you want.

          If you want to get fancy, an alternative is to put in extra rules in your makefile. For example "make play" to play, which depends upon the installed executable, which in turn depends on the compiled executable.
          Thanks. I know the windows makefile automatically copies the executable from the /NPP/src directory to the base /npp directory. I was considering having the regular makefile do the same thing. But I will take that on once I get it running.

          @Nick - I pulled (or pushed or fetched or whatever git calls it) your github fork back into the NPP work-in-progress branch. Thank you for that.
          NPPAngband current home page: http://nppangband.bitshepherd.net/
          Source code repository:
          https://github.com/nppangband/NPPAngband_QT
          Downloads:
          https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57

          Comment

          • AnonymousHero
            Veteran
            • Jun 2007
            • 1393

            #35
            Originally posted by PowerDiver
            If you plan to do any development under Ubuntu, I have some important advice for you. Do not copy the executable up a level. Use a symbolic link instead. In the earlier post I used: ln -s src/nppangband
            You can also just get used to typing ./src/nppangband instead of ./nppangband .

            Comment

            • Magnate
              Angband Devteam member
              • May 2007
              • 5110

              #36
              Originally posted by AnonymousHero
              You can also just get used to typing ./src/nppangband instead of ./nppangband .
              +1. This is the easiest way to play and/or test using --with-no-install, because if you move or copy stuff around, make clean might not clean up properly.
              "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

              Comment

              • nppangband
                NPPAngband Maintainer
                • Dec 2008
                • 926

                #37
                Originally posted by Magnate

                Originally posted by AnonymousHero
                You can also just get used to typing ./src/nppangband instead of ./nppangband .
                +1. This is the easiest way to play and/or test using --with-no-install, because if you move or copy stuff around, make clean might not clean up properly.
                Great suggestion. That seems like the best & simplest solution.
                NPPAngband current home page: http://nppangband.bitshepherd.net/
                Source code repository:
                https://github.com/nppangband/NPPAngband_QT
                Downloads:
                https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57

                Comment

                • nppangband
                  NPPAngband Maintainer
                  • Dec 2008
                  • 926

                  #38
                  I got the gcu port working. That's a good start. I think X-11 and gtk can't load because of the specisl x-char fonts, but I am going to switch to UTF-8 soon, so the special s-xhar fonts won't be needed any more.

                  For sdl, it says "Unable to prepare any 'display module". I do have ncurses loaded. Is there any other dependency I need?

                  EDIT: SDL is now working too.
                  Last edited by nppangband; February 14, 2012, 02:36.
                  NPPAngband current home page: http://nppangband.bitshepherd.net/
                  Source code repository:
                  https://github.com/nppangband/NPPAngband_QT
                  Downloads:
                  https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57

                  Comment

                  • PowerDiver
                    Prophet
                    • Mar 2008
                    • 2820

                    #39
                    Originally posted by AnonymousHero
                    You can also just get used to typing ./src/nppangband instead of ./nppangband .
                    If you are going to do that, just use src/nppangband, but you will be better off if you learn to use links.

                    Comment

                    • AnonymousHero
                      Veteran
                      • Jun 2007
                      • 1393

                      #40
                      Originally posted by PowerDiver
                      If you are going to do that, just use src/nppangband, but you will be better off if you learn to use links.
                      Heh, I see I've used both on occasion (link and using the relative path). For some reason I've gotten used to always having the dot in ./blabla/blabla/bla. Probably because of tab-completion which doesn't expand directories in the current dir until you type the first '/'. Obviously not a big deal if you just need to type 'src', but it's just embeddded in my finger memory at this point.

                      Comment

                      • PowerDiver
                        Prophet
                        • Mar 2008
                        • 2820

                        #41
                        Originally posted by AnonymousHero
                        Heh, I see I've used both on occasion (link and using the relative path). For some reason I've gotten used to always having the dot in ./blabla/blabla/bla. Probably because of tab-completion which doesn't expand directories in the current dir until you type the first '/'. Obviously not a big deal if you just need to type 'src', but it's just embeddded in my finger memory at this point.
                        You should be able to complete a directory as soon as you've typed enough to distinguish it from any commands available from your path. Typing "sr" ought to be enough to start completing src/... .

                        Comment

                        • Derakon
                          Prophet
                          • Dec 2009
                          • 9022

                          #42
                          Originally posted by PowerDiver
                          You should be able to complete a directory as soon as you've typed enough to distinguish it from any commands available from your path. Typing "sr" ought to be enough to start completing src/... .
                          I could easily believe this is one of those things that depends on which shell you use. For what it's worth, I'm using bash and can tab-complete directories without a leading ./

                          Comment

                          • AnonymousHero
                            Veteran
                            • Jun 2007
                            • 1393

                            #43
                            It's shell and shell options related, probably. I've been using zsh for ages.

                            Comment

                            • nppangband
                              NPPAngband Maintainer
                              • Dec 2008
                              • 926

                              #44
                              I am back with a couple more questions:

                              In linux, what command line do I need to do to get graphics working? I tried loading graphics on the sdl port, and it didn't work. My configure, compile, and execute lines are:

                              ./autogen.sh
                              ./configure --with-no-install --enable-sdl
                              make
                              make install
                              ./src/nppangband -msdl
                              NPPAngband current home page: http://nppangband.bitshepherd.net/
                              Source code repository:
                              https://github.com/nppangband/NPPAngband_QT
                              Downloads:
                              https://app.box.com/s/1x7k65ghsmc31usmj329pb8415n1ux57

                              Comment

                              • Magnate
                                Angband Devteam member
                                • May 2007
                                • 5110

                                #45
                                Originally posted by nppangband
                                I am back with a couple more questions:

                                In linux, what command line do I need to do to get graphics working? I tried loading graphics on the sdl port, and it didn't work. My configure, compile, and execute lines are:

                                ./autogen.sh
                                ./configure --with-no-install --enable-sdl
                                make
                                make install
                                ./src/nppangband -msdl
                                That should be all you need for the build, so I suspect the problem is somewhere in run-time config. When you "tried loading graphics", what exactly did you do? AFAIK (and remember I'm not a tiles expert), the 'right' way in the SDL port is

                                1. Click the "Options" button in the top-right corner of the SDL window.

                                2. Click the desired tileset's button (Original, Adam Bolt, David Gervais, Nomad's, Shockbolt, None)

                                3. Select the desired tile width and height.

                                4. Click the OK button.

                                5. (You may need to adjust the main subwindow's font size to get the right visual result, otherwise tiles get cropped or something.)

                                If this is what you're doing, can you describe what happens?
                                "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

                                Comment

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