[Queue-developers] Queue on Solaris 8: solutions and problems
Brought to you by:
wkrebs
|
From: Henry T. <cc...@uc...> - 2001-10-30 15:59:13
|
Hi all,
I've succeeded in installing and running queue-1.30.1 on a Solaris 8
system (using the native Sun cc compiler), and thought it would be useful
to share the fixes I found necessary. I haven't yet been able to get
queue-1.40.1beta to compile.
1) The main problem with the cc compile on Solaris is the fact that the
compiler flag -Wp,-MD, doesn't work properly. This flag appears in the
Makefile template Makefile.in, e.g.:
$(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
The -Wp part says "pass the following option through to the
pre-processor"... the subsequent part -MD,.<filename> means "generate
a list of the make dependencies of this source file, placing it in
<filename>".
Unfortunately, the Solaris form of this option doesn't seem to work
in the same way. The only way that I've found to generate these
dependencies is to use the COMPILER option -xM, which runs the
pre-processor ONLY, sending the dependencies to standard output.
This means that the single line above needs to be replaced with TWO
lines, one to generate the dependencies, and one to do the compilation,
e.g.:
$(COMPILE) -xM $< > .deps/$(*F).pp
$(COMPILE) -c $<
The diff file for Makefile.in, included below, makes the changes in the
four places necessary.
2) Also in the Makefile, there is a line:
cp doc/queue.man doc/queue.1
This is trying to create a file doc/queue.1 in the queue-1.30.1, which
is in my user area... since the make is run as root, this fails trying
to write to the user area... I notice that Linux seems to let root write
into a user area, regardless of permissions... Solaris does not. I resolved
this by performing the copy separately (under my user account), and deleting
this line from the makefile. The attached diff for Makefile.in also does this
job.
=======start of Makefile.in diff========
416c416,417
< $(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
---
> $(COMPILE) -xM $< > .deps/$(*F).pp
> $(COMPILE) -c $<
425c426,427
< $(LTCOMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
---
> $(LTCOMPILE) -xM $< > .deps/$(*F).pp
> $(LTCOMPILE) -c $<
435c437,438
< $(CXXCOMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
---
> $(CXXCOMPILE) -xM $< > .deps/$(*F).pp
> $(CXXCOMPILE) -c $<
444c447,448
< $(LTCXXCOMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
---
> $(LTCXXCOMPILE) -xMD $< > .deps/$(*F).pp
> $(LTCXXCOMPILE) -c $<
573d576
< cp doc/queue.man doc/queue.1
=======end of Makefile.in diff========
I haven't investigated how to integrate these changes more fully into queue
(or even if this is possible).
3) In queued.c, there is a string which is split over two lines: cc doesn't accept
this. I note that this is fixed in queue-1.40.1beta, but here is my fix for
version 1.30.1:
=======start of queued.c diff========
4713,4714c4713,4714
< merror1("QueueD: Received invalid cookie. In NO_ROOT, COOKIEFILE must be
< the same on all machines! Received cookie: %s\n",tmpcookie); goto abort;
---
> merror1("QueueD: Received invalid cookie. In NO_ROOT, COOKIEFILE must be \
> the same on all machines! Received cookie: %s\n",tmpcookie); goto abort;
=======end of queued.c diff========
4) This isn't really an error, but I found it useful to redirect the "system"
mail generated by queue to somewhere other than root... in our networked
environment this is not a specific enough destination. During investigations,
I re-directed this mail to my own account (ccaahot), with the following fix
to configure:
=======start of configure diff========
4234c4234,4235
< MIUSER=\"${OWNER}\"
---
> # MIUSER=\"${OWNER}\"
> MIUSER=\"ccaahot\"
=======end of configure diff========
With these fixes, queue seems to work OK on my Solaris 8 machine (a SunBlade 100),
though I haven't done exhaustive tests yet.
I hope this info is of use to someone
cheers
Henry
=====================================================================
Henry Tillotson e-mail: h.t...@uc...
User Support phone: 020 7679 7827
Information Systems fax: 020 7388 5406
University College London, Gower Street, London WC1 E 6BT
=====================================================================
|