Loading ...
Sorry, an error occurred while loading the content.

Building on Windows with XPM

Expand Messages
  • Bram Moolenaar
    I was trying to get Vim to build with MSVC 2008 on a clean system with all the optional extras. One thing that doesn t work is the XPM feature. The
    Message 1 of 13 , Aug 2, 2012
    • 0 Attachment
      I was trying to get Vim to build with MSVC 2008 on a clean system with
      all the optional extras. One thing that doesn't work is the XPM
      feature.

      The Make_mvc.mak file recommeds:

      # XPM - Include support for XPM signs
      # You need to download or build xpm.lib somehow.
      # You can get the most recent version of libXpm-*.zip from
      # http://cgit.freedesktop.org/xorg/lib/libXpm


      But that site is down. I found an alternate xpm_w32 zip file on
      ftp.gnu.org, but it does not include libXpm.lib and no way to build it.

      Any suggestions?

      --
      hundred-and-one symptoms of being an internet addict:
      197. Your desk collapses under the weight of your computer peripherals.

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
      \\\ an exciting new programming language -- http://www.Zimbu.org ///
      \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

      --
      You received this message from the "vim_dev" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php
    • Sergey Khorev
      ... I have built libXpm some 8 years ago. It is available from https://sites.google.com/site/khorser/opensource/vim/xpm.zip?attredirects=0&d=1 Is it possible
      Message 2 of 13 , Aug 2, 2012
      • 0 Attachment
        > # XPM - Include support for XPM signs
        > # You need to download or build xpm.lib somehow.
        > # You can get the most recent version of libXpm-*.zip from
        > # http://cgit.freedesktop.org/xorg/lib/libXpm
        >
        >
        > But that site is down. I found an alternate xpm_w32 zip file on
        > ftp.gnu.org, but it does not include libXpm.lib and no way to build it.


        I have built libXpm some 8 years ago. It is available from
        https://sites.google.com/site/khorser/opensource/vim/xpm.zip?attredirects=0&d=1
        Is it possible to put the file on Vim ftp?

        --
        You received this message from the "vim_dev" maillist.
        Do not top-post! Type your reply below the text you are replying to.
        For more information, visit http://www.vim.org/maillist.php
      • tux.
        ... It does not compile though. It says it can t find xpm.h although the directory is correctly added per -I parametert. -- You received this message from the
        Message 3 of 13 , Aug 2, 2012
        • 0 Attachment
          Sergey Khorev schrob am 02. Aug. 2012 um 20:26 Zeit:
          > I have built libXpm some 8 years ago. It is available from
          > https://sites.google.com/site/khorser/opensource/vim/xpm.zip?attredirects=0&d=1


          It does not compile though. It says it can't find xpm.h although the
          directory is correctly added per -I parametert.

          --
          You received this message from the "vim_dev" maillist.
          Do not top-post! Type your reply below the text you are replying to.
          For more information, visit http://www.vim.org/maillist.php
        • Sergey Khorev
          ... You didn t mention how you tried to build Vim, here is how I did it: nmake -f Make_mvc.mak GUI=yes CSCOPE=yes NETBEANS=yes XPM=e: hg xpm E: HG vim src dir
          Message 4 of 13 , Aug 2, 2012
          • 0 Attachment
            > It does not compile though. It says it can't find xpm.h although the
            > directory is correctly added per -I parametert.

            You didn't mention how you tried to build Vim, here is how I did it:
            nmake -f Make_mvc.mak GUI=yes CSCOPE=yes NETBEANS=yes XPM=e:\hg\xpm

            E:\HG\vim\src>dir /B /S e:\hg\xpm
            e:\hg\xpm\include
            e:\hg\xpm\lib
            e:\hg\xpm\include\simx.h
            e:\hg\xpm\include\xpm.h
            e:\hg\xpm\lib\libXpm.lib

            --
            You received this message from the "vim_dev" maillist.
            Do not top-post! Type your reply below the text you are replying to.
            For more information, visit http://www.vim.org/maillist.php
          • Bram Moolenaar
            ... Thanks. I tried and it builds with MSVC 2008. Don t know how to try if it actually works. ... OK, I ll put it here:
            Message 5 of 13 , Aug 2, 2012
            • 0 Attachment
              Sergey Khorev wrote:

              > > # XPM - Include support for XPM signs
              > > # You need to download or build xpm.lib somehow.
              > > # You can get the most recent version of libXpm-*.zip from
              > > # http://cgit.freedesktop.org/xorg/lib/libXpm
              > >
              > >
              > > But that site is down. I found an alternate xpm_w32 zip file on
              > > ftp.gnu.org, but it does not include libXpm.lib and no way to build it.
              >
              >
              > I have built libXpm some 8 years ago. It is available from
              > https://sites.google.com/site/khorser/opensource/vim/xpm.zip?attredirects=0&d=1

              Thanks. I tried and it builds with MSVC 2008. Don't know how to try if
              it actually works.

              > Is it possible to put the file on Vim ftp?

              OK, I'll put it here: ftp://ftp.vim.org/pub/vim/pcextra/xpm.zip

              Can you give some information about what it was build with? I suppose
              it only works for 32 bits builds?

              --
              hundred-and-one symptoms of being an internet addict:
              201. When somebody asks you where you are, you tell them in which chat room.

              /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
              /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
              \\\ an exciting new programming language -- http://www.Zimbu.org ///
              \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

              --
              You received this message from the "vim_dev" maillist.
              Do not top-post! Type your reply below the text you are replying to.
              For more information, visit http://www.vim.org/maillist.php
            • tux.
              ... Ah, I used relative folders. My fault, thanks! -- You received this message from the vim_dev maillist. Do not top-post! Type your reply below the text
              Message 6 of 13 , Aug 2, 2012
              • 0 Attachment
                Sergey Khorev schrob am 02. Aug. 2012 um 21:31 Zeit:
                > nmake -f Make_mvc.mak GUI=yes CSCOPE=yes NETBEANS=yes XPM=e:\hg\xpm


                Ah, I used relative folders. My fault, thanks!

                --
                You received this message from the "vim_dev" maillist.
                Do not top-post! Type your reply below the text you are replying to.
                For more information, visit http://www.vim.org/maillist.php
              • Sergey Khorev
                ... Originally I did it for that Netbeans plugin which for some reason used only XPM icons. Commands below will show whether XPM lib is ... Correct, the binary
                Message 7 of 13 , Aug 2, 2012
                • 0 Attachment
                  > Thanks. I tried and it builds with MSVC 2008. Don't know how to try if
                  > it actually works.

                  Originally I did it for that Netbeans plugin which for some reason
                  used only XPM icons. Commands below will show whether XPM lib is
                  working or not:
                  :exe 'sign define vimxpm icon='.$VIMRUNTIME.'\\vim32x32.xpm'
                  :exe 'sign place 1 line=1 name=vimxpm file='.expand('%:p')

                  > Can you give some information about what it was build with? I suppose
                  > it only works for 32 bits builds?

                  Correct, the binary is 32bit only but it can be built for 64bit
                  without any problems. Here are the makefiles:

                  Makefile for MSVC:

                  ---- snip ----
                  src = Attrib.c CrBufFrI.c CrDatFrI.c create.c CrIFrBuf.c CrIFrDat.c \
                  data.c hashtab.c Image.c Info.c misc.c RdFToBuf.c RdFToDat.c \
                  RdFToI.c rgb.c scan.c simx.c WrFFrBuf.c parse.c \
                  WrFFrDat.c WrFFrI.c

                  obj = Attrib.obj CrBufFrI.obj CrDatFrI.obj create.obj CrIFrBuf.obj
                  CrIFrDat.obj \
                  data.obj hashtab.obj Image.obj Info.obj misc.obj RdFToBuf.obj RdFToDat.obj \
                  RdFToI.obj rgb.obj scan.obj simx.obj WrFFrBuf.obj parse.obj \
                  WrFFrDat.obj WrFFrI.obj

                  .c.obj:
                  cl -DFOR_MSW /c $<

                  target = ..\lib\libXpm.lib

                  all: $(target)

                  $(target): $(obj)
                  lib /out:$(target) $(obj)
                  ---- snip ----


                  Makefile for MinGW:

                  ---- snip ----
                  src = Attrib.c CrBufFrI.c CrDatFrI.c create.c CrIFrBuf.c CrIFrDat.c \
                  data.c hashtab.c Image.c Info.c misc.c RdFToBuf.c RdFToDat.c \
                  RdFToI.c rgb.c scan.c simx.c WrFFrBuf.c parse.c \
                  WrFFrDat.c WrFFrI.c

                  obj = Attrib.o CrBufFrI.o CrDatFrI.o create.o CrIFrBuf.o CrIFrDat.o \
                  data.o hashtab.o Image.o Info.o misc.o RdFToBuf.o RdFToDat.o \
                  RdFToI.o rgb.o scan.o simx.o WrFFrBuf.o parse.o \
                  WrFFrDat.o WrFFrI.o

                  .c.o:
                  gcc -O2 -DFOR_MSW -c $<

                  target = libXpm.a

                  all: $(target)

                  $(target): $(obj)
                  ar r $(target) $(obj)
                  ---- snip ----

                  --
                  You received this message from the "vim_dev" maillist.
                  Do not top-post! Type your reply below the text you are replying to.
                  For more information, visit http://www.vim.org/maillist.php
                • Bram Moolenaar
                  ... Thanks, it works (although the image is too big :-)). ... I would prefer for people to be able to easily download and install the dependencies. It s
                  Message 8 of 13 , Aug 3, 2012
                  • 0 Attachment
                    Sergey Khorev wrote:

                    > > Thanks. I tried and it builds with MSVC 2008. Don't know how to try if
                    > > it actually works.
                    >
                    > Originally I did it for that Netbeans plugin which for some reason
                    > used only XPM icons. Commands below will show whether XPM lib is
                    > working or not:
                    > :exe 'sign define vimxpm icon='.$VIMRUNTIME.'\\vim32x32.xpm'
                    > :exe 'sign place 1 line=1 name=vimxpm file='.expand('%:p')

                    Thanks, it works (although the image is too big :-)).


                    > > Can you give some information about what it was build with? I suppose
                    > > it only works for 32 bits builds?
                    >
                    > Correct, the binary is 32bit only but it can be built for 64bit
                    > without any problems. Here are the makefiles:

                    I would prefer for people to be able to easily download and install the
                    dependencies. It's difficult enough to build Vim already.

                    Perhaps you can make one zip file that contains the required header
                    files and the .lib files for 32 and 64 bit?

                    Note that depending on the license the source files need to be included
                    as well. At least include a README that mentions the copyright.

                    --
                    hundred-and-one symptoms of being an internet addict:
                    207. You're given one phone call in prison and you ask them for a laptop.

                    /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
                    /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
                    \\\ an exciting new programming language -- http://www.Zimbu.org ///
                    \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

                    --
                    You received this message from the "vim_dev" maillist.
                    Do not top-post! Type your reply below the text you are replying to.
                    For more information, visit http://www.vim.org/maillist.php
                  • Sergey Khorev
                    Hi Bram, ... I am travelling now and don t have 64bit compiler on my laptop. Will prepare the zip when I m back (in 2 weeks). -- You received this message from
                    Message 9 of 13 , Aug 3, 2012
                    • 0 Attachment
                      Hi Bram,

                      > I would prefer for people to be able to easily download and install the
                      > dependencies. It's difficult enough to build Vim already.
                      >
                      > Perhaps you can make one zip file that contains the required header
                      > files and the .lib files for 32 and 64 bit?
                      >
                      > Note that depending on the license the source files need to be included
                      > as well. At least include a README that mentions the copyright.

                      I am travelling now and don't have 64bit compiler on my laptop. Will
                      prepare the zip when I'm back (in 2 weeks).

                      --
                      You received this message from the "vim_dev" maillist.
                      Do not top-post! Type your reply below the text you are replying to.
                      For more information, visit http://www.vim.org/maillist.php
                    • Sergey Khorev
                      Hi Bram, ... Here is the zip containing the library: https://sites.google.com/site/khorser/opensource/vim/xpmWin.zip?attredirects=0&d=1 For some reason gmail
                      Message 10 of 13 , Aug 26, 2012
                      • 0 Attachment
                        Hi Bram,

                        >> Note that depending on the license the source files need to be included
                        >> as well. At least include a README that mentions the copyright.
                        >
                        > I am travelling now and don't have 64bit compiler on my laptop. Will
                        > prepare the zip when I'm back (in 2 weeks).

                        Here is the zip containing the library:
                        https://sites.google.com/site/khorser/opensource/vim/xpmWin.zip?attredirects=0&d=1

                        For some reason gmail thinks that libraries are executable and does
                        not allow sending them.

                        --
                        You received this message from the "vim_dev" maillist.
                        Do not top-post! Type your reply below the text you are replying to.
                        For more information, visit http://www.vim.org/maillist.php
                      • Bram Moolenaar
                        ... Thanks for making this available. It s fairly small and a quick glance shows the license is liberal, so perhaps we should simply include it in the
                        Message 11 of 13 , Aug 27, 2012
                        • 0 Attachment
                          Sergey Khorev wrote:

                          > >> Note that depending on the license the source files need to be included
                          > >> as well. At least include a README that mentions the copyright.
                          > >
                          > > I am travelling now and don't have 64bit compiler on my laptop. Will
                          > > prepare the zip when I'm back (in 2 weeks).
                          >
                          > Here is the zip containing the library:
                          > https://sites.google.com/site/khorser/opensource/vim/xpmWin.zip?attredirects=0&d=1
                          >
                          > For some reason gmail thinks that libraries are executable and does
                          > not allow sending them.

                          Thanks for making this available. It's fairly small and a quick glance
                          shows the license is liberal, so perhaps we should simply include it in
                          the distribution. Otherwise I can put it on the Vim ftp site.

                          --
                          FIRST HEAD: All right! All right! We'll kill him first and then have tea and
                          biscuits.
                          "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

                          /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
                          /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
                          \\\ an exciting new programming language -- http://www.Zimbu.org ///
                          \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

                          --
                          You received this message from the "vim_dev" maillist.
                          Do not top-post! Type your reply below the text you are replying to.
                          For more information, visit http://www.vim.org/maillist.php
                        • Sergey Khorev
                          ... I think it s a good idea to include it into the distribution. -- You received this message from the vim_dev maillist. Do not top-post! Type your reply
                          Message 12 of 13 , Aug 27, 2012
                          • 0 Attachment
                            > Thanks for making this available. It's fairly small and a quick glance
                            > shows the license is liberal, so perhaps we should simply include it in
                            > the distribution. Otherwise I can put it on the Vim ftp site.

                            I think it's a good idea to include it into the distribution.

                            --
                            You received this message from the "vim_dev" maillist.
                            Do not top-post! Type your reply below the text you are replying to.
                            For more information, visit http://www.vim.org/maillist.php
                          • Bram Moolenaar
                            Sergey - ... I think it s OK to include the files under src/xpm. I don t think it is useful to include the makefiles, since the required source files are not
                            Message 13 of 13 , Aug 29, 2012
                            • 0 Attachment
                              Sergey -

                              > >> Note that depending on the license the source files need to be included
                              > >> as well. At least include a README that mentions the copyright.
                              > >
                              > > I am travelling now and don't have 64bit compiler on my laptop. Will
                              > > prepare the zip when I'm back (in 2 weeks).
                              >
                              > Here is the zip containing the library:
                              > https://sites.google.com/site/khorser/opensource/vim/xpmWin.zip?attredirects=0&d=1
                              >
                              > For some reason gmail thinks that libraries are executable and does
                              > not allow sending them.

                              I think it's OK to include the files under src/xpm.

                              I don't think it is useful to include the makefiles, since the required
                              source files are not included.

                              Including the include files twice, because of the different path, isn't
                              nice. I'll find a way to avoid that.

                              - Bram

                              --
                              GALAHAD hurries to the door and pushes through it. As he leaves the room
                              we CUT TO the reverse to show that he is now in a room full of bathing
                              and romping GIRLIES, all innocent, wide-eyed and beautiful. They smile
                              enchantingly at him as he tries to keep walking without being diverted by
                              the lovely sights assaulting his eyeballs.
                              "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

                              /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
                              /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
                              \\\ an exciting new programming language -- http://www.Zimbu.org ///
                              \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

                              --
                              You received this message from the "vim_dev" maillist.
                              Do not top-post! Type your reply below the text you are replying to.
                              For more information, visit http://www.vim.org/maillist.php
                            Your message has been successfully submitted and would be delivered to recipients shortly.