mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

124 lines
3.5 KiB

  1. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  2. #
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. # Please add additional copyright information _after_ the line containing
  5. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  6. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  7. #
  8. # ROCK Linux: rock-src/package/base/glibc22/glibc22.conf
  9. # ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf
  10. #
  11. # This program is free software; you can redistribute it and/or modify
  12. # it under the terms of the GNU General Public License as published by
  13. # the Free Software Foundation; either version 2 of the License, or
  14. # (at your option) any later version. A copy of the GNU General Public
  15. # License can be found at Documentation/COPYING.
  16. #
  17. # Many people helped and are helping developing ROCK Linux. Please
  18. # have a look at http://www.rocklinux.org/ and the Documentation/TEAM
  19. # file for details.
  20. #
  21. # --- ROCK-COPYRIGHT-NOTE-END ---
  22. glibc_custmain() {
  23. cat > configparms <<- EOF
  24. prefix = /usr
  25. slibdir = /lib
  26. sysconfdir = /etc
  27. install_root = $root
  28. CC = $CC
  29. BUILD_CC = $BUILDCC
  30. AR = $AR
  31. RANLIB = $RANLIB
  32. EOF
  33. # Disable glibc internal debuging but build debuging and profile
  34. # code so we can use this glibc to debug other programs.
  35. CFLAGS="$CFLAGS -g -DNDEBUG=1" ./configure --with-gnu-binutils \
  36. --enable-add-ons --enable-profile \
  37. --with-headers=$root/usr/include/linux \
  38. --with-gd=/usr \
  39. --with-gd-lib=/usr/lib \
  40. --with-gd-include=/usr/include \
  41. --build=${arch_build} ${arch_target}
  42. echo $BUILDCC elf/sln.c -o elf/dyn_sln
  43. $BUILDCC elf/sln.c -o elf/dyn_sln
  44. eval $MAKE symbolic-link-prog=elf/dyn_sln all install
  45. # Misc. stuff
  46. #
  47. if [ "$crossnative" = native ] ; then
  48. eval $MAKE install-locales -C localedata
  49. mkdir -p $root/usr/share/man/man3
  50. if [ -f /usr/bin/perl ] ; then
  51. eval $MAKE -C linuxthreads/man \
  52. MANDIR=$root/usr/share/man/man3 all install
  53. fi
  54. fi
  55. ln -sf libbsd-compat.a $root/usr/lib/libbsd.a
  56. # copy linuxthreads and crypt documentation
  57. #
  58. cp linuxthreads/ChangeLog $docdir/ChangeLog.threads
  59. cp linuxthreads/Changes $docdir/Changes.threads
  60. cp linuxthreads/README $docdir/README.threads
  61. cp linuxthreads/FAQ.html $docdir/FAQ-threads.html
  62. cp -r linuxthreads/Examples $docdir/examples.threads
  63. cp crypt/README.ufc-crypt $docdir/README.crypt
  64. # NSCD Init script and config
  65. #
  66. cp $confdir/nscd.conf $confdir/nsswitch.conf $root/etc/
  67. install_init nscd $confdir/nscd.init
  68. # No absolute path in libc.so if cross-compileing
  69. #
  70. if [ $crossnative = cross ] ; then
  71. libcso=$root/usr/lib/libc.so
  72. for x in 1 2 3 4 5 ; do
  73. sed 's,/[a-z/]*/,,' < $libcso > $libcso.new
  74. mv $libcso.new $libcso
  75. done
  76. fi
  77. # Install ld.so.conf
  78. #
  79. {
  80. echo "/usr/lib"
  81. echo "/usr/X11/lib"
  82. echo "/usr/local/lib"
  83. echo "/opt/*/lib"
  84. } > $root/etc/ld.so.conf
  85. if [ -f $root/usr/sbin/ldconfig ] ; then
  86. ln -sf ../usr/sbin/ldconfig $root/sbin/
  87. fi
  88. }
  89. glibc_prepatch() {
  90. tar $taropt $archdir/glibc-linuxthreads-$threadsver.tar.bz2
  91. }
  92. glibc_stage0() {
  93. eval "./configure --enable-add-ons $confopt"
  94. make cross-compiling=yes install-headers
  95. # make some final adaptions
  96. cp -v include/features.h $root/$prefix/include
  97. mkdir -p $root/$prefix/include/gnu
  98. touch $root/$prefix/include/gnu/stubs.h
  99. cp -v bits/stdio_lim.h $root/$prefix/include/bits
  100. # cp /usr/include/errno.h $root/$prefix/include
  101. # cp /usr/include/bits/errno.h $root/$prefix/include/bits
  102. }
  103. threadsver="$ver"
  104. prepatch="glibc_prepatch"
  105. if [ $stagelevel -eq 0 ]
  106. then
  107. custmain="glibc_stage0"
  108. else
  109. custmain="glibc_custmain"
  110. fi