/[libidn]/libidn/libc/README
ViewVC logotype

Contents of /libidn/libc/README

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.18 - (show annotations) (download)
Thu Sep 27 15:18:16 2007 UTC (16 years, 7 months ago) by jas
Branch: MAIN
CVS Tags: HEAD
Changes since 1.17: +0 -0 lines
FILE REMOVED
Removed (all moved to git).

1 Libidn libc/README -- Instructions for building as a GNU Libc add-on.
2 Copyright (C) 2003 Simon Josefsson
3 See the end for copying conditions.
4
5 GNU Libidn can be built into GNU Libc if you follow these
6 instructions. Note that you should not run configure in Libidn.
7
8 1) Unpack Libc:
9
10 $ tar xfz glibc-2.3.2.tar.gz # and glibc-linuxthreads if you need it
11
12 2) Unpack Libidn:
13
14 $ tar xfz ~/libidn-0.3.0.tar.gz
15
16 3) Set up the Libidn add-on inside the Libc directory:
17
18 $ perl -pi -e 's/idn-int.h/stdint.h/' libidn-0.3.0/lib/{idna,stringprep,punycode}.h
19 $ cp -r libidn-0.3.0/lib glibc-2.3.2/libidn
20 $ ln -sf ../libidn/idna.h glibc-2.3.2/include/
21 $ cp libidn-0.3.0/libc/{Makefile,configure,Banner,Versions} glibc-2.3.2/libidn/
22 $ cp libidn-0.3.0/libc/getaddrinfo.c glibc-2.3.2/sysdeps/posix/
23 $ cp libidn-0.3.0/libc/netdb.h glibc-2.3.2/resolv/
24 $ touch glibc-2.3.2/libidn/libidn.texi
25
26 4) Configure and build Libc with the Libidn add-on:
27
28 $ mkdir glibc-2.3.2-obj
29 $ cd glibc-2.3.2-obj
30 $ ../glibc-2.3.2/configure --enable-add-ons=linuxthreads,libidn \
31 --prefix=/usr/local/glibc
32 $ make install
33
34 5) Run the example:
35
36 $ cd ../glibc-2.3.2/libidn/libc
37 $ gcc -o example example.c -L/usr/local/glibc/lib -Wl,-rpath,/usr/local/glibc/lib -nostdinc -I/usr/local/glibc/include -I/usr/include -I/usr/lib/gcc-lib/i386-linux/2.95.4/include
38 $ CHARSET=iso-8859-1 ./example
39 locale charset `iso-8859-1'
40 gettaddrinfo(räksmörgås.josefsson.org):
41 address `217.13.230.178'
42 canonical name `178.230.13.217.in-addr.dgcsystems.net'
43 $
44
45 Internally the domain name xn--rksmrgs-5wao1o.josefsson.org is looked
46 up in DNS.
47
48 The file libc.patch in this directory contains the modifications made
49 to getaddrinfo.c and netdb.h, should you wish to try this with another
50 GNU Libc version. With minor modifications, it has been verified to
51 work with 2.3.1.
52
53 ----------------------------------------------------------------------
54 Copying and distribution of this file, with or without modification,
55 are permitted in any medium without royalty provided the copyright
56 notice and this notice are preserved.

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26