From owner-freebsd-ports@FreeBSD.ORG Mon Feb 7 21:40:02 2011 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 051ED106564A for ; Mon, 7 Feb 2011 21:40:02 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-ey0-f182.google.com (mail-ey0-f182.google.com [209.85.215.182]) by mx1.freebsd.org (Postfix) with ESMTP id 874CF8FC23 for ; Mon, 7 Feb 2011 21:40:01 +0000 (UTC) Received: by eyf6 with SMTP id 6so2634340eyf.13 for ; Mon, 07 Feb 2011 13:40:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-type :content-transfer-encoding; bh=/qShrm1YZQwPWzmAMVijMWFZXmyVGYbGkDuoWpnLMFc=; b=VxWpfAvRooN7Se3QCDuOMUOu/ph1V8vvuUaf8htOnTEpWBtwjQvQcr6iIckY8B7N7z gMbO5Vs1ho8KW+YJdwX0Nv/oJP+0DQRsuE/sTQ9jIk96Pb0nz7rPJnQd8M9T33fx1Ssk oIEEeTn6Rs2TLaGxP0IC2e2y+jMZM8tzB238I= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type:content-transfer-encoding; b=nImCu7Jac4/F1OhIUcOBf0ijLizSUlsU+gl4J5oriSv8VFixGgVC8e4U/5ITbCZBol nyFVoCcPuAwH9YJJcDSFLlwAhJ/Fz6kwj+L/J9zej4bfVKbBQzpuCFNsdjTn866ESyoK mnucwp2CB+cTbOqJod2eU9a6IhX2o90rKxtbU= Received: by 10.14.52.13 with SMTP id d13mr6077850eec.11.1297114800587; Mon, 07 Feb 2011 13:40:00 -0800 (PST) Received: from localhost (gpftor6.privacyfoundation.de [62.212.67.209]) by mx.google.com with ESMTPS id t5sm3455837eeh.20.2011.02.07.13.39.57 (version=SSLv3 cipher=RC4-MD5); Mon, 07 Feb 2011 13:39:59 -0800 (PST) From: Anonymous To: Cyrille Lefevre References: <4D502D22.3000200@yandex.ru> <4D5048B5.4060000@laposte.net> Date: Tue, 08 Feb 2011 00:39:41 +0300 In-Reply-To: <4D5048B5.4060000@laposte.net> (Cyrille Lefevre's message of "Mon, 07 Feb 2011 20:32:05 +0100") Message-ID: <86sjvzzfqa.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-ports@freebsd.org Subject: Re: How to not use OPTIMIZED_FLAGS properly X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Feb 2011 21:40:02 -0000 Cyrille Lefevre writes: > Le 07/02/2011 18:34, Ruslan Mahmatkhanov a =C3=A9crit : >> >> Hello. >> >> I'm working on port that doesn't builds with "-O2 -pipe", that passed to >> Makefile by default (it exits with message about virtual memory is >> exhausted). I can avoid this by setting CFLAGS=3D"" and CXXFLAGS=3D"" in >> CONFIGURE_ENV. But portlint is complaining like this: >> >> What is the right way to do the job? > > how about CFLAGS :=3D ${CFLAGS:N-O*:N-pipe} -O One can also define WITH_DEBUG in the port's makefile until -On is fixed. # from Mk/bsd.port.mk .if defined(WITH_DEBUG) && !defined(WITHOUT_DEBUG) STRIP=3D #none STRIP_CMD=3D ${TRUE} DEBUG_FLAGS?=3D -g CFLAGS:=3D ${CFLAGS:N-O*:N-fno-strict*} ${DEBUG_FLAGS} .endif