linux/fs/unicode
Masahiro Yamada b1992c3772 kbuild: use $(src) instead of $(srctree)/$(src) for source directory
Kbuild conventionally uses $(obj)/ for generated files, and $(src)/ for
checked-in source files. It is merely a convention without any functional
difference. In fact, $(obj) and $(src) are exactly the same, as defined
in scripts/Makefile.build:

    src := $(obj)

When the kernel is built in a separate output directory, $(src) does
not accurately reflect the source directory location. While Kbuild
resolves this discrepancy by specifying VPATH=$(srctree) to search for
source files, it does not cover all cases. For example, when adding a
header search path for local headers, -I$(srctree)/$(src) is typically
passed to the compiler.

This introduces inconsistency between upstream and downstream Makefiles
because $(src) is used instead of $(srctree)/$(src) for the latter.

To address this inconsistency, this commit changes the semantics of
$(src) so that it always points to the directory in the source tree.

Going forward, the variables used in Makefiles will have the following
meanings:

  $(obj)     - directory in the object tree
  $(src)     - directory in the source tree  (changed by this commit)
  $(objtree) - the top of the kernel object tree
  $(srctree) - the top of the kernel source tree

Consequently, $(srctree)/$(src) in upstream Makefiles need to be replaced
with $(src).

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2024-05-10 04:34:52 +09:00
..
.gitignore unicode: fix .gitignore for generated utfdata file 2022-01-17 07:26:43 +02:00
Kconfig unicode: clean up the Kconfig symbol confusion 2022-01-20 19:57:24 -05:00
Makefile kbuild: use $(src) instead of $(srctree)/$(src) for source directory 2024-05-10 04:34:52 +09:00
mkutf8data.c unicode: Add utf8-data module 2021-10-12 11:41:39 -03:00
README.utf8data
utf8-core.c unicode: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:54 -07:00
utf8-norm.c unicode: only export internal symbols for the selftests 2021-10-12 11:41:39 -03:00
utf8-selftest.c unicode: Add utf8-data module 2021-10-12 11:41:39 -03:00
utf8data.c_shipped unicode: Add utf8-data module 2021-10-12 11:41:39 -03:00
utf8n.h unicode: Add utf8-data module 2021-10-12 11:41:39 -03:00

The utf8data.h file in this directory is generated from the Unicode
Character Database for version 12.1.0 of the Unicode standard.

The full set of files can be found here:

  http://www.unicode.org/Public/12.1.0/ucd/

Individual source links:

  https://www.unicode.org/Public/12.1.0/ucd/CaseFolding.txt
  https://www.unicode.org/Public/12.1.0/ucd/DerivedAge.txt
  https://www.unicode.org/Public/12.1.0/ucd/extracted/DerivedCombiningClass.txt
  https://www.unicode.org/Public/12.1.0/ucd/DerivedCoreProperties.txt
  https://www.unicode.org/Public/12.1.0/ucd/NormalizationCorrections.txt
  https://www.unicode.org/Public/12.1.0/ucd/NormalizationTest.txt
  https://www.unicode.org/Public/12.1.0/ucd/UnicodeData.txt

md5sums (verify by running "md5sum -c README.utf8data"):

  900e76da1d822a160fd6b8c0b1d70094  CaseFolding.txt
  131256380bff4fea8ad4a851616f2f10  DerivedAge.txt
  e731a4089b30002144e107e3d6f8d1fa  DerivedCombiningClass.txt
  a47c9fbd7ff92a9b261ba9831e68778a  DerivedCoreProperties.txt
  fcab6dad15e440879d92f315978f93d3  NormalizationCorrections.txt
  f9ff1c55a60decf436100f791b44aa98  NormalizationTest.txt
  755f6af699f8c8d2d958da411f78f6c6  UnicodeData.txt

sha1sums (verify by running "sha1sum -c README.utf8data"):

  dc9245f6803c4ac99555c361f5052e0b13eb779b  CaseFolding.txt
  3281104f237184cdb5d869e86eb8573678ada7da  DerivedAge.txt
  2f5f995ccb96e0fa84b15151b35d5e2681535175  DerivedCombiningClass.txt
  5b8698a3fcd5018e1987f296b02e2c17e696415e  DerivedCoreProperties.txt
  cd83935fbc012345d8792d2c704f69497e753835  NormalizationCorrections.txt
  ea419aae505b337b0d99a83fa83fe58ddff7c19f  NormalizationTest.txt
  dc973c0fc93d6f09d9ab9f70d1c9f89c447f0526  UnicodeData.txt


To update to the newer version of the Unicode standard, the latest
released version of the UCD can be found here:

  http://www.unicode.org/Public/UCD/latest/

Then, build under fs/unicode/ with REGENERATE_UTF8DATA=1:

	make REGENERATE_UTF8DATA=1 fs/unicode/

After sanity checking the newly generated utf8data.h file (the
version generated from the 12.1.0 UCD should be 4,109 lines long, and
have a total size of 324k) and/or comparing it with the older version
of utf8data.h_shipped, rename it to utf8data.h_shipped.

If you are a kernel developer updating to a newer version of the
Unicode Character Database, please update this README.utf8data file
with the version of the UCD that was used, the md5sum and sha1sums of
the *.txt files, before checking in the new versions of the utf8data.h
and README.utf8data files.