Bug 173576 - [patch] x11/rxvt: Wrong operators in Makefile
Summary: [patch] x11/rxvt: Wrong operators in Makefile
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Eitan Adler
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-12 13:00 UTC by WATANABE Kazuhiro
Modified: 2012-11-13 15:40 UTC (History)
0 users

See Also:


Attachments
file.diff (745 bytes, patch)
2012-11-12 13:00 UTC, WATANABE Kazuhiro
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description WATANABE Kazuhiro 2012-11-12 13:00:00 UTC
The latest commit uses wrong operators in Makefile.
It loses the previous definition of CONFIGURE_ARGS.
See the patch below.

"--disable-utmp" should be combined with "--disable-wtmp".
If not, it occurs a compilation error.

How-To-Repeat: (With the operator's fix and without "--disable-wtmp")
# cd /usr/ports/x11/rxvt
# make BATCH=yes
(snip)
cc -DHAVE_CONFIG_H  -c -DHAVE_LIBXPM -I/usr/local/include -I/usr/local/include/X11  -I. -I.. -I.  -O2 -pipe -fno-strict-aliasing logging.c
logging.c:66: warning: 'struct utmp' declared inside parameter list
logging.c:66: warning: its scope is only this definition or declaration, which is probably not what you want
logging.c: In function 'rxvt_update_wtmp':
logging.c:85: error: invalid application of 'sizeof' to incomplete type 'struct utmp' 
*** Error code 1

Stop in /FreeBSD/ports/x11/rxvt/work/rxvt-2.6.4/src.
*** Error code 1

Stop in /FreeBSD/ports/x11/rxvt/work/rxvt-2.6.4.
*** Error code 1

Stop in /FreeBSD/ports/x11/rxvt.
#
Comment 1 Eitan Adler freebsd_committer freebsd_triage 2012-11-13 00:58:15 UTC
Responsible Changed
From-To: freebsd-ports-bugs->eadler

I'll take it.
Comment 2 Eitan Adler freebsd_committer freebsd_triage 2012-11-13 01:06:34 UTC
State Changed
From-To: open->closed

committed, sorry I forgot to include the PR number and submitter name in 
the commit message :(
Comment 3 WATANABE Kazuhiro 2012-11-13 12:59:33 UTC
Hello.

Thanks for your work!  But a major problem still remains.
(fixed manually?)

Now x11/rxvt/Makefile has the following lines:

| CONFIGURE_ARGS=	--enable-ttygid \
| 		--with-xpm --enable-xpm-background \
| 		--with-xpm-includes=${LOCALBASE}/include/X11 \
| 		--with-xpm-library=${LOCALBASE}/lib
| MAN1=		rxvt.1
| PLIST_FILES=	bin/rxvt
| 
| MAKE_JOBS_SAFE=	yes
| 
| .include <bsd.port.pre.mk>
| 
| # fails to build with new utmpx
| .if ${OSVERSION} > 900007
| CONFIGURE_ARGS=	--disable-utmp --disable-wtmp
| .else
| CONFIGURE_ARGS=	--enable-utmp --enable-wtmp
| .endif

First, plenty of configure options are assigned to a CONFIGURE_ARGS
variable.

And then the .if-.endif conditional uses "CONFIGURE_ARGS=".  In this
case, the first value of CONFIGURE_ARGS variable is completely
deleted.  It loses a lot of XPM-related configure options; therefore
rxvt's "background image" feature has been lost.

In the conditional, we should use "CONFIGURE_ARGS+=" instead of
"CONFIGURE_ARGS=".  Please see my original patch.

Sorry for my bad explanation and english...

At Tue, 13 Nov 2012 01:06:35 GMT,
eadler@FreeBSD.org wrote:
> Synopsis: [patch] x11/rxvt: Wrong operators in Makefile
> 
> State-Changed-From-To: open->closed
> State-Changed-By: eadler
> State-Changed-When: Tue Nov 13 01:06:34 UTC 2012
> State-Changed-Why: 
> committed, sorry I forgot to include the PR number and submitter name in
> the commit message :(
Don't mind :-)

> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=173576
---
WATANABE Kazuhiro (CQG00620@nifty.ne.jp)
Comment 4 Eitan Adler freebsd_committer freebsd_triage 2012-11-13 15:39:18 UTC
On 13 November 2012 07:59, WATANABE Kazuhiro <CQG00620@nifty.ne.jp> wrote:
> Hello.
>
> Thanks for your work!  But a major problem still remains.
> (fixed manually?)

The patch in the PR didn't apply so I fixed it manually.  Obviously
I missed something.

> In the conditional, we should use "CONFIGURE_ARGS+=" instead of
> "CONFIGURE_ARGS=".  Please see my original patch.

Okay. I shall fix shortly.

> Sorry for my bad explanation and english...

Your explanation and English is perfectly fine.


-- 
Eitan Adler
Source, Ports, Doc committer
Bugmeister, Ports Security teams