History Report a problem
Article Edit this page Discussion

Parallel make patch

From Sawfish

Jump to: navigation, search
Browse all patches

[edit] Author

Harald van Dijk

[edit] Synopsis

This patch fixes the parallel build bug that can result in:

(compiling sawfish/wm/commands/x-cycle.jl)
error--> (file-error "No such file or directory" "sawfish/wm/util/x")

When make is run with -j2 (or higher), it's possible that src/fake-libexec gets executed before the targets of the symbolic links it is supposed to create exist. src/.libexec will be incomplete if this happens, and make fails in lisp. This patch tells make to not run src/fake-libexec before the build is ready.

[edit] Patch testing

  1. Copy/paste the patch listed below into some file, eg. TEST.diff.
  2. If you don't have sawfish sources yet, then make a fresh checkout:
    svn checkout svn://svn.gnome.org/svn/sawfish/trunk
  3. Go into the directory where sawfish sources reside, eg. cd trunk
  4. Test if the patch applies cleanly with this command:
    patch -p1 --ignore-whitespace --dry-run < TEST.diff
    in case of problems try also: -p0 or -p2
  5. If it applies cleanly, then remove the --dry-run from above command and run it again, otherwise ask on the mailing list.
  6. Compile sawifsh with those instructions or with those: autogen.sh ; make
  7. Install it for testing, but it depends on your linux distribution.
    1. It is always better to install sawfish as your distribution package, but it is different for each distribution.
    2. So you may try make install, which will install sawifish in /usr/local/share/sawfish/ (if you have write access). But then make sure that you run the correct version and delete it from that directory afterwards, to avoid any conflicts.

PS: edit this template if you feel that those instructions can be improved.

[edit] Patch

--- sawfish/src/Makefile.in
+++ sawfish/src/Makefile.in
@@ -88,7 +88,7 @@
 	$(SHELL) $< $(DESTDIR)$(bindir) $(DESTDIR)$(repexecdir)/sawfish \
 	  $(foreach x,$(DL_DIRS),$(DESTDIR)$(sawfishexecdir)/$(x))
 
-.libexec :
+.libexec : $(DL_OBJS)
 	$(SHELL) $(srcdir)/fake-libexec
 
 clean :

[edit] Community's reasons for inclusion or rejection

Patch submitters, please vote also! Yes, obviosuly your vote will be positive, but it's the place to give your explanation why this patch is good for all Sawfish users, and why it is correct - good reasons for inclusion.

When voting anonymously please write your name, so that it can be associated with your posts on the mailing list. If you are logged in you can sign yourself by typing four tilda characters: ~~~~.

  • Image:Yes.png vote: yes. Looks reasonable. Apparently fake-libexec takes a directory listing of .libs, so there is a dependency on any files created there. Those files are not make targets, but making $(DL_OBJS) causes them to be created as a side effect of libtool. It is a bit ugly to rely on that, but simplicity speaks for the presented solution. Tkorvola 10:19, 2 March 2008 (UTC)

Rate this article:

Share this article:

Hubs Highlights International Sites Wikia messages
Entertainment
Gaming
Cartoons & Comics
Science Fiction
Hobbies
Sports
See all...
Grand Theft Auto
Pixar
Legend of Zelda Wiki
Terminator Wiki
Everquest II Wiki
One Piece
German
Spanish
Chinese
Japanese
More...
Wikia is hiring for several open positions
Send this article to a friend
"Parallel make patch"
 
 
Hi!

I thought you'd like this page from Wikia!

http://sawfish.wikia.com

Come check it out!
Send confirmation