* [LTP] [PATCH 0/3] LC_ALL for build, remove outdated doc
@ 2022-10-21 11:53 Petr Vorel
2022-10-21 11:53 ` [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C Petr Vorel
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Petr Vorel @ 2022-10-21 11:53 UTC (permalink / raw)
To: ltp
Petr Vorel (3):
Makefile: set LC_ALL and LANG to C
Makefile: Update copyright, use SPDX
doc: Remove mini-howto-building-ltp-from-git.txt
Makefile | 28 +++--------
doc/mini-howto-building-ltp-from-git.txt | 62 ------------------------
2 files changed, 7 insertions(+), 83 deletions(-)
delete mode 100644 doc/mini-howto-building-ltp-from-git.txt
--
2.38.0
--
Mailing list info: https://lists.linux.it/listinfo/ltp
^ permalink raw reply [flat|nested] 10+ messages in thread* [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C 2022-10-21 11:53 [LTP] [PATCH 0/3] LC_ALL for build, remove outdated doc Petr Vorel @ 2022-10-21 11:53 ` Petr Vorel 2022-10-22 0:28 ` Akihiko Odaki 2022-10-21 11:53 ` [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX Petr Vorel 2022-10-21 11:53 ` [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt Petr Vorel 2 siblings, 1 reply; 10+ messages in thread From: Petr Vorel @ 2022-10-21 11:53 UTC (permalink / raw) To: ltp * have reproducible builds (no locale dependencies) * English only output - easier to debug problem Signed-off-by: Petr Vorel <pvorel@suse.cz> --- NOTE: if we want to have only reproducible build, but keep localized messages, we could use kernel approach: unexport LC_ALL LC_COLLATE=C LC_NUMERIC=C export LC_COLLATE LC_NUMERIC They deliberately kept LC_CTYPE to have localized messages. See also c051346b7db2 ("Makefile: set LC_CTYPE, LC_COLLATE, LC_NUMERIC to C") 07105202bdeb ("Makefile: do not override LC_CTYPE") Makefile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Makefile b/Makefile index d4399bae6..ea11ac7f3 100644 --- a/Makefile +++ b/Makefile @@ -21,6 +21,10 @@ # Ngie Cooper, July 2009 # +# Avoid funny character set dependencies +export LANG=C +export LC_ALL=C + top_srcdir ?= $(CURDIR) include $(top_srcdir)/include/mk/env_pre.mk -- 2.38.0 -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C 2022-10-21 11:53 ` [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C Petr Vorel @ 2022-10-22 0:28 ` Akihiko Odaki 2022-11-07 11:41 ` Richard Palethorpe 0 siblings, 1 reply; 10+ messages in thread From: Akihiko Odaki @ 2022-10-22 0:28 UTC (permalink / raw) To: Petr Vorel, ltp On 2022/10/21 20:53, Petr Vorel wrote: > * have reproducible builds (no locale dependencies) > * English only output - easier to debug problem > > Signed-off-by: Petr Vorel <pvorel@suse.cz> > --- > NOTE: if we want to have only reproducible build, but keep localized > messages, we could use kernel approach: > unexport LC_ALL > LC_COLLATE=C > LC_NUMERIC=C > export LC_COLLATE LC_NUMERIC > > They deliberately kept LC_CTYPE to have localized messages. > > See also > c051346b7db2 ("Makefile: set LC_CTYPE, LC_COLLATE, LC_NUMERIC to C") > 07105202bdeb ("Makefile: do not override LC_CTYPE") > > Makefile | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/Makefile b/Makefile > index d4399bae6..ea11ac7f3 100644 > --- a/Makefile > +++ b/Makefile > @@ -21,6 +21,10 @@ > # Ngie Cooper, July 2009 > # > > +# Avoid funny character set dependencies > +export LANG=C Hi, Setting LANG should not be necessary as long as LC_ALL is set. That is what my patch "tst_test.sh: Normalize the locale" does. Regards, Akihiko Odaki > +export LC_ALL=C > + > top_srcdir ?= $(CURDIR) > > include $(top_srcdir)/include/mk/env_pre.mk -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C 2022-10-22 0:28 ` Akihiko Odaki @ 2022-11-07 11:41 ` Richard Palethorpe 0 siblings, 0 replies; 10+ messages in thread From: Richard Palethorpe @ 2022-11-07 11:41 UTC (permalink / raw) To: Akihiko Odaki; +Cc: ltp Hello, Akihiko Odaki <akihiko.odaki@daynix.com> writes: > On 2022/10/21 20:53, Petr Vorel wrote: >> * have reproducible builds (no locale dependencies) >> * English only output - easier to debug problem >> Signed-off-by: Petr Vorel <pvorel@suse.cz> >> --- >> NOTE: if we want to have only reproducible build, but keep localized >> messages, we could use kernel approach: >> unexport LC_ALL >> LC_COLLATE=C >> LC_NUMERIC=C >> export LC_COLLATE LC_NUMERIC >> They deliberately kept LC_CTYPE to have localized messages. >> See also >> c051346b7db2 ("Makefile: set LC_CTYPE, LC_COLLATE, LC_NUMERIC to C") >> 07105202bdeb ("Makefile: do not override LC_CTYPE") I would prefer to copy the kernel. If someone sends us compilation messages in a language we don't understand then we can ask them to set the locale before compiling. I think ensuring our build scripts produce the same executable output on different locales is nice though. >> Makefile | 4 ++++ >> 1 file changed, 4 insertions(+) >> diff --git a/Makefile b/Makefile >> index d4399bae6..ea11ac7f3 100644 >> --- a/Makefile >> +++ b/Makefile >> @@ -21,6 +21,10 @@ >> # Ngie Cooper, July 2009 >> # >> +# Avoid funny character set dependencies >> +export LANG=C > > Hi, > > Setting LANG should not be necessary as long as LC_ALL is set. That is > what my patch "tst_test.sh: Normalize the locale" does. Yes, I don't understand what LANG is doing here. AFAICT it is just sets a default for undefined settings and will be overrided by LC_ALL. > > Regards, > Akihiko Odaki > >> +export LC_ALL=C >> + >> top_srcdir ?= $(CURDIR) >> include $(top_srcdir)/include/mk/env_pre.mk Setting to changes-requested in patchwork because of LANG and LC_ALL is overkill IMO. -- Thank you, Richard. -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply [flat|nested] 10+ messages in thread
* [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX 2022-10-21 11:53 [LTP] [PATCH 0/3] LC_ALL for build, remove outdated doc Petr Vorel 2022-10-21 11:53 ` [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C Petr Vorel @ 2022-10-21 11:53 ` Petr Vorel 2022-11-07 12:03 ` Richard Palethorpe 2022-10-21 11:53 ` [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt Petr Vorel 2 siblings, 1 reply; 10+ messages in thread From: Petr Vorel @ 2022-10-21 11:53 UTC (permalink / raw) To: ltp Signed-off-by: Petr Vorel <pvorel@suse.cz> --- Makefile | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/Makefile b/Makefile index ea11ac7f3..1ccb301a0 100644 --- a/Makefile +++ b/Makefile @@ -1,25 +1,7 @@ -# -# Top-level Makefile for LTP. See INSTALL for more info. -# -# Copyright (c) Linux Test Project, 2009-2020 -# Copyright (c) Cisco Systems Inc., 2009-2010 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -# +# SPDX-License-Identifier: GPL-2.0-or-later +# Copyright (c) Linux Test Project, 2009-2022 +# Copyright (c) Cisco Systems Inc., 2009-2010 # Ngie Cooper, July 2009 -# # Avoid funny character set dependencies export LANG=C -- 2.38.0 -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX 2022-10-21 11:53 ` [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX Petr Vorel @ 2022-11-07 12:03 ` Richard Palethorpe 2022-11-07 14:44 ` Petr Vorel 0 siblings, 1 reply; 10+ messages in thread From: Richard Palethorpe @ 2022-11-07 12:03 UTC (permalink / raw) To: Petr Vorel; +Cc: ltp Hello, Petr Vorel <pvorel@suse.cz> writes: > Signed-off-by: Petr Vorel <pvorel@suse.cz> > --- > Makefile | 24 +++--------------------- > 1 file changed, 3 insertions(+), 21 deletions(-) > > diff --git a/Makefile b/Makefile > index ea11ac7f3..1ccb301a0 100644 > --- a/Makefile > +++ b/Makefile > @@ -1,25 +1,7 @@ > -# > -# Top-level Makefile for LTP. See INSTALL for more info. > -# > -# Copyright (c) Linux Test Project, 2009-2020 > -# Copyright (c) Cisco Systems Inc., 2009-2010 > -# > -# This program is free software; you can redistribute it and/or modify > -# it under the terms of the GNU General Public License as published by > -# the Free Software Foundation; either version 2 of the License, or > -# (at your option) any later version. > -# > -# This program is distributed in the hope that it will be useful, > -# but WITHOUT ANY WARRANTY; without even the implied warranty of > -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > -# GNU General Public License for more details. > -# > -# You should have received a copy of the GNU General Public License along > -# with this program; if not, write to the Free Software Foundation, Inc., > -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. > -# > +# SPDX-License-Identifier: GPL-2.0-or-later > +# Copyright (c) Linux Test Project, 2009-2022 > +# Copyright (c) Cisco Systems Inc., 2009-2010 > # Ngie Cooper, July 2009 > -# I would just merge, but it won't apply Acked-by: Richard Palethorpe <rpalethorpe@suse.com> > > # Avoid funny character set dependencies > export LANG=C > -- > 2.38.0 -- Thank you, Richard. -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX 2022-11-07 12:03 ` Richard Palethorpe @ 2022-11-07 14:44 ` Petr Vorel 0 siblings, 0 replies; 10+ messages in thread From: Petr Vorel @ 2022-11-07 14:44 UTC (permalink / raw) To: Richard Palethorpe; +Cc: ltp Hi Richie, > I would just merge, but it won't apply > Acked-by: Richard Palethorpe <rpalethorpe@suse.com> I rebased and merged this one. I will send new version of fist patch, so that more people can have change to review. Kind regards, Petr -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply [flat|nested] 10+ messages in thread
* [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt 2022-10-21 11:53 [LTP] [PATCH 0/3] LC_ALL for build, remove outdated doc Petr Vorel 2022-10-21 11:53 ` [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C Petr Vorel 2022-10-21 11:53 ` [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX Petr Vorel @ 2022-10-21 11:53 ` Petr Vorel 2022-11-07 12:03 ` Richard Palethorpe 2 siblings, 1 reply; 10+ messages in thread From: Petr Vorel @ 2022-10-21 11:53 UTC (permalink / raw) To: ltp Document is not linked into our wiki, there is "Quick guide to running the tests" section in README.md visible from web and CI scripts in ci/*.sh and build.sh, which describe what to install and how to build. Signed-off-by: Petr Vorel <pvorel@suse.cz> --- Do we want any of these move to "Quick guide to running the tests" section in README.md? doc/mini-howto-building-ltp-from-git.txt | 62 ------------------------ 1 file changed, 62 deletions(-) delete mode 100644 doc/mini-howto-building-ltp-from-git.txt diff --git a/doc/mini-howto-building-ltp-from-git.txt b/doc/mini-howto-building-ltp-from-git.txt deleted file mode 100644 index 28825c20f..000000000 --- a/doc/mini-howto-building-ltp-from-git.txt +++ /dev/null @@ -1,62 +0,0 @@ -Mini-Howto: Building LTP from Git -================================= - -****************************************************************************** -The following document briefly describes the single steps to build LTP from -the Git repository located at GitHub. -The instructions here were tested on a Ubuntu/precise Linux system (feel free -to adapt to your distribution). - -Changelog: - * Initial version: Sedat Dilek <sedat.dilek@gmail.com> - * Embedded comments from Cyril Hrubis <chrubis@suse.cz> -****************************************************************************** - -# Export language settings - -export LANG=C -export LC_ALL=C - -# Set some useful variables (adapt if you dislike) - -WORKING_DIR="$HOME/src/ltp" - -PREFIX="/opt/ltp" - -GIT_URL="https://github.com/linux-test-project/ltp.git" - -MAKE_JOBS=$(getconf _NPROCESSORS_ONLN) - -BUILD_LOG_FILE="build-log.txt" -INSTALL_LOG_FILE="install-log.txt" - -# PREREQS on Ubuntu (package-list is incomplete and may vary for other distros) - -sudo apt-get install build-essential -sudo apt-get install autoconf automake autotools-dev m4 -sudo apt-get install git -sudo apt-get install linux-headers-$(uname -r) -sudo apt-get install libaio-dev libattr1-dev libcap-dev - -# Working directory - -mkdir -p $WORKING_DIR -cd $WORKING_DIR - -# Get the LTP source - -git clone $GIT_URL ltp-git - -# Configure LTP - -cd ltp-git/ -make autotools -./configure --prefix=$PREFIX - -# Start building LTP - -make -j$MAKE_JOBS 2>&1 | tee ../$BUILD_LOG_FILE - -# Install LTP (requires superuser privileges) - -sudo make install 2>&1 | tee ../$INSTALL_LOG_FILE -- 2.38.0 -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt 2022-10-21 11:53 ` [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt Petr Vorel @ 2022-11-07 12:03 ` Richard Palethorpe 2022-11-07 14:43 ` Petr Vorel 0 siblings, 1 reply; 10+ messages in thread From: Richard Palethorpe @ 2022-11-07 12:03 UTC (permalink / raw) To: Petr Vorel; +Cc: ltp Hello, Petr Vorel <pvorel@suse.cz> writes: > Document is not linked into our wiki, there is "Quick guide to running > the tests" section in README.md visible from web and CI scripts in > ci/*.sh and build.sh, which describe what to install and how to build. > > Signed-off-by: Petr Vorel <pvorel@suse.cz> Acked-by: Richard Palethorpe <rpalethorpe@suse.com> > --- > Do we want any of these move to "Quick guide to running the tests" > section in README.md? > > > doc/mini-howto-building-ltp-from-git.txt | 62 ------------------------ > 1 file changed, 62 deletions(-) > delete mode 100644 doc/mini-howto-building-ltp-from-git.txt > > diff --git a/doc/mini-howto-building-ltp-from-git.txt b/doc/mini-howto-building-ltp-from-git.txt > deleted file mode 100644 > index 28825c20f..000000000 > --- a/doc/mini-howto-building-ltp-from-git.txt > +++ /dev/null > @@ -1,62 +0,0 @@ > -Mini-Howto: Building LTP from Git > -================================= > - > -****************************************************************************** > -The following document briefly describes the single steps to build LTP from > -the Git repository located at GitHub. > -The instructions here were tested on a Ubuntu/precise Linux system (feel free > -to adapt to your distribution). > - > -Changelog: > - * Initial version: Sedat Dilek <sedat.dilek@gmail.com> > - * Embedded comments from Cyril Hrubis <chrubis@suse.cz> > -****************************************************************************** > - > -# Export language settings > - > -export LANG=C > -export LC_ALL=C > - > -# Set some useful variables (adapt if you dislike) > - > -WORKING_DIR="$HOME/src/ltp" > - > -PREFIX="/opt/ltp" > - > -GIT_URL="https://github.com/linux-test-project/ltp.git" > - > -MAKE_JOBS=$(getconf _NPROCESSORS_ONLN) > - > -BUILD_LOG_FILE="build-log.txt" > -INSTALL_LOG_FILE="install-log.txt" > - > -# PREREQS on Ubuntu (package-list is incomplete and may vary for other distros) > - > -sudo apt-get install build-essential > -sudo apt-get install autoconf automake autotools-dev m4 > -sudo apt-get install git > -sudo apt-get install linux-headers-$(uname -r) > -sudo apt-get install libaio-dev libattr1-dev libcap-dev > - > -# Working directory > - > -mkdir -p $WORKING_DIR > -cd $WORKING_DIR > - > -# Get the LTP source > - > -git clone $GIT_URL ltp-git > - > -# Configure LTP > - > -cd ltp-git/ > -make autotools > -./configure --prefix=$PREFIX > - > -# Start building LTP > - > -make -j$MAKE_JOBS 2>&1 | tee ../$BUILD_LOG_FILE > - > -# Install LTP (requires superuser privileges) > - > -sudo make install 2>&1 | tee ../$INSTALL_LOG_FILE > -- > 2.38.0 -- Thank you, Richard. -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt 2022-11-07 12:03 ` Richard Palethorpe @ 2022-11-07 14:43 ` Petr Vorel 0 siblings, 0 replies; 10+ messages in thread From: Petr Vorel @ 2022-11-07 14:43 UTC (permalink / raw) To: Richard Palethorpe; +Cc: ltp Hi Richie, > Acked-by: Richard Palethorpe <rpalethorpe@suse.com> Thx, merged this one. Kind regards, Petr -- Mailing list info: https://lists.linux.it/listinfo/ltp ^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2022-11-07 14:45 UTC | newest] Thread overview: 10+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2022-10-21 11:53 [LTP] [PATCH 0/3] LC_ALL for build, remove outdated doc Petr Vorel 2022-10-21 11:53 ` [LTP] [PATCH 1/3] Makefile: set LC_ALL and LANG to C Petr Vorel 2022-10-22 0:28 ` Akihiko Odaki 2022-11-07 11:41 ` Richard Palethorpe 2022-10-21 11:53 ` [LTP] [PATCH 2/3] Makefile: Update copyright, use SPDX Petr Vorel 2022-11-07 12:03 ` Richard Palethorpe 2022-11-07 14:44 ` Petr Vorel 2022-10-21 11:53 ` [LTP] [PATCH 3/3] doc: Remove mini-howto-building-ltp-from-git.txt Petr Vorel 2022-11-07 12:03 ` Richard Palethorpe 2022-11-07 14:43 ` Petr Vorel
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox