<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
for longer term solution submit a patch upstream. you might want to
check the optimization flag because some applications don't run
well/have runtime issues with some flags. In those cases you don't
want to override them. (I have at least one package with that
issue.)<br>
Regards Tim<br>
<br>
<div class="moz-cite-prefix">On 23/04/2022 05:53, Brandon Pribula
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAC3J=Zab0+3BqUDbAnuPEHjdSBJPJRN063rKvhnKw62dr7mvfg@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="auto">Hi,<br>
<br>
I have a situation with an application I'm packaging. The CFLAGS
variable, et al in <a href="http://config.mk"
moz-do-not-send="true">config.mk</a> can't be prepended.<br>
<br>
CFLAGS = -std=c99 ...<br>
<br>
instead of<br>
<br>
CFLAGS += -std=c99 ...<br>
<br>
so as is I can't prepend $SLKFLAGS to $CFLAGS. It also contains
an optimization flag: -Os which conflicts with Slackware's.<br>
<br>
The solution I came up with is to change '=' to '+='<br>
<br>
sed -i '/CFLAGS/s/=/+=/' <a href="http://config.mk"
moz-do-not-send="true">config.mk</a><br>
<br>
and remove the optimization flag -Os<br>
<br>
sed -i '/CFLAGS/s/-Os//' <a href="http://config.mk"
moz-do-not-send="true">config.mk</a><br>
<br>
This works fine but I would like to know if there is a more
preferable solution with a slackbuild.
<div dir="auto"><br>
</div>
<div dir="auto">Thanks</div>
</div>
<br>
<fieldset class="moz-mime-attachment-header"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
SlackBuilds-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:SlackBuilds-users@slackbuilds.org">SlackBuilds-users@slackbuilds.org</a>
<a class="moz-txt-link-freetext" href="https://lists.slackbuilds.org/mailman/listinfo/slackbuilds-users">https://lists.slackbuilds.org/mailman/listinfo/slackbuilds-users</a>
Archives - <a class="moz-txt-link-freetext" href="https://lists.slackbuilds.org/pipermail/slackbuilds-users/">https://lists.slackbuilds.org/pipermail/slackbuilds-users/</a>
FAQ - <a class="moz-txt-link-freetext" href="https://slackbuilds.org/faq/">https://slackbuilds.org/faq/</a>
</pre>
</blockquote>
<br>
<div id="DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2">
<br /><br />
<hr style='border:none; color:#909090; background-color:#B0B0B0; height: 1px; width: 99%;' />
<table style='border-collapse:collapse;border:none;'>
<tr>
<td style='border:none;padding:0px 15px 0px 8px'>
<a href="https://www.avg.com/internet-security">
<img border=0 src="https://static.avast.com/emails/avg-mail-stamp.png" alt="AVG logo" />
</a>
</td>
<td>
<p style='color:#3d4d5a; font-family:"Calibri","Verdana","Arial","Helvetica"; font-size:12pt;'>
This email has been checked for viruses by AVG antivirus software.
<br><a href="https://www.avg.com/internet-security">www.avg.com</a>
</p>
</td>
</tr>
</table>
<br />
<a href="#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2" width="1" height="1"> </a></div></body>
</html>