[vim/vim] po/Makefile: Avoid race over LINGUAS file (PR #10776)

4 views
Skip to first unread message

Richard Purdie

unread,
Jul 24, 2022, 5:36:09 AM7/24/22
to vim/vim, Subscribed

The creation of the LINGUAS file is duplicated for each desktop file
which can lead the commands to race against each other. One target might
remove it before another has been able to use it. Rework the makefile to
avoid this as the expense of leaving the file on disk.

Signed-off-by: Richard Purdie richard...@linuxfoundation.org


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/10776

Commit Summary

  • bfc6d38 po/Makefile: Avoid race over LINGUAS file

File Changes

(1 file)

Patch Links:


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776@github.com>

Bram Moolenaar

unread,
Jul 27, 2022, 1:06:45 PM7/27/22
to vim/vim, Subscribed

Well, after this change it leaves the LINGUAS file behind. The documentation isn't very clear, but it seems that the file can't be given another name, so that we would be able to use a different file in each block.
Any way to delete LINGUAS when done?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776/c1197053622@github.com>

Dominique Pellé

unread,
Jul 27, 2022, 4:25:24 PM7/27/22
to vim/vim, Subscribed

@brammool wrote:

Well, after this change it leaves the LINGUAS file behind.

LINGUAS is removed in the clean target. So I think the change is fine.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776/c1197328906@github.com>

Bram Moolenaar

unread,
Jul 27, 2022, 5:22:17 PM7/27/22
to vim/vim, Subscribed


> @brammool wrote:
>
> > Well, after this change it leaves the LINGUAS file behind.
>
> `LINGUAS` is removed in the `clean` target. So I think the change is fine.

I normally don't type "make clean", as it also deltes the *.mo files.

Perhaps there is a way to make the targets run sequential.
Perhaps by making gvim.desktop depend on vim.desktop.
Or by joining the two blocks.

It's a bit weird that a tool has an input file for which the name can't
be specified.

--
Send $25.00 for handy leaflet on how to make money by selling leaflets

/// Bram Moolenaar -- ***@***.*** -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776/c1197382288@github.com>

Bram Moolenaar

unread,
Jul 28, 2022, 6:22:34 AM7/28/22
to vim...@googlegroups.com, Bram Moolenaar

> > @brammool wrote:
> >
> > > Well, after this change it leaves the LINGUAS file behind.
> >
> > `LINGUAS` is removed in the `clean` target. So I think the change is fine.
>
> I normally don't type "make clean", as it also deltes the *.mo files.
>
> Perhaps there is a way to make the targets run sequential.
> Perhaps by making gvim.desktop depend on vim.desktop.
> Or by joining the two blocks.
>
> It's a bit weird that a tool has an input file for which the name can't
> be specified.

Would it work to add vim.desktop as a dependency on the gvim.desktop
rule? Then vim.desktop must be done before the other, they can't run at
the same time, right?

- gvim.desktop: gvim.desktop.in $(POFILES)
+ gvim.desktop: gvim.desktop.in $(POFILES) vim.desktop


--
If you feel lonely, try schizophrenia.

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\

Bram Moolenaar

unread,
Jul 30, 2022, 3:59:07 PM7/30/22
to vim/vim, Subscribed

Can you check if the problem still exists after the recent change to src/po/Makefile ?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776/c1200285226@github.com>

Richard Purdie

unread,
Sep 1, 2022, 11:14:19 AM9/1/22
to vim/vim, Subscribed

We haven't seen the issue again since that change so I think we're good, thanks!


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776/c1234421170@github.com>

Richard Purdie

unread,
Sep 1, 2022, 11:14:21 AM9/1/22
to vim/vim, Subscribed

Closed #10776.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10776/issue_event/7306261434@github.com>

Reply all
Reply to author
Forward
0 new messages