From owner-freebsd-ports@FreeBSD.ORG Mon Feb 7 18:06:08 2011 Return-Path: Delivered-To: ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D3D5E106566B for ; Mon, 7 Feb 2011 18:06:08 +0000 (UTC) (envelope-from annulen@yandex.ru) Received: from forward6.mail.yandex.net (forward6.mail.yandex.net [77.88.60.125]) by mx1.freebsd.org (Postfix) with ESMTP id 872EF8FC0A for ; Mon, 7 Feb 2011 18:06:08 +0000 (UTC) Received: from web95.yandex.ru (web95.yandex.ru [77.88.60.19]) by forward6.mail.yandex.net (Yandex) with ESMTP id 853203958D83 for ; Mon, 7 Feb 2011 20:50:57 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1297101057; bh=abDnSMlFPIVsIOhhjJwge9FnMRhVwlZDBa1VofB6PyM=; h=From:To:Cc:In-Reply-To:References:Subject:MIME-Version:Message-Id: Date:Content-Transfer-Encoding:Content-Type; b=CvrOzvyr2HhhvGryV2moruGQMjWUsP4FmgWeV6+X46XpZbv7xmHAXR9ZPwwVxkFAh 4dYy7ejHazzhj+vHvF4v49DShxM68jF8aben0J5Wa/IdY5n05XmRSq19nZrEJURDWU aMqDM/4Ku89bJMF84OzNuSgoV7+ylAlSGGL3qR90= Received: from localhost (localhost.localdomain [127.0.0.1]) by web95.yandex.ru (Yandex) with ESMTP id 75AEF2403A7; Mon, 7 Feb 2011 20:50:57 +0300 (MSK) Received: from [195.34.30.225] ([195.34.30.225]) by mail.yandex.ru with HTTP; Mon, 07 Feb 2011 20:50:56 +0300 From: Konstantin Tokarev To: Ruslan Mahmatkhanov In-Reply-To: <4D502D22.3000200@yandex.ru> References: <4D502D22.3000200@yandex.ru> MIME-Version: 1.0 Message-Id: <567921297101056@web95.yandex.ru> Date: Mon, 07 Feb 2011 20:50:56 +0300 X-Mailer: Yamail [ http://yandex.ru ] 5.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=koi8-r Cc: FreeBSD Ports Mailing List 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 18:06:08 -0000 07.02.2011, 20:34, "Ruslan Mahmatkhanov" : > 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="" and CXXFLAGS="" in > CONFIGURE_ENV. But portlint is complaining like this: > > WARN: Makefile: CFLAGS/CXXFLAGS are not needed in CONFIGURE_ENV as they > are already added there in bsd.port.mk. > FATAL: Makefile: CFLAGS are clobbered in CONFIGURE_ENV. šAlter CFLAGS in > the Makefile with CFLAGS+=... instead > FATAL: Makefile: CXXFLAGS are clobbered in CONFIGURE_ENV. šAlter > CXXFLAGS in the Makefile with CXXFLAGS+=... instead > > What is the right way to do the job? > > PS. If i set -O0 in CONFIGURE_ENV, it's later redefined to "-O2 -pipe". Have you tried CFLAGS+=-O0 as portlint suggested? -- Regards, Konstantin