unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Generating byteswap.h on Windows
@ 2013-10-04  9:59 martin rudalics
  2013-10-04 10:54 ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: martin rudalics @ 2013-10-04  9:59 UTC (permalink / raw)
  To: emacs-devel

To avoid a trunk build failure on Windows like

data.c:24:22: fatal error: byteswap.h: No such file or directory
compilation terminated.
make[1]: *** [data.o] Error 1
make[1]: Leaving directory `/c/emacs/trunk/src'
make: *** [src] Error 2

apply the patch below Paul sent me this morning.
I leave it to Eli to install it.

martin

=== modified file 'nt/gnulib.mk'
--- nt/gnulib.mk	2013-07-07 18:00:14 +0000
+++ nt/gnulib.mk	2013-10-04 08:35:33 +0000
@@ -78,6 +78,29 @@

  ## end   gnulib module alloca-opt

+## begin gnulib module byteswap
+
+BUILT_SOURCES += $(BYTESWAP_H)
+
+# We need the following in order to create <byteswap.h> when the system
+# doesn't have one.
+if GL_GENERATE_BYTESWAP_H
+byteswap.h: byteswap.in.h $(top_builddir)/config.status
+	$(AM_V_GEN)rm -f $@-t $@ && \
+	{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
+	  cat $(srcdir)/byteswap.in.h; \
+	} > $@-t && \
+	mv -f $@-t $@
+else
+byteswap.h: $(top_builddir)/config.status
+	rm -f $@
+endif
+MOSTLYCLEANFILES += byteswap.h byteswap.h-t
+
+EXTRA_DIST += byteswap.in.h
+
+## end   gnulib module byteswap
+
  ## begin gnulib module c-ctype

  libgnu_a_SOURCES += c-ctype.h c-ctype.c





^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Generating byteswap.h on Windows
  2013-10-04  9:59 Generating byteswap.h on Windows martin rudalics
@ 2013-10-04 10:54 ` Eli Zaretskii
  2013-10-04 12:47   ` martin rudalics
  0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2013-10-04 10:54 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel

> Date: Fri, 04 Oct 2013 11:59:02 +0200
> From: martin rudalics <rudalics@gmx.at>
> 
> To avoid a trunk build failure on Windows like
> 
> data.c:24:22: fatal error: byteswap.h: No such file or directory
> compilation terminated.
> make[1]: *** [data.o] Error 1
> make[1]: Leaving directory `/c/emacs/trunk/src'
> make: *** [src] Error 2
> 
> apply the patch below Paul sent me this morning.
> I leave it to Eli to install it.

Why leave it to me?  Please install whatever changes you find that fix
any breakage.



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Generating byteswap.h on Windows
  2013-10-04 10:54 ` Eli Zaretskii
@ 2013-10-04 12:47   ` martin rudalics
  2013-10-04 14:09     ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: martin rudalics @ 2013-10-04 12:47 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel

 > Why leave it to me?

Because as a rule I only install changes I understand and I don't
understand makefiles.  Moreover I now have byteswap.h in my lib
directory and according to bzr status I would commit that too.  So I'd
also have to learn how to avoid that.

 > Please install whatever changes you find that fix
 > any breakage.

If you can't commit I can do it but at least give me some sort of
approval first that Paul's patch is correct.

martin



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Generating byteswap.h on Windows
  2013-10-04 12:47   ` martin rudalics
@ 2013-10-04 14:09     ` Eli Zaretskii
  2013-10-04 14:33       ` martin rudalics
  0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2013-10-04 14:09 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel

> Date: Fri, 04 Oct 2013 14:47:38 +0200
> From: martin rudalics <rudalics@gmx.at>
> CC: emacs-devel@gnu.org
> 
>  > Why leave it to me?
> 
> Because as a rule I only install changes I understand and I don't
> understand makefiles.

If the build was broken, and your change fixes it, the fix is worth
installing, so that others could build successfully.  We can always
improve the fix later, if needed.

IOW, installing a fix can never make things worse than they are when
the build is broken.

> Moreover I now have byteswap.h in my lib directory and according to
> bzr status I would commit that too.  So I'd also have to learn how
> to avoid that.

You can "bzr commit" specific files.  But the general rule for this is
add the file to .bzrignore.

>  > Please install whatever changes you find that fix
>  > any breakage.
> 
> If you can't commit I can do it but at least give me some sort of
> approval first that Paul's patch is correct.

You will always have my approval for committing something that fixes a
broken build.  I just don't want that it will always depend on me,
because I'm sometimes busy or unavailable.

Thanks.



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Generating byteswap.h on Windows
  2013-10-04 14:09     ` Eli Zaretskii
@ 2013-10-04 14:33       ` martin rudalics
  2013-10-04 15:45         ` Paul Eggert
  0 siblings, 1 reply; 7+ messages in thread
From: martin rudalics @ 2013-10-04 14:33 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel

> If the build was broken, and your change fixes it, the fix is worth
> installing, so that others could build successfully.  We can always
> improve the fix later, if needed.

It is Paul's fix, not mine.

> IOW, installing a fix can never make things worse than they are when
> the build is broken.

How can I tell whether a build is broken generally or just on my
machine?

> You can "bzr commit" specific files.  But the general rule for this is
> add the file to .bzrignore.

I added it there.

> You will always have my approval for committing something that fixes a
> broken build.  I just don't want that it will always depend on me,
> because I'm sometimes busy or unavailable.

Committed as revision#114521.  Please have a look as soon as you have time.

Thanks, martin




^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Generating byteswap.h on Windows
  2013-10-04 14:33       ` martin rudalics
@ 2013-10-04 15:45         ` Paul Eggert
  2013-10-04 17:55           ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Paul Eggert @ 2013-10-04 15:45 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel

martin rudalics wrote:
> Committed as revision#114521.

Thanks for checking that in.  And sorry about the confusion.
I thought that the recent changes to the Windows build had
decoupled it from minor changes such as the addition of byteswap.h;
evidently I was mistaken.  To avoid similar problems in the future,
perhaps admin/merge-gnulib could be modified to generate nt/gnulib.mk
automatically after lib/gnulib.mk is generated.



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Generating byteswap.h on Windows
  2013-10-04 15:45         ` Paul Eggert
@ 2013-10-04 17:55           ` Eli Zaretskii
  0 siblings, 0 replies; 7+ messages in thread
From: Eli Zaretskii @ 2013-10-04 17:55 UTC (permalink / raw)
  To: Paul Eggert; +Cc: rudalics, emacs-devel

> Date: Fri, 04 Oct 2013 08:45:22 -0700
> From: Paul Eggert <eggert@cs.ucla.edu>
> Cc: emacs-devel@gnu.org
> 
> I thought that the recent changes to the Windows build had
> decoupled it from minor changes such as the addition of byteswap.h;
> evidently I was mistaken.

The decoupling is not 100%, although it comes close.  In addition to
nt/gnulib.mk, sometimes nt/mingw-site.cfg needs tweaking to get the
configure script DTRT for the Windows build.

> To avoid similar problems in the future, perhaps admin/merge-gnulib
> could be modified to generate nt/gnulib.mk automatically after
> lib/gnulib.mk is generated.

I don't know how to automate this, since human judgment is required to
decide whether a given addition to lib/gnulib.mk needs to be copied to
nt/gnulib.mk.  But maybe at least a message with reminder that this
should be considered would be a good thing to add to
admin/merge-gnulib.



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2013-10-04 17:55 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-04  9:59 Generating byteswap.h on Windows martin rudalics
2013-10-04 10:54 ` Eli Zaretskii
2013-10-04 12:47   ` martin rudalics
2013-10-04 14:09     ` Eli Zaretskii
2013-10-04 14:33       ` martin rudalics
2013-10-04 15:45         ` Paul Eggert
2013-10-04 17:55           ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).