Bug 72137 - make clean crashes in x11/nvidia-driver
Summary: make clean crashes in x11/nvidia-driver
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: Alexey Dokuchaev
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-27 23:10 UTC by Michel Lavondes
Modified: 2004-11-09 09:45 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michel Lavondes 2004-09-27 23:10:36 UTC
# cd /usr/ports/x11/nvidia-driver; make clean
"Makefile", line 44: warning: String comparison operator should be either == or !=
"Makefile", line 44: Malformed conditional (${OSVERSION} < 490000 || (${OSVERSION} >= 500000 && ${OSVERSION} < 502001))
"Makefile", line 44: Missing dependency operator
"Makefile", line 46: if-less endif
"Makefile", line 46: Need an operator
make: fatal errors encountered -- cannot continue

Note: this is a near-duplicate of ports/72118, http://www.freebsd.org/cgi/query-pr.cgi?pr=72118

Fix: 

Change line 44 of Makefile from:

.if ${OSVERSION} < 490000 || (${OSVERSION} >= 500000 && ${OSVERSION} < 502001)

to

.if ${OSVERSION} < 490000 || ${OSVERSION} >= 500000 && ${OSVERSION} < 502001

Note: make(1) states that && has higher precedence than ||, so the () shouldn't be necessary. Just to be on the safe side (I don't have the resources to test on other FreeBSD versions), I checked my fix with: 

# make -V OSVERSION
480000
# make -V IGNORE
"supports FreeBSD -STABLE (4.9 or later), or FreeBSD -CURRENT (5.2.1 or later)"
# make -V IGNORE OSVERSION=489999
"supports FreeBSD -STABLE (4.9 or later), or FreeBSD -CURRENT (5.2.1 or later)"
# make -V IGNORE OSVERSION=490000

# make -V IGNORE OSVERSION=499999

# make -V IGNORE OSVERSION=500000
"supports FreeBSD -STABLE (4.9 or later), or FreeBSD -CURRENT (5.2.1 or later)"
# make -V IGNORE OSVERSION=502000
"supports FreeBSD -STABLE (4.9 or later), or FreeBSD -CURRENT (5.2.1 or later)"
# 

I hope I didn't overlook anything.
How-To-Repeat: See above "Full Description"
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2004-09-28 04:20:32 UTC
Responsible Changed
From-To: freebsd-ports-bugs->danfe

Over to maintainer. 

I sure will be glad when everyone has that newer make(1) ...
Comment 2 Alexey Dokuchaev freebsd_committer freebsd_triage 2004-11-09 09:44:33 UTC
State Changed
From-To: open->closed

Fixed, thanks!