Bug 277961 - x11-wm/libwraster: fail to build with portmaster: gmake error: : invalid option -- D
Summary: x11-wm/libwraster: fail to build with portmaster: gmake error: : invalid opti...
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: Hiroki Sato
URL:
Keywords:
Depends on: 281732
Blocks:
  Show dependency treegraph
 
Reported: 2024-03-25 22:11 UTC by O. Hartmann
Modified: 2025-08-11 16:12 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (hrs)


Attachments
fix build (683 bytes, patch)
2024-03-25 22:11 UTC, O. Hartmann
no flags Details | Diff
Fix traditional make in portstree (670 bytes, patch)
2025-08-03 11:45 UTC, O. Hartmann
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description O. Hartmann 2024-03-25 22:11:29 UTC
Created attachment 249487 [details]
fix build

On recent CURRENT, building port x11-wm/libwraster fails with error

[...]
gmake
: invalid option -- D

The attached patch fixes build.
Comment 1 O. Hartmann 2024-04-03 16:35:51 UTC
The reported problem occurs while using ports-mgmt/portmaster
Comment 2 Chad Jacob Milios 2024-06-19 12:28:04 UTC
i think you ought to throw a ${WRK_ENV} in there between ${SETENVI} and ${MAKE_ENV}, for good measure, even though it doesn't seem strictly necessary in this case. am i wrong? i'm just going by CHANGES:20240229

https://cgit.freebsd.org/ports/tree/CHANGES?id=f4ec56fe7b087557686a786e13d07eaf0ee882df#n30
Comment 3 Chad Jacob Milios 2024-06-19 13:06:53 UTC
it looks like the portmaster port punted this problem *for now* in this commit:

https://cgit.freebsd.org/ports/commit/?id=755d190db121778a25b45950c397163325d8e797

but please dont just close this PR as "overcome by events"

i still think we ought to root out as many as we can from the ports tree of these unmitigated calls with a potentially filthy environment. please spare me the 'just use poodreeay' because while that is a valid stance for many there's nothing wrong with working toward a more perfect ports tree ALSO. dont shy away from the -D

i like the SETENVI work done in Mk/Uses and it'd be nice if we continue to improve as many ports as we can using this improved practice. i will be filling about a dozen PRs with patches today, unless someone would please quick point me to an ongoing encompassing PR# or DR#.

what can i say? i like lots of -D in my life. i cant get enough -D. -DTHIS, -DTHAT...and please don't tell me just to THIS=1 THAT=1; it only masks the problem of liabilities which we ought to be ever vigilant to address and correct in the most robust ways practical
Comment 4 O. Hartmann 2025-08-03 11:41:50 UTC
(In reply to Chad Jacob Milios from comment #3)

This port is one of the rare left-overs not working properly with a traditional "make". So, I followed your advice and changes the patch accoridngly, adding

${SETENVI} ${WRK_ENV} ...

A simple 

${SETENVI} ...

does alos do the job.

I will replace the patch immediately.
Comment 5 O. Hartmann 2025-08-03 11:45:16 UTC
Created attachment 262662 [details]
Fix traditional make in portstree

This patch fixes a misbehaviour while performing a traditional "make -C /usr/ports/x11-em/libwraster which results in the error shown in the initial PR. The patch also contains a consideration of the former poster's comment.
Comment 6 O. Hartmann 2025-08-11 16:12:34 UTC
Can someone check and commit, please?