useful bug reports (was: [Patch] Re: compile not copied? Why?)

2005-11-14 Thread Ralf Wildenhues
Hi Harald,

* Harald Dunkel wrote on Sun, Nov 13, 2005 at 06:44:12PM CET:
 Ralf Wildenhues wrote:
  
  Please consider this thread:
  http://lists.gnu.org/archive/html/libtool/2005-10/msg00069.html
 
 How is this thread related to copying a missing script?

It shows that your patch is not enough, for the issue I presumed your
report was about.

 Please note that C support is broken, too, as soon as there is some
 C++ code in your Makefile.am.

Harald, please consider *providing more and useful information* if you
want help.  I for one can't read your mind, and almost every first post
of yours leaves me wanting for a crystal ball as to what has gone wrong.
This makes me for one be less and less enthusiastic about replying.
With newbies, or people where I do not know whether they are newbies or
not, one cannot expect more, at least the first couple of times they
post.  But you bee given hints before.  This is no service hotline.
I heartily recommend reading this (available in several languages):
http://www.chiark.greenend.org.uk/~sgtatham/bugs.html

We have now again wasted 5 messages without getting to the point of the
problem you encounter: I still have no clue what's going wrong on your
side, and I bet you aren't happy about the situation either.

This example setup does not expose your bug:

mkdir sub
touch sub/a.c sub/b.cc
cat configure.ac EOF
AC_INIT([compile-issue],[1],[devnull])
AM_INIT_AUTOMAKE([foreign subdir-objects])
AC_PROG_CC
AM_PROG_CC_C_O
AC_PROG_CXX
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
EOF
cat Makefile.am EOF
bin_PROGRAMS = foo
foo_SOURCES = sub/a.c sub/b.cc
EOF
autoreconf -vi

| [...]
| autoreconf: running: automake --add-missing --copy --no-force
| configure.ac:4: installing `./compile'

So, what really is the problem, and how can it be exposed, 
and with which software versions?

Cheers,
Ralf




[Patch] Re: compile not copied? Why?

2005-11-13 Thread Harald Dunkel
Hi folks,

Harald Dunkel wrote:
 Hi folks,
 
 What is the criteria for copying the compile script into
 the source directory tree? I have some *.cc code, it is
 mentioned in my Makefile.am file, configure detects that
 the compile script must be used, too, but Automake doesn't
 provide it.
 

It seems that the compile script is only copied, if you have
C code only. As soon as you have C++ code in your Makefile.am
(with or without C code), compile is not copied into the
source tree anymore. This breaks support for MSVC.

Below you can find a patch.


Regards

Harri
--
diff -urN automake-1.9.6.orig/automake.in automake-1.9.6/automake.in
--- automake-1.9.6.orig/automake.in 2005-06-30 23:17:13.0 +0200
+++ automake-1.9.6/automake.in  2005-11-07 15:58:49.0 +0100
@@ -1138,7 +1138,7 @@
my $output_flag = $lang-output_flag || '';
$output_flag = '-o'
  if (! $output_flag
-  $lang-name eq 'c'
+  ($lang-name eq 'c' || $lang-name eq 'cxx')
   option 'subdir-objects');

# Compute a possible derived extension.
@@ -1599,7 +1599,7 @@
 $object = $dname . '-' . $object;

 require_conf_file ($am_file.am, FOREIGN, 'compile')
-if $lang-name eq 'c';
+if $lang-name eq 'c' || $lang-name eq 'cxx';

prog_error ($lang-name .  flags defined without compiler)
  if ! defined $lang-compile;




Re: [Patch] Re: compile not copied? Why?

2005-11-13 Thread Ralf Wildenhues
Hi Harald,

* Harald Dunkel wrote on Sun, Nov 13, 2005 at 12:00:18PM CET:
 Harald Dunkel wrote:
  
  What is the criteria for copying the compile script into
  the source directory tree? I have some *.cc code, it is
  mentioned in my Makefile.am file, configure detects that
  the compile script must be used, too, but Automake doesn't
  provide it.
 
 It seems that the compile script is only copied, if you have
 C code only. As soon as you have C++ code in your Makefile.am
 (with or without C code), compile is not copied into the
 source tree anymore. This breaks support for MSVC.
 
 Below you can find a patch.

Please consider this thread:
http://lists.gnu.org/archive/html/libtool/2005-10/msg00069.html

Cheers,
Ralf




Re: [Patch] Re: compile not copied? Why?

2005-11-13 Thread Harald Dunkel
Ralf Wildenhues wrote:
 Hi Harald,
 
 
 Please consider this thread:
 http://lists.gnu.org/archive/html/libtool/2005-10/msg00069.html
 

How is this thread related to copying a missing script? Please
note that C support is broken, too, as soon as there is some
C++ code in your Makefile.am.


Regards

Harri