Bug 24643 - [patch] build failed on smp system: No rule to make target `exports.c'
Summary: [patch] build failed on smp system: No rule to make target `exports.c'
Status: CLOSED FIXED
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: Build (show other bugs)
Version: 2.0.48
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
URL:
Keywords: PatchAvailable
Depends on:
Blocks:
 
Reported: 2003-11-12 12:41 UTC by Sviatoslav Sviridov
Modified: 2004-11-16 19:05 UTC (History)
0 users



Attachments
unfixes for server/Makefile.in (1.34 KB, patch)
2003-12-02 15:16 UTC, Joe Orton
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sviatoslav Sviridov 2003-11-12 12:41:02 UTC
On SMP systems build can fail because of not full dependencies in Makefile with
next error:

gawk -f /home/svd/RPM/BUILD/httpd-2.0.48/build/make_var_export.awk `cat
export_files` > export_vars.h
make[2]: *** No rule to make target `exports.c', needed by `httpd.exp'.  Stop.

To fix it I'm using this patch:

--- httpd-2.0.48/server/Makefile.in~    2003-03-11 17:41:55 +0200
+++ httpd-2.0.48/server/Makefile.in     2003-11-12 13:57:18 +0200
@@ -64,6 +64,8 @@
 $(top_builddir)/server/exports.c: export_files
        $(AWK) -f $(top_srcdir)/build/make_exports.awk `cat $?` > $@
 
+exports.c: $(top_builddir)/server/exports.c
+
 export_vars.h: export_files
        $(AWK) -f $(top_srcdir)/build/make_var_export.awk `cat $?` > $@
Comment 1 Jeff Trawick 2003-11-12 20:34:10 UTC
What's the issue with SMP systems?  Do you mean that the box where it failed is
SMP?  What commands are you using to build Apache?  What Linux is it?
Comment 2 Joe Orton 2003-11-12 21:05:44 UTC
It fails with a parallel make i.e. make -j2 with GNU make... HEAD has this change:

# Needed to allow exports.c to be generated in a parallel build successfully
.NOTPARALLEL: $(top_builddir)/server/exports.c

I'm not sure whether this is really needed or whether the paths to exports.c
just need to be fixed to be either absolute or not all through that Makefile, it
seems confused.
Comment 3 Sviatoslav Sviridov 2003-11-13 10:17:35 UTC
Sorry for not very accurate report,
yes, it fails when make satrted as "make -j2".

And it seems that adding

.NOTPARALLEL: $(top_builddir)/server/exports.c

also helps. I hope, it's better solution. I'm not so experienced in Makefiles,
so I think you'll do it better than me.
Thanks.
Comment 4 Joe Orton 2003-12-02 15:16:14 UTC
Created attachment 9357 [details]
unfixes for server/Makefile.in
Comment 5 Joe Orton 2003-12-02 15:21:27 UTC
Attached what looks like the right fix to me (for HEAD); awaiting review before
committing.
Comment 6 Joe Orton 2004-01-12 14:31:50 UTC
Fixed for 2.0.49 - thanks for the report.