acl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] libattr: Link programs against LTLIBINTL for gettext


From: Arsen Arsenović
Subject: [PATCH] libattr: Link programs against LTLIBINTL for gettext
Date: Wed, 16 Nov 2022 16:51:09 +0100

---
Afternoon,

In similar vein to the patch for libacl, this patch resolves linker
errors on systems that don't bundle gettext in libc, such as (some)
mlibc-based systems, giving us this:

  bash-5.1# attr
  mlibc: uselocale() is a no-op
  mlibc: uselocale() is a no-op
  mlibc: __fsetlocking() is a no-op
  A filename to operate on is required
  mlibc: uselocale() is a no-op
  mlibc: uselocale() is a no-op
  Usage: attr [-LRSq] -s attrname [-V attrvalue] pathname  # set value
         attr [-LRSq] -g attrname pathname                 # get value
         attr [-LRSq] -r attrname pathname                 # remove attr
         attr [-LRq]  -l pathname                          # list attrs 
        -s reads a value from stdin and -g writes a value to stdout
  mlibc: Locale en_US.utf8 is not supported
  bash-5.1# LANG=de attr
  mlibc: Locale en_US.utf8 is not supported
  mlibc: uselocale() is a no-op
  mlibc: uselocale() is a no-op
  mlibc: __fsetlocking() is a no-op
  Der Name der zu verwendenden Datei ist erforderlich
  mlibc: uselocale() is a no-op
  mlibc: uselocale() is a no-op
  Verwendung: attr [-LRSq] -s attrname [-V attrvalue] pfadname  # Wert setzen
              attr [-LRSq] -g attrname pfadname                 # Wert lesen
              attr [-LRSq] -r attrname pfadname                 # Wert entfernen
              attr [-LRq]  -l pfadname                          # Attribute 
auflisten
              -s liest einen Wert von stdin, -g schreibt einen Wert auf stdout
  mlibc: Locale en_US.utf8 is not supported
  bash-5.1#

Bar libc flaws (again), we gettext gets linked and does localize
(presumably; I don't speak German :^).

Thanks in advance, and have a great day.

 libattr/Makemodule.am | 1 +
 tools/Makemodule.am   | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/libattr/Makemodule.am b/libattr/Makemodule.am
index 1211aba..3103cec 100644
--- a/libattr/Makemodule.am
+++ b/libattr/Makemodule.am
@@ -8,6 +8,7 @@ LT_CURRENT = 2
 LT_AGE = 1
 LTVERSION = $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
 
+libattr_la_LIBADD = $(LTLIBINTL)
 libattr_la_DEPENDENCIES = \
        exports
 if OS_LINUX
diff --git a/tools/Makemodule.am b/tools/Makemodule.am
index 890c11f..6bb99e0 100644
--- a/tools/Makemodule.am
+++ b/tools/Makemodule.am
@@ -1,4 +1,4 @@
-tools_ldadd = $(LDADD) libattr.la libmisc.la
+tools_ldadd = $(LDADD) libattr.la libmisc.la $(LTLIBINTL)
 
 bin_PROGRAMS += attr
 attr_SOURCES = tools/attr.c
-- 
2.38.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]