From patchwork Wed Apr 24 13:13:21 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Guo, Yejun" X-Patchwork-Id: 12891 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id 84E2144849A for ; Wed, 24 Apr 2019 16:13:33 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 6C2CF68A129; Wed, 24 Apr 2019 16:13:33 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 0C90868A129 for ; Wed, 24 Apr 2019 16:13:25 +0300 (EEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 24 Apr 2019 06:13:24 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,389,1549958400"; d="scan'208";a="167484957" Received: from yguo18-skl-u1604.sh.intel.com ([10.239.13.25]) by fmsmga001.fm.intel.com with ESMTP; 24 Apr 2019 06:13:23 -0700 From: "Guo, Yejun" To: ffmpeg-devel@ffmpeg.org Date: Wed, 24 Apr 2019 21:13:21 +0800 Message-Id: <1556111601-7107-1-git-send-email-yejun.guo@intel.com> X-Mailer: git-send-email 2.7.4 Subject: [FFmpeg-devel] [PATCH V5 2/2] configure: replace 'pr' with printf since busybox does not support pr X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: yejun.guo@intel.com MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" This patch is based on https://trac.ffmpeg.org/ticket/5680 provided by Kylie McClain at Wed, 29 Jun 2016 16:37:20 -0400, and have some changes. contributor: Kylie McClain contributor: avih Signed-off-by: Guo, Yejun --- configure | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/configure b/configure index ad1b183..4215765 100755 --- a/configure +++ b/configure @@ -502,9 +502,13 @@ log(){ } log_file(){ - log BEGIN $1 - pr -n -t $1 >> $logfile - log END $1 + log BEGIN "$1" + log_file_i=1 + while IFS= read -r log_file_line;do + printf '%5s %s\n' "${log_file_i}" "${log_file_line}" + log_file_i=$(($log_file_i+1)) + done < "$1" >> "$logfile" + log END "$1" } warn(){