HOWTOs
About
Search
libchardet
- Mozilla's Universal Charset Detector C/C++ API
ChangeLog
Web site:
https://github.com/Joungkyun/libchardet
Repository:
https://github.com/Joungkyun/libchardet
HOWTO
# libchardet 1.0.6
# ================
# Get the source
cd
test -f installed/libchardet-1.0.6.tar.bz2 &&
mv -f installed/libchardet-1.0.6.tar.bz2 .
test ! -f libchardet-1.0.6.tar.bz2 &&
wget https://github.com/Joungkyun/libchardet/releases/download/1.0.6/\
libchardet-1.0.6.tar.bz2
# Extract the source
mkdir -p -m 0700 ~/src
cd ~/src
find -type d -maxdepth 1 -name "libchardet-*" -exec rm -r {} \;
tar xjvf ~/libchardet-1.0.6.tar.bz2
cd libchardet-1.0.6
test $UID = 0 && chown -R root:root .
# Configure the build for 64-bit
test $(uname -m) = 'x86_64' &&
./configure --docdir=/usr/local/doc/libchardet-1.0.6 \
--libdir=/usr/local/lib64 --mandir=/usr/local/man
# Configure the build for anything else
test $(uname -m) != 'x86_64' &&
./configure --docdir=/usr/local/doc/libchardet-1.0.6 \
--mandir=/usr/local/man
# Build it
make
# Check the build
make check
# Become root to install it
su
# Install it
make install
ldconfig
# Become your non-root user again
exit
# Save the source for later
cd
mkdir -p 0700 installed
rm -f installed/libchardet-*.tar.*
mv libchardet-1.0.6.tar.bz2 installed/
# If you ever want to uninstall libchardet, this should do it:
cd
su
test -d src/libchardet-* && ( cd src/libchardet-* ; make uninstall )
rm /usr/local/bin/chardet-config
find /usr/local/doc -maxdepth 1 -type d -name "libchardet-*"
test -d /usr/local/doc/libchardet &&
rm -r /usr/local/doc/libchardet
test -d /usr/local/share/doc/libchardet &&
rm -r /usr/local/share/doc/libchardet/
( cd /usr/local/lib
rm -f libchardet.* pkgconfig/chardet.pc )
( cd /usr/local/lib64
rm -f libchardet.* pkgconfig/chardet.pc )
test -d /usr/local/include/chardet &&
rm -r /usr/local/include/chardet
test -d /usr/local/man/ko/man3 &&
( cd /usr/local/man/ko/man3
rm -f detect.3 detect_handledata.3 detect_obj_free.3 detect_reset.3 \
detect_destroy.3 detect_init.3 detect_obj_init.3 )
test -d /usr/local/man/man3 &&
( cd /usr/local/man/man3
rm -f detect.3 detect_handledata.3 detect_obj_free.3 detect_reset.3 \
detect_destroy.3 detect_init.3 detect_obj_init.3 )
ldconfig
exit
find ~/src -maxdepth 1 -type d -name "libchardet-*" -exec rm -r {} \;
rm -f ~/installed/libchardet-*.tar.*
List of HOWTOs
Web page itself last updated:
2023-12-20 8:06pm (EST -0500)
HOWTO last updated:
2023-09-12 12:36am
Copyright © 2001-2024
Jason Englander
. All Rights reserved.