make distclean

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

make distclean

Juergen Sauermann
Hi,

I have received a bug-report saying that 'make distclean' fails for GNU APL.

The error message is this:

make[2]: Entering directory `/home/eedjsa/projects/juergen/apl-1.5/src'
Makefile:837: .deps/apl-Archive.Po: No such file or directory
Makefile:838: .deps/apl-ArrayIterator.Po: No such file or directory
Makefile:839: .deps/apl-Assert.Po: No such file or directory
Makefile:840: .deps/apl-Avec.Po: No such file or directory
Makefile:841: .deps/apl-Backtrace.Po: No such file or directory
...
Makefile:916: .deps/apl-Workspace.Po: No such file or directory
Makefile:917: .deps/apl-configure_args.Po: No such file or directory
Makefile:918: .deps/apl-main.Po: No such file or directory
Makefile:919: .deps/libapl_la-Archive.Plo: No such file or directory
Makefile:920: .deps/libapl_la-ArrayIterator.Plo: No such file or directory
Makefile:921: .deps/libapl_la-Assert.Plo: No such file or directory
Makefile:922: .deps/libapl_la-Avec.Plo: No such file or directory
Makefile:923: .deps/libapl_la-Backtrace.Plo: No such file or directory
...
Makefile:998: .deps/libapl_la-Workspace.Plo: No such file or directory
Makefile:999: .deps/libapl_la-configure_args.Plo: No such file or directory
Makefile:1000: .deps/libapl_la-libapl.Plo: No such file or directory
make[2]: *** No rule to make target `.deps/libapl_la-libapl.Plo'. Stop.
make[2]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src'
make[1]: *** [distclean-recursive] Error 1
make[1]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src'
make: *** [distclean-recursive] Error 1

----------------------------------------------------------------------------------------------------

 From what I can see:

(1) the libapl related files should not be deleted in the first place .
The Makefile.am (attached) uses:

if WANT_LIBAPL

which is an AM_CONDITIONAL() and the project was NOT ./configure'd to
build libapl

(2) why would 'make distclean' try (and then fail) to build any targets
in the first place?

Shouldn't it just delete files created by ./configure and be happy if
they are gone?

------------------------------------------------------
automake version is 1.14.1
autoconf version is 2.69

The whole project is at http://svn.savannah.gnu.org/viewvc/trunk/?root=apl

Sometimes make distclean works, but I haven't figured when.

Thanks,
Jürgen Sauermann



Makefile.am (7K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: make distclean

Peter Johansson-6
Hi Jürgen,


On 03/18/2016 01:28 AM, Juergen Sauermann wrote:

> Hi,
>
> I have received a bug-report saying that 'make distclean' fails for
> GNU APL.
>
> The error message is this:
>
> make[2]: Entering directory `/home/eedjsa/projects/juergen/apl-1.5/src'
> Makefile:837: .deps/apl-Archive.Po: No such file or directory
> Makefile:838: .deps/apl-ArrayIterator.Po: No such file or directory
> Makefile:839: .deps/apl-Assert.Po: No such file or directory
> Makefile:840: .deps/apl-Avec.Po: No such file or directory
> Makefile:841: .deps/apl-Backtrace.Po: No such file or directory
> ...
> Makefile:916: .deps/apl-Workspace.Po: No such file or directory
> Makefile:917: .deps/apl-configure_args.Po: No such file or directory
> Makefile:918: .deps/apl-main.Po: No such file or directory
> Makefile:919: .deps/libapl_la-Archive.Plo: No such file or directory
> Makefile:920: .deps/libapl_la-ArrayIterator.Plo: No such file or
> directory
> Makefile:921: .deps/libapl_la-Assert.Plo: No such file or directory
> Makefile:922: .deps/libapl_la-Avec.Plo: No such file or directory
> Makefile:923: .deps/libapl_la-Backtrace.Plo: No such file or directory
> ...
> Makefile:998: .deps/libapl_la-Workspace.Plo: No such file or directory
> Makefile:999: .deps/libapl_la-configure_args.Plo: No such file or
> directory
> Makefile:1000: .deps/libapl_la-libapl.Plo: No such file or directory
> make[2]: *** No rule to make target `.deps/libapl_la-libapl.Plo'. Stop.
> make[2]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src'
> make[1]: *** [distclean-recursive] Error 1
> make[1]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src'
> make: *** [distclean-recursive] Error 1
>
> ----------------------------------------------------------------------------------------------------
>
>

Hard to tell what's going on here without seeing the message from 'make
distclean' before the error message.

> From what I can see:
>
> (1) the libapl related files should not be deleted in the first place .

Well, 'make distclean' always deletes directory '.deps' if their's
compilation going on.

> The Makefile.am (attached) uses:
>
> if WANT_LIBAPL
>
> which is an AM_CONDITIONAL() and the project was NOT ./configure'd to
> build libapl
>
> (2) why would 'make distclean' try (and then fail) to build any
> targets in the first place?

It's not trying to build anything. It's trying to remove deps files,
which are created by configure (and usually updated by the compiler).

>
>
> Shouldn't it just delete files created by ./configure and be happy if
> they are gone?
>

Cheers,
Peter


Reply | Threaded
Open this post in threaded view
|

Re: make distclean

Juergen Sauermann
Hi Peter,

thanks for looking into this.

Attached is the full log (shortest way to reproduce the problem.
I could have run 'make all' as well bu the result would be the same.

What puzzles me the most is the message:

make[2]: *** No rule to make target `.deps/libapl_la-libapl.Plo'. Stop.

because why would 'make distclean' even try to make that target?

Thanks,
Jürgen



On 03/18/2016 12:02 AM, Peter Johansson wrote:

> Hi Jürgen,
>
>
> On 03/18/2016 01:28 AM, Juergen Sauermann wrote:
>> Hi,
>>
>> I have received a bug-report saying that 'make distclean' fails for
>> GNU APL.
>>
>> The error message is this:
>>
>> make[2]: Entering directory `/home/eedjsa/projects/juergen/apl-1.5/src'
>> Makefile:837: .deps/apl-Archive.Po: No such file or directory
>> Makefile:838: .deps/apl-ArrayIterator.Po: No such file or directory
>> Makefile:839: .deps/apl-Assert.Po: No such file or directory
>> Makefile:840: .deps/apl-Avec.Po: No such file or directory
>> Makefile:841: .deps/apl-Backtrace.Po: No such file or directory
>> ...
>> Makefile:916: .deps/apl-Workspace.Po: No such file or directory
>> Makefile:917: .deps/apl-configure_args.Po: No such file or directory
>> Makefile:918: .deps/apl-main.Po: No such file or directory
>> Makefile:919: .deps/libapl_la-Archive.Plo: No such file or directory
>> Makefile:920: .deps/libapl_la-ArrayIterator.Plo: No such file or
>> directory
>> Makefile:921: .deps/libapl_la-Assert.Plo: No such file or directory
>> Makefile:922: .deps/libapl_la-Avec.Plo: No such file or directory
>> Makefile:923: .deps/libapl_la-Backtrace.Plo: No such file or directory
>> ...
>> Makefile:998: .deps/libapl_la-Workspace.Plo: No such file or directory
>> Makefile:999: .deps/libapl_la-configure_args.Plo: No such file or
>> directory
>> Makefile:1000: .deps/libapl_la-libapl.Plo: No such file or directory
>> make[2]: *** No rule to make target `.deps/libapl_la-libapl.Plo'. Stop.
>> make[2]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src'
>> make[1]: *** [distclean-recursive] Error 1
>> make[1]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src'
>> make: *** [distclean-recursive] Error 1
>>
>> ----------------------------------------------------------------------------------------------------
>>
>>
>
> Hard to tell what's going on here without seeing the message from
> 'make distclean' before the error message.
>
>> From what I can see:
>>
>> (1) the libapl related files should not be deleted in the first place .
>
> Well, 'make distclean' always deletes directory '.deps' if their's
> compilation going on.
>
>> The Makefile.am (attached) uses:
>>
>> if WANT_LIBAPL
>>
>> which is an AM_CONDITIONAL() and the project was NOT ./configure'd to
>> build libapl
>>
>> (2) why would 'make distclean' try (and then fail) to build any
>> targets in the first place?
>
> It's not trying to build anything. It's trying to remove deps files,
> which are created by configure (and usually updated by the compiler).
>
>>
>>
>> Shouldn't it just delete files created by ./configure and be happy if
>> they are gone?
>>
>
> Cheers,
> Peter
>
>


Xterm.log.server66.2016.03.18.12.24.41.2894 (33K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: make distclean

Mike Miller
On Fri, Mar 18, 2016 at 12:36:13 +0100, Juergen Sauermann wrote:
> Attached is the full log (shortest way to reproduce the problem.
> I could have run 'make all' as well bu the result would be the same.
>
> What puzzles me the most is the message:
>
> make[2]: *** No rule to make target `.deps/libapl_la-libapl.Plo'. Stop.
>
> because why would 'make distclean' even try to make that target?

Thanks for the full log, that gives enough information to explain this.

Makefiles include all of the files in .deps (as a make include). Make
treates included files as prerequisites of the makefile itself, so they
need to exist in order for any target to run, including any *clean
targets.

Turns out from your log file that a subdirectory of src is removing the
.deps files in its parent dir:

> make[2]: Entering directory `/home/eedjsa/projects/juergen/apl-1.5/src/APs'
> rm -rf .libs _libs
> rm -f *.o
>  rm -f AP100 AP210 APserver
> rm -f *.lo
> rm -f *.tab.c
> test -z "" || rm -f
> rm -f ../*.o
> rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
> test . = "." || test -z "" || rm -f
> rm -f ../.deps/.dirstamp
> rm -f ../.dirstamp
> rm -rf ../.deps ./.deps
> rm -f Makefile
> make[2]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src/APs'

This is probably why when 'distclean' returns to src, its .deps files
are already removed and the makefile errors out.

Are sources from the parent directory being built in the src/APs subdir
and you're using the 'subdir-objects' option?

--
mike

Reply | Threaded
Open this post in threaded view
|

Re: make distclean

Juergen Sauermann
Hi Mike,

I am not using the subdir-objects option. Should I ?

Also, if I

     ./configure
     make distcleran

then the compiler will not yet have been run.
But your explanation have given me an idea: if I remove the .deps directory
manually then 'make distclean' seems to work again.

Not very nice but at least  work-around.

Thanks,
Jürgen


On 03/18/2016 04:15 PM, Mike Miller wrote:

> On Fri, Mar 18, 2016 at 12:36:13 +0100, Juergen Sauermann wrote:
>> Attached is the full log (shortest way to reproduce the problem.
>> I could have run 'make all' as well bu the result would be the same.
>>
>> What puzzles me the most is the message:
>>
>> make[2]: *** No rule to make target `.deps/libapl_la-libapl.Plo'. Stop.
>>
>> because why would 'make distclean' even try to make that target?
> Thanks for the full log, that gives enough information to explain this.
>
> Makefiles include all of the files in .deps (as a make include). Make
> treates included files as prerequisites of the makefile itself, so they
> need to exist in order for any target to run, including any *clean
> targets.
>
> Turns out from your log file that a subdirectory of src is removing the
> .deps files in its parent dir:
>
>> make[2]: Entering directory `/home/eedjsa/projects/juergen/apl-1.5/src/APs'
>> rm -rf .libs _libs
>> rm -f *.o
>>   rm -f AP100 AP210 APserver
>> rm -f *.lo
>> rm -f *.tab.c
>> test -z "" || rm -f
>> rm -f ../*.o
>> rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
>> test . = "." || test -z "" || rm -f
>> rm -f ../.deps/.dirstamp
>> rm -f ../.dirstamp
>> rm -rf ../.deps ./.deps
>> rm -f Makefile
>> make[2]: Leaving directory `/home/eedjsa/projects/juergen/apl-1.5/src/APs'
> This is probably why when 'distclean' returns to src, its .deps files
> are already removed and the makefile errors out.
>
> Are sources from the parent directory being built in the src/APs subdir
> and you're using the 'subdir-objects' option?
>