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

Re: Patch 7.2.058

Expand Messages
  • Tony Mechelynck
    ... Well, as long as the patch applies (with line shifts but no errors) there s no urgency to unapply-reapply, I suppose. Anyway, as soon as one has more than
    Message 1 of 16 , Dec 1, 2008
    • 0 Attachment
      On 01/12/08 14:18, Bill McCarthy wrote:
      > On Sun 30-Nov-08 4:47pm -0600, Tony Mechelynck wrote:
      >
      >> On 30/11/08 12:53, Bram Moolenaar wrote:
      >>> Patch 7.2.058
      >>> Problem: Can't add a patch name to the ":version" output.
      >>> Solution: Add the extra_patches array.
      >>> Files: src/version.c
      >> [...]
      >>
      >> Nice new feature :-). However, unlike the "Modified by" line and the
      >> "highest standard patch number", it is reflected only in the output of
      >> ":version" -- not on the ":intro" screen, where even the fact that
      >> "extra" patches are present does not appear. Is this intentional?
      >
      > Interesting. I've added the extra patch description similar
      > to yours. A similar patch to version.c could be added to
      > the floating point patch.
      >
      > This would require, whenever eval.c is changed: (1)
      > reversing the patch, (2) applying Bram's patches then (3)
      > reapplying the floating point patch. This is the same
      > process others may use today - no change.
      >
      >

      Well, as long as the patch applies (with line shifts but no errors)
      there's no urgency to unapply-reapply, I suppose.

      Anyway, as soon as one has more than one "extra patch" applied,
      reversing the earlier one will give lineshifts, if only because it is
      now lower in version.c

      See also the variant with "#ifdef FEAT_FLOAT" in the next post to the
      one you quoted above. (I'm using common sources [with a shadowdir] for a
      huge gvim and a tiny vi, as close as I can get to both ends of the
      capability range, and I don't want vi (with -float) to boast about a
      patch which is actually disabled in it.)


      Best regards,
      Tony.
      --
      There once was a girl named Irene
      Who lived on distilled kerosene
      But she started absorbin'
      A new hydrocarbon
      And since then has never benzene.

      --~--~---------~--~----~------------~-------~--~----~
      You received this message from the "vim_dev" maillist.
      For more information, visit http://www.vim.org/maillist.php
      -~----------~----~----~----~------~----~------~--~---
    • Bill McCarthy
      ... Sorry, that email was a draft that I thought I hadn t sent this morning. BTW, I have a fairly formal procedure for dealing with eval.c patching:
      Message 2 of 16 , Dec 1, 2008
      • 0 Attachment
        On Mon 1-Dec-08 7:42am -0600, Tony Mechelynck wrote:

        >
        > On 01/12/08 14:18, Bill McCarthy wrote:
        >> On Sun 30-Nov-08 4:47pm -0600, Tony Mechelynck wrote:
        >>
        >>> On 30/11/08 12:53, Bram Moolenaar wrote:
        >>>> Patch 7.2.058
        >>>> Problem: Can't add a patch name to the ":version" output.
        >>>> Solution: Add the extra_patches array.
        >>>> Files: src/version.c
        >>> [...]
        >>>
        >>> Nice new feature :-). However, unlike the "Modified by" line and the
        >>> "highest standard patch number", it is reflected only in the output of
        >>> ":version" -- not on the ":intro" screen, where even the fact that
        >>> "extra" patches are present does not appear. Is this intentional?
        >>
        >> Interesting. I've added the extra patch description similar
        >> to yours. A similar patch to version.c could be added to
        >> the floating point patch.
        >>
        >> This would require, whenever eval.c is changed: (1)
        >> reversing the patch, (2) applying Bram's patches then (3)
        >> reapplying the floating point patch. This is the same
        >> process others may use today - no change.

        > Well, as long as the patch applies (with line shifts but no errors)
        > there's no urgency to unapply-reapply, I suppose.
        >
        > Anyway, as soon as one has more than one "extra patch" applied,
        > reversing the earlier one will give lineshifts, if only because it is
        > now lower in version.c

        Sorry, that email was a draft that I thought I hadn't sent
        this morning. BTW, I have a fairly formal procedure for
        dealing with eval.c patching:

        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        Instructions for patching eval.c
        ================================

        1) Run PREBRAM to copy eval.c.bram to eval.c
        2) Run the patches from Bram
        3) Run POSTBRAM to copy eval.c to eval.c.bram
        4) Run PEVAL to both patch eval.c and asks to finish

        The finish is POSTEVAL - copies eval.c to eval.c.wjm
        At any time you can run DEVAL for a directory of eval.*
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

        > See also the variant with "#ifdef FEAT_FLOAT" in the next post to the
        > one you quoted above. (I'm using common sources [with a shadowdir] for a
        > huge gvim and a tiny vi, as close as I can get to both ends of the
        > capability range, and I don't want vi (with -float) to boast about a
        > patch which is actually disabled in it.)

        Nice addition.

        --
        Best regards,
        Bill


        --~--~---------~--~----~------------~-------~--~----~
        You received this message from the "vim_dev" maillist.
        For more information, visit http://www.vim.org/maillist.php
        -~----------~----~----~----~------~----~------~--~---
      • Bram Moolenaar
        ... Yes, the intro screen doesn t mention any features. It would get very crowded. It only mentions the last patch included, since that s taking only a small
        Message 3 of 16 , Dec 1, 2008
        • 0 Attachment
          Tony Mechelynck wrote:

          > On 30/11/08 12:53, Bram Moolenaar wrote:
          > >
          > > Patch 7.2.058
          > > Problem: Can't add a patch name to the ":version" output.
          > > Solution: Add the extra_patches array.
          > > Files: src/version.c
          > [...]
          >
          > Nice new feature :-). However, unlike the "Modified by" line and the
          > "highest standard patch number", it is reflected only in the output of
          > ":version" -- not on the ":intro" screen, where even the fact that
          > "extra" patches are present does not appear. Is this intentional?

          Yes, the intro screen doesn't mention any features. It would get very
          crowded. It only mentions the last patch included, since that's taking
          only a small space.

          --
          CUSTOMER: Well, can you hang around a couple of minutes? He won't be
          long.
          MORTICIAN: Naaah, I got to go on to Robinson's -- they've lost nine today.
          CUSTOMER: Well, when is your next round?
          MORTICIAN: Thursday.
          DEAD PERSON: I think I'll go for a walk.
          The Quest for the Holy Grail (Monty Python)

          /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
          /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
          \\\ download, build and distribute -- http://www.A-A-P.org ///
          \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

          --~--~---------~--~----~------------~-------~--~----~
          You received this message from the "vim_dev" maillist.
          For more information, visit http://www.vim.org/maillist.php
          -~----------~----~----~----~------~----~------~--~---
        • Bill McCarthy
          ... How do you get that Modified by to work? There doesn t appear to be anything to modify in the make line. -- Best regards, Bill
          Message 4 of 16 , Dec 1, 2008
          • 0 Attachment
            On Sun 30-Nov-08 4:47pm -0600, Tony Mechelynck wrote:

            > On 30/11/08 12:53, Bram Moolenaar wrote:
            >>
            >> Patch 7.2.058
            >> Problem: Can't add a patch name to the ":version" output.
            >> Solution: Add the extra_patches array.
            >> Files: src/version.c

            > Nice new feature :-). However, unlike the "Modified by" line and the

            How do you get that "Modified by" to work? There doesn't
            appear to be anything to modify in the "make" line.

            --
            Best regards,
            Bill


            --~--~---------~--~----~------------~-------~--~----~
            You received this message from the "vim_dev" maillist.
            For more information, visit http://www.vim.org/maillist.php
            -~----------~----~----~----~------~----~------~--~---
          • Markus Heidelberg
            ... Using 3 lines of these /**/ comment markers would circumvent the problem with the limited context diff. You could just create the patch without worrying,
            Message 5 of 16 , Dec 2, 2008
            • 0 Attachment
              Bram Moolenaar, 30.11.2008:
              >
              > > Patch 7.2.058
              > [...]
              > > + /*
              > > + * Place to put a short description when adding a feature with a patch.
              > > + * Keep it short, e.g.,: "relative numbers", "persistent undo".
              > > + * Also add a comment marker to separate the lines.
              > > + * See the official Vim patches for the diff format: It must use a context of
              > > + * one line only. Use "diff -C2".
              >
              > I forgot to mention that after "diff -C2" you need to edit the patch to
              > reduce the context.

              Using 3 lines of these /**/ comment markers would circumvent the problem
              with the limited context diff. You could just create the patch without
              worrying, in addition automatic creation of patches with for example
              gitweb will be possible. Merely the offset will increase by 4 every time
              an extra patch is applied, but it will increase in any case because of
              the normal patches.

              > So that the context doesn't contain anything of another patch that was
              > applied.

              However, when merging various patches as it's done in vim_extended.git,
              conflicts with extra_patches[] are unavoidable because a version control
              system always knows more about the sources than the patch tool with
              three context lines.

              But because it's nice to have the patch names listed, these trivial
              merge conflicts are acceptable, I think.

              Markus


              --~--~---------~--~----~------------~-------~--~----~
              You received this message from the "vim_dev" maillist.
              For more information, visit http://www.vim.org/maillist.php
              -~----------~----~----~----~------~----~------~--~---
            • Tony Mechelynck
              ... It depends on your compiler, which, in turn, depends on your OS: on Unix-like systems one should use gcc with the top-level Makefile; on Windows you can
              Message 6 of 16 , Dec 2, 2008
              • 0 Attachment
                On 02/12/08 05:34, Bill McCarthy wrote:
                > On Sun 30-Nov-08 4:47pm -0600, Tony Mechelynck wrote:
                >
                >> On 30/11/08 12:53, Bram Moolenaar wrote:
                >>> Patch 7.2.058
                >>> Problem: Can't add a patch name to the ":version" output.
                >>> Solution: Add the extra_patches array.
                >>> Files: src/version.c
                >
                >> Nice new feature :-). However, unlike the "Modified by" line and the
                >
                > How do you get that "Modified by" to work? There doesn't
                > appear to be anything to modify in the "make" line.
                >

                It depends on your compiler, which, in turn, depends on your OS: on
                Unix-like systems one should use gcc with the top-level Makefile; on
                Windows you can use Cygwin gcc, MinGW gcc, Borland BCC32, Microsoft
                Visual C/C++, and maybe others, each with its own makefile among the
                various src/Make_*.mak; it also depends on how you configure Vim.

                I used until a short time ago the line

                export CONF_ARGS='--with-modified-by="Bill McCarthy (float)"'

                in the file which I have bash source (not run) before running Vim make.
                Since the above patch came out I have, as you know, taken advantage of
                it instead.

                See lines 316-317 of vim72/src/Makefile

                To regenerate the config cache and recompile immediately, use (only on
                Unix-like platforms) "make reconfig". It can be run in the top-level
                Makefile, which will pass it to src/Makefile.


                On Windows, you may have to check the particular makefile for your
                compiler, and maybe search
                /modif
                There may or may not be a make variable for it; if there isn't (but, I
                suppose, only if there isn't) you may uncomment (and edit) line 974 of
                src/feature.h (which is the file where most of the user-selectable
                features can be enabled or disabled).

                See also:
                (U*x) http://users.skynet.be/antoine.mechelynck/vim/compunix.htm
                (W32) http://users.skynet.be/antoine.mechelynck/vim/compile.htm

                which show how to set the most commonly used make variables when
                compiling Vim. For lesser variables you may have to check the particular
                makefile you use for which particular names and values to use. I
                recommend not to modify the makefile but to set the variables either on
                the make command-line (where on the command line depends on your
                particular version of make) or in the environment, as shown in the above
                howto pages.


                Best regards,
                Tony.
                --
                Bizoos, n.:
                The millions of tiny individual bumps that make up a
                basketball.
                -- Rich Hall, "Sniglets"

                --~--~---------~--~----~------------~-------~--~----~
                You received this message from the "vim_dev" maillist.
                For more information, visit http://www.vim.org/maillist.php
                -~----------~----~----~----~------~----~------~--~---
              • Bill McCarthy
                ... Thanks for all your suggestions. I ve tried all kinds of ways to add from the top - parameters to the make file like I have now. Nothing worked :-( I
                Message 7 of 16 , Dec 2, 2008
                • 0 Attachment
                  On Tue 2-Dec-08 6:16pm -0600, Tony Mechelynck wrote:

                  > On 02/12/08 05:34, Bill McCarthy wrote:

                  >>> Nice new feature :-). However, unlike the "Modified by" line and the

                  >> How do you get that "Modified by" to work? There doesn't
                  >> appear to be anything to modify in the "make" line.

                  Thanks for all your suggestions. I've tried all kinds of
                  ways to add from the top - parameters to the make file like
                  I have now. Nothing worked :-(

                  I even tried to directly modify Make_ming.mak by physically
                  adding: -DMODIFIED_BY=\"My Stuff\"

                  Nothing worked - version.c wouldn't compile.

                  --
                  Best regards,
                  Bill


                  --~--~---------~--~----~------------~-------~--~----~
                  You received this message from the "vim_dev" maillist.
                  For more information, visit http://www.vim.org/maillist.php
                  -~----------~----~----~----~------~----~------~--~---
                • Tony Mechelynck
                  ... Modified by is not in version.c but in feature.h. Since apparently Make_ming.mak has no option to set that line, you should edit feature.h manually, as I
                  Message 8 of 16 , Dec 3, 2008
                  • 0 Attachment
                    On 03/12/08 05:54, Bill McCarthy wrote:
                    > On Tue 2-Dec-08 6:16pm -0600, Tony Mechelynck wrote:
                    >
                    >> On 02/12/08 05:34, Bill McCarthy wrote:
                    >
                    >>>> Nice new feature :-). However, unlike the "Modified by" line and the
                    >
                    >>> How do you get that "Modified by" to work? There doesn't
                    >>> appear to be anything to modify in the "make" line.
                    >
                    > Thanks for all your suggestions. I've tried all kinds of
                    > ways to add from the top - parameters to the make file like
                    > I have now. Nothing worked :-(
                    >
                    > I even tried to directly modify Make_ming.mak by physically
                    > adding: -DMODIFIED_BY=\"My Stuff\"
                    >
                    > Nothing worked - version.c wouldn't compile.
                    >

                    "Modified by" is not in version.c but in feature.h. Since apparently
                    Make_ming.mak has no option to set that line, you should edit feature.h
                    manually, as I said. (Didn't you get my reply to your former post asking
                    how to set it?

                    Best regards,
                    Tony.
                    --
                    ... [concerning quotation marks] even if we *did* quote anybody in this
                    business, it probably would be gibberish.
                    -- Thom McLeod

                    --~--~---------~--~----~------------~-------~--~----~
                    You received this message from the "vim_dev" maillist.
                    For more information, visit http://www.vim.org/maillist.php
                    -~----------~----~----~----~------~----~------~--~---
                  • Bill McCarthy
                    ... I read it, Tony, and I know that MODIFIED_BY is usually defined in feature.h. That #define (currently not done) is used by version.c to create the
                    Message 9 of 16 , Dec 7, 2008
                    • 0 Attachment
                      On Wed 3-Dec-08 3:07pm -0600, Tony Mechelynck wrote:

                      >
                      > On 03/12/08 05:54, Bill McCarthy wrote:
                      >> On Tue 2-Dec-08 6:16pm -0600, Tony Mechelynck wrote:
                      >>
                      >>> On 02/12/08 05:34, Bill McCarthy wrote:
                      >>
                      >>>>> Nice new feature :-). However, unlike the "Modified by" line and the
                      >>
                      >>>> How do you get that "Modified by" to work? There doesn't
                      >>>> appear to be anything to modify in the "make" line.
                      >>
                      >> Thanks for all your suggestions. I've tried all kinds of
                      >> ways to add from the top - parameters to the make file like
                      >> I have now. Nothing worked :-(
                      >>
                      >> I even tried to directly modify Make_ming.mak by physically
                      >> adding: -DMODIFIED_BY=\"My Stuff\"
                      >>
                      >> Nothing worked - version.c wouldn't compile.
                      >>
                      >
                      > "Modified by" is not in version.c but in feature.h. Since apparently
                      > Make_ming.mak has no option to set that line, you should edit feature.h
                      > manually, as I said. (Didn't you get my reply to your former post asking
                      > how to set it?

                      I read it, Tony, and I know that MODIFIED_BY is usually
                      defined in feature.h. That #define (currently not done) is
                      used by version.c to create the message.

                      I know I can add a #define in feature.h. I was trying to do
                      this more high level by changing my invocation of make.

                      BTW, i finally gave up and modified feature.h :-(

                      --
                      Best regards,
                      Bill


                      --~--~---------~--~----~------------~-------~--~----~
                      You received this message from the "vim_dev" maillist.
                      For more information, visit http://www.vim.org/maillist.php
                      -~----------~----~----~----~------~----~------~--~---
                    Your message has been successfully submitted and would be delivered to recipients shortly.