LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 5556|回复: 17

本人安装XORG7.4的过程及总结。。。

[复制链接]
发表于 2009-2-19 09:24:41 | 显示全部楼层 |阅读模式
按照CBLFS的方法来装。。。
请高手指点,也给像我这样的新手点提示,不要像我一样犯太多错误。。
谢谢。。
先下载包包:
  1. wget -c http://pkgconfig.freedesktop.org/releases/pkg-config-0.23.tar.gz
  2. wget -c ftp://xmlsoft.org/libxml2/libxml2-2.7.2.tar.gz
  3. wget -c ftp://ftp.gnu.org/pub/gnu/gperf/gperf-3.0.3.tar.gz
  4. wget -c ftp://xmlsoft.org/libxml2/libxslt-1.1.24.tar.gz
  5. wget -c http://xcb.freedesktop.org/dist/xcb-proto-1.2.tar.bz2
  6. wget -c http://www.python.org/ftp/python/2.5.2/Python-2.5.2.tar.bz2
  7. wget -c http://svn.cross-lfs.org/svn/repos/patches/Python/Python-2.5.2-gdbm-1.patch
  8. wget -c http://xcb.freedesktop.org/dist/libxcb-1.1.91.tar.bz2
  9. wget -c http://svn.cross-lfs.org/svn/repos/patches/libxcb/libxcb-1.1.91-sloppy_lock-1.patch
  10. wget -c http://xcb.freedesktop.org/dist/xcb-util-0.2.tar.bz2
  11. wget -c http://ftp.gnu.org/pub/gnu/ed/ed-1.2.tar.gz
  12. wget -c http://downloads.sourceforge.net/expat/expat-2.0.1.tar.gz
  13. wget -c http://downloads.sourceforge.net/freetype/freetype-2.3.5.tar.bz2
  14. wget -c http://downloads.sourceforge.net/freetype/freetype-doc-2.3.5.tar.bz2
  15. wget -c http://fontconfig.org/release/fontconfig-2.6.0.tar.gz
  16. wget -c http://cross-lfs.org/~jciccone/drm-20080719.tar.bz2
  17. wget -c http://downloads.sourceforge.net/mesa3d/MesaLib-7.1.tar.gz
  18. wget -c http://downloads.sourceforge.net/mesa3d/MesaDemos-7.1.tar.bz2
  19. wget -c http://downloads.sourceforge.net/mesa3d/MesaGLUT-7.1.tar.bz2
  20. wget -c http://xorg.freedesktop.org/releases/individual/data/xbitmaps-1.0.1.tar.bz2
  21. wget -c http://downloads.sourceforge.net/libpng/libpng-1.2.34.tar.bz2
  22. wget -c http://svn.cross-lfs.org/svn/repos/patches/libpng/libpng-1.2.34-apng-1.patch
  23. wget -c http://cpan.org/authors/id/M/MS/MSERGEANT/XML-Parser-2.36.tar.gz
  24. wget -c http://ftp.gnome.org/pub/gnome/sources/intltool/0.40/intltool-0.40.5.tar.bz2
  25. wget -c http://xorg.freedesktop.org/releases/individual/data/xcursor-themes-1.0.1.tar.bz2
  26. wget -c http://xlibs.freedesktop.org/xkbdesc/xkeyboard-config-1.3.tar.bz2
  27. wget -c http://www.openssl.org/source/openssl-0.9.8j.tar.gz
  28. wget -c http://svn.cross-lfs.org/svn/repos/patches/openssl/openssl-0.9.8j-fix_manpages-1.patch
  29. wget -c http://svn.cross-lfs.org/svn/repos/patches/openssl/openssl-0.9.8j-build_fix-1.patch
  30. wget -c http://svn.cross-lfs.org/svn/repos/patches/openssl/openssl-0.9.8j-mips_support-1.patch
  31. wget -c http://xorg.freedesktop.org/releases/individual/xserver/xorg-server-1.5.0.tar.bz2
  32. wget -c http://svn.cross-lfs.org/svn/repos/patches/xorg-server/xorg-server-1.5.0-paint_it_black-1.patch
  33. wget -c  ftp://invisible-island.net/xterm/xterm-237.tgz
  34. wget -c  http://prdownloads.sourceforge.net/polyglotman/rman-3.2.tar.gz
  35. #if there is not a cmd named "makedepend"  down this and install it .
  36. wget -c  http://xorg.freedesktop.org/releases/individual/util/makedepend-1.0.1.tar.bz2
  37. #down proto
  38. wget http://cblfs.cross-lfs.org/index.php/Special:Filepath/Proto-20081023.wget &&
  39. mkdir -p proto &&
  40. cd proto &&
  41. wget -B http://xorg.freedesktop.org/releases/individual/proto/ -i ../Proto-20081023.wget
  42. cd ..
  43. #down util
  44. wget http://cblfs.cross-lfs.org/index.php/Special:Filepath/Util-20081023.wget &&
  45. mkdir -p util &&
  46. cd util &&
  47. wget -B http://xorg.freedesktop.org/releases/individual/util/ -i ../Util-20081023.wget
  48. cd ..
  49. #down lib
  50. wget http://cblfs.cross-lfs.org/index.php/Special:Filepath/Lib-20081023.wget &&
  51. mkdir -p lib &&
  52. cd lib &&
  53. wget -B http://xorg.freedesktop.org/releases/individual/lib/ -i ../Lib-20081023.wget
  54. cd ..
  55. #down app
  56. wget http://cblfs.cross-lfs.org/index.php/Special:Filepath/App-20081023.wget &&
  57. mkdir -p app &&
  58. cd app &&
  59. wget -B http://xorg.freedesktop.org/releases/individual/app/ -i ../App-20081023.wget
  60. cd ..
  61. #down font
  62. wget http://cblfs.cross-lfs.org/index.php/Special:Filepath/Font-20081023.wget &&
  63. mkdir -p font &&
  64. cd font &&
  65. wget -B http://xorg.freedesktop.org/releases/individual/font/ -i ../Font-20081023.wget
  66. cd ..
  67. #down driver
  68. wget http://cblfs.cross-lfs.org/index.php/Special:Filepath/Driver-20081023.wget
  69. #Edit Driver-20081023.wget and completely remove the drivers you don't need.
  70. #I just keep three: xf86-input-mouse  xf86-input-keyboard  xf86-video-nv
  71. mkdir -p driver &&
  72. cd driver &&
  73. wget -B http://xorg.freedesktop.org/archive/individual/driver/ -i ../Driver-20081023.wget
  74. cd ..
复制代码

安装过程:



#check #检查下LFS系统是否有makedepend有这个命令了,没有的话就先安装上,装MesaLib的时候会用得到。。。
tar xvf makedepend-1.0.1.tar.bz2
cd makedepend-1.0.1
./configure
make
cp ./makedepend /bin/makedepend

######0 python install. someone need it, if you had installed so skip.

tar xvf Python-2.5.2.tar.bz2
cd Python-2.5.2
sed -i "s@/usr/X11R6@${XORG_PREFIX}@g" setup.py &&
patch -Np1 -i ../Python-2.5.2-gdbm-1.patch &&
./configure --prefix=/usr --enable-shared &&
make EXTRA_CFLAGS="-fwrapv"
make install
cd ..
rm -rf  Python-2.5.2

#####1 Ready to go.....
export XORG_PREFIX="/usr/X11R7"
export XORG_CONFIG="  --prefix=$XORG_PREFIX --sysconfdir=/etc \
    --mandir=$XORG_PREFIX/share/man --localstatedir=/var "

#add "/usr/X11R7/lib" to "ld.sc.conf"

cat >> /etc/ld.so.conf << EOF
# Begin Xorg addition to /etc/ld.so.conf
${XORG_PREFIX}/lib
# End Xorg addition to /etc/ld.so.conf
EOF

######2  pkg-config
tar xvf pkg-config-0.23.tar.gz
cd pkg-config-0.23
./configure --prefix=/usr
make
make install
cd ..
rm -rf pkg-config-0.23

#pkg-config is a tool to help you insert the correct compiler options on the command line when compiling applications and libraries.

export PKG_CONFIG_PATH=/usr/X11R7/lib:/lib/pkgconfig:/usr/lib/pkgconfig:/usr/X11R7/lib/pkgconfig

#########3 Xorg7/Protocol Headers
cd proto
#do tar first of all.
for i in *.tar.bz2; do
  tar xvf $i;
done

for dir in `find . -maxdepth 1 -mindepth 1 -type d`; do
  cd $dir &&
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG &&
  make install
  cd ..
  rm -rf $dir
  echo  $dir ===========================END
done 2>&1 | tee -a ../xorg-proto-7.4-compile.log #log the entire loop
cd ..

########4 Xorg7/Utilities
cd util
#do tar first of all.
for i in *.tar.bz2; do
tar xvf $i;
done

#install xorg-cf-files-1.0.2  first
cd xorg-cf-files-1.0.2
sed -i "s@/usr/X11R6@$XORG_PREFIX@" X11.tmpl
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure $XORG_CONFIG &&
make install
cd ..
rm -rf xorg-cf-files-1.0.2
#instll the rest
for dir in `find . -maxdepth 1 -mindepth 1 -type d`; do
  cd $dir &&
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG &&
  make
  make install
  cd ..
  rm -rf $dir
  echo  $dir ===========================END
done 2>&1 | tee -a ../xorg-util-7.4-compile.log #log the entire loop
cd ..

#从5到16是为了给 Xorg7/Libraries 做准备工作。。
#######5 LibXML2
tar xvf libxml2-2.7.2.tar.gz
cd libxml2-2.7.2
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr  &&
make &&
make install
cd ..
rm -rf libxml2-2.7.2

#######6 Gperf
tar xvf gperf-3.0.3.tar.gz
cd gperf-3.0.3
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr  &&
make &&
make install
cd ..
rm -rf gperf-3.0.3

#######7 LibXSLT
tar xvf libxslt-1.1.24.tar.gz
cd libxslt-1.1.24
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr  &&
make &&
make install
cd ..
rm -rf libxslt-1.1.24

########8 Xcb-proto
tar xvf xcb-proto-1.2.tar.bz2
cd xcb-proto-1.2
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure $XORG_CONFIG  &&
make &&
make install
cd ..
rm -rf xcb-proto-1.2

########9 Libpthread-stubs
cd lib
tar xvf libpthread-stubs-0.1.tar.bz2
cd libpthread-stubs-0.1
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure $XORG_CONFIG  &&
make &&
make install
cd ..
rm -rf libpthread-stubs-0.1
cd ..

########10 libXau
cd lib
tar xvf libXau-1.0.4.tar.bz2
cd libXau-1.0.4
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure $XORG_CONFIG  &&
make &&
make install
cd ..
rm -rf libXau-1.0.4
cd ..

# #####11 Libxcb
tar xvf libxcb-1.1.91.tar.bz2
cd libxcb-1.1.91
patch -Np1 -i ../libxcb-1.1.91-sloppy_lock-1.patch &&
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure $XORG_CONFIG &&
make
make install
cd ..
rm -rf libxcb-1.1.91

#######12 Xcb-utils
tar xvf xcb-util-0.2.tar.bz2
cd xcb-util-0.2
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure $XORG_CONFIG  &&
make &&
make install
cd ..
rm -rf xcb-util-0.2

#########13 ed
tar xvf ed-1.2.tar.gz
cd ed-1.2
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr --exec-prefix="" &&
make
make install
cd ..
rm -rf ed-1.2

##########14 Expat
tar  xvf expat-2.0.1.tar.gz
cd expat-2.0.1
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr &&
make
make install &&
install -v -m755 -d /usr/share/doc/expat-2.0.1 &&
install -v -m644 doc/*.{html,png,css} /usr/share/doc/expat-2.0.1
cd ..
rm -rf expat-2.0.1

#########15 FreeType
tar xvf freetype-2.3.5.tar.bz2
cd freetype-2.3.5
tar xf ../freetype-doc-2.3.5.tar.bz2 --strip-components=2 -C docs
sed -i -r 's:.*(#.*BYTE.*) .*:\1:' include/freetype/config/ftoption.h
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr &&
make
make install &&
install -v -m755 -d /usr/share/doc/freetype-2.3.5 &&
cp -v -R docs/* /usr/share/doc/freetype-2.3.5
cd ..
rm -rf freetype-2.3.5

##########16 FontConfig
tar xvf fontconfig-2.6.0.tar.gz
cd fontconfig-2.6.0
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" \
./configure --prefix=/usr --sysconfdir=/etc \
    --disable-docs --localstatedir=/var --without-add-fonts \
    --with-docdir=/usr/share/doc/fontconfig-2.6.0 &&
make
make install &&
install -v -m644 doc/*.3 /usr/share/man/man3 &&
install -v -m644 doc/*.5 /usr/share/man/man5 &&
install -v -m755 -d /usr/share/doc/fontconfig-2.6.0/fontconfig-devel &&
install -v -m644 doc/*.{html,pdf,txt} /usr/share/doc/fontconfig-2.6.0 &&
install -v -m644 doc/fontconfig-devel/* /usr/share/doc/fontconfig-2.6.0/fontconfig-devel
cd ..
rm -rf fontconfig-2.6.0

# #######17 Xorg7/Libraries
cd lib
for package in $(grep -v '^#' ../Lib-20081023.wget)
do
  packagedir=$(echo $package | sed 's/.tar.bz2//')
  tar -xf $package
  cd $packagedir
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG &&
  make
  make install
  cd ..
  rm -rf $packagedir
  echo  $packagedir ===========================END
done 2>&1 | tee -a ../xorg-lib-7.4-compile.log #log the entire loop
cd ..

#libX11这个包可以使用--enable-loadable-i18n这个参数,它将打开i18n的国际化支持。所以建议打开,你可以单独编译一下这个包。其它的参数可以通过./configure --help来查看。

cd lib
tar xvf libX11-1.1.5.tar.bz2
cd libX11-1.1.5
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure --prefix=$XORG_PREFIX --sysconfdir=/etc   --mandir=$XORG_PREFIX/share/man --localstatedir=/var  --enable-loadable-i18n  &&
  make
  make install
cd ..
rm -rf libX11-1.1.5
cd ..

#######18 Xorg7/libdrm
tar xvf  drm-20080719.tar.bz2
cd drm-20080719
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG &&
make &&
make install
cd ..
rm -rf drm-20080719

#####19 Xorg7/MesaLib ##here need a cmd named "makedepend". if u dont have, install it  plz .
tar xvf MesaLib-7.1.tar.gz
tar xvf MesaDemos-7.1.tar.bz2
tar xvf MesaGLUT-7.1.tar.bz2
cd Mesa-7.1
ln -sf linux-dri configs/current
echo 'X11_INCLUDES = $(shell pkg-config --cflags-only-I x11)' >> configs/current &&
echo 'CFLAGS += $(X11_INCLUDES)' >> configs/current &&
echo 'EXTRA_LIB_PATH = $(shell pkg-config --libs-only-L x11)' >> configs/current &&
echo "DRI_DRIVER_INSTALL_DIR = ${XORG_PREFIX}/lib/xorg/modules/dri" >> configs/current &&
echo "INSTALL_DIR = /usr" >> configs/current &&
echo "LIB_DIR = lib" >> configs/current &&
echo "DRI_DIRS += swrast" >> configs/current
echo 'DEFINES += -DUSE_XCB' >> configs/current &&
echo 'X11_INCLUDES += $(shell pkg-config --cflags-only-I xcb x11-xcb xcb-glx)' >> configs/current &&
echo 'GL_LIB_DEPS += $(shell pkg-config --libs xcb x11-xcb xcb-glx)' >> configs/current
make default
make install
make -C progs/xdemos glxinfo glxgears &&
install -m755 -v progs/xdemos/{glxinfo,glxgears} /usr/bin
cd ..
#rm -rf Mesa-7.1
#source is needed by xserver, if del, when configure the xserver should del this cmd:   --with-mesa-source="${PWD}/../Mesa-7.1" \
#here last so ****ing long.

#######20 Xorg7/xbitmaps
tar xvf xbitmaps-1.0.1.tar.bz2
cd xbitmaps-1.0.1
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"  ./configure $XORG_CONFIG
make install
cd ..
rm -rf xbitmaps-1.0.1

########21 Libpng
##because Xcursorgen needs it
tar xvf libpng-1.2.34.tar.bz2
cd libpng-1.2.34
patch -Np1 -i ../libpng-1.2.34-apng-1.patch
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure --prefix=/usr &&
make
make install &&
install -v -m755 -d /usr/share/doc/libpng-1.2.34 &&
install -v -m644 README libpng-1.2.34.txt /usr/share/doc/libpng-1.2.34
cd ..
rm -rf libpng-1.2.34


######22 Xorg7/Apps
cd app
for package in $(grep -v '^#' ../App-20081023.wget)
do
  packagedir=$(echo $package | sed 's/.tar.bz2//')
  tar -xf $package
  cd $packagedir
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG &&
  make
  make install
  cd ..
  rm -rf $packagedir
  echo  $packagedir ===========================END
done 2>&1 | tee -a ../xorg-app-7.4-compile.log #log the entire loop
cd ..

#####23 Perl Module XML:arser
#needs Expat. we had installed yet.
tar xvf XML-Parser-2.36.tar.gz
cd XML-Parser-2.36
sed -i 's@<ERL_DESTDIR>@@g' Makefile
perl Makefile.PL &&
make &&
make test
make install
cd ..
rm -rf XML-Parser-2.36

#####24 Intltool
tar xvf intltool-0.40.5.tar.bz2
cd intltool-0.40.5
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"  ./configure --prefix=/usr &&
make
make install &&
install -v -m644 -D doc/I18N-HOWTO \
    /usr/share/doc/intltool-0.40.5/I18N-HOWTO
cd ..
rm -rf intltool-0.40.5

# ####25 Xorg7/Data : xcursor-themes and xkeyboard-config
#25.1  xcursor-themes-1.0.1.tar.bz2
tar xvf xcursor-themes-1.0.1.tar.bz2
cd xcursor-themes-1.0.1
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"  ./configure $XORG_CONFIG &&
make &&
make install
cd ..
rm -rf xcursor-themes-1.0.1
#25.2xkeyboard-config-1.3.tar.bz2
tar xvf xkeyboard-config-1.3.tar.bz2
cd xkeyboard-config-1.3
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"   ./configure $XORG_CONFIG \
    --with-xkb-base=${XORG_PREFIX}/share/X11/xkb \
    --with-xkb-rules-symlink=xorg --enable-compat-rules &&
make &&
make install
cd ..
rm -rf xkeyboard-config-1.3

##### 26 Xorg7/Fonts
cd font
for package in $(grep -v '^#' ../Font-20081023.wget)
do
  packagedir=$(echo $package | sed 's/.tar.bz2//')
  tar -xf $package
  cd $packagedir
  sed -i 's{libdir}/X11/fonts:/usr/share/fonts:g' configure &&
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG
  make
  make install
  cd ..
  rm -rf $packagedir
  echo  $packagedir ===========================END
done 2>&1 | tee -a ../xorg-font-7.4-compile.log #log the entire loop
cd ..


######27 OpenSSL
tar xvf openssl-0.9.8j.tar.gz
cd openssl-0.9.8j
patch -Np1 -i ../openssl-0.9.8j-fix_manpages-1.patch &&
patch -Np1 -i ../openssl-0.9.8j-build_fix-1.patch &&
patch -Np1 -i ../openssl-0.9.8j-mips_support-1.patch &&
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./config --openssldir=/etc/ssl --prefix=/usr shared &&
make MANDIR=/usr/share/man
make MANDIR=/usr/share/man install &&
cp -v -r certs /etc/ssl &&
install -v -d -m755 /usr/share/doc/openssl-0.9.8j &&
cp -v -r doc/{HOWTO,README,*.{txt,html,gif}} \
    /usr/share/doc/openssl-0.9.8j
cd ..
rm -rf openssl-0.9.8j
#PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"  needed here ???

#######28Xorg7/Xserver
tar xvf xorg-server-1.5.0.tar.bz2
cd xorg-server-1.5.0
patch -Np1 -i ../xorg-server-1.5.0-paint_it_black-1.patch
sed -i '/xpconfigdir=/s@=.*@=$datadir/X11/xserver@' configure &&
sed -i '/-DXPRINTDIR/s/libdir/datadir/' hw/xprint/Makefile.in &&
./configure $XORG_CONFIG --enable-install-setuid \
    --with-dri-driver-path="${XORG_PREFIX}/lib/xorg/modules/dri" \
    --with-fontdir="/usr/share/fonts" \
    --with-mesa-source="${PWD}/../Mesa-7.1" \
    --disable-dri2
make
make install
cd ..
rm -rf xorg-server-1.5.0
#because the mesa had installed ,     --with-mesa-source="${PWD}/../Mesa-7.1"  can be deleted...
#make sure where the derector your mesa-source is..
#PKG_CONFIG_PATH="${PKG_CONFIG_PATH}"  needed  here ????


######29Xorg7/Drivers
#Edit Driver-20081023.wget and completely remove the drivers you don't need.
#I just keep three: xf86-input-mouse  xf86-input-keyboard  xf86-video-nv
cd driver
for package in $(grep -v '^#' ../Driver-20081023.wget)
do
  packagedir=$(echo $package | sed 's/.tar.bz2//')
  tar -xf $package
  cd $packagedir
  PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure ${XORG_CONFIG} &&
  make
  make install
  cd ..
  rm -rf $packagedir
  echo  $packagedir ===========================EDN
done 2>&1 | tee -a ../xorg-font-7.4-compile.log #log the entire loop
cd ..
#if you keep xf86-input-magictouch fix to it:
#sed -i "/#include <xf86_ansic.h>/d" src/xf86MagicTouch.c
#if you keep xf64-video-cyrix fix to it :
#sed -i "/#define _CYRIX_H_/a\typedef struct pci_device *pciVideoPtr;" src/cyrix.h


#########30 Xorg7/xterm You can find another one taht surport  Chinrse well.
tar xvf xterm-237.tgz
cd xterm-237
PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" ./configure $XORG_CONFIG --enable-wide-chars \
    --with-app-defaults=${XORG_PREFIX}/share/X11/app-defaults &&
make
make install &&
make install-ti
cd ..
rm -rf xterm-237

#######31 Xorg7/rman  
#rman is a utility to convert manual pages into other formats.
#But i didnt use it ever. And i dont know what is it .
tar xvf rman-3.2.tar.gz
cd rman-3.2
sed -i -e "s@/opt/local@$XORG_PREFIX@" \
    -e "s@/usr/local@$XORG_PREFIX/share@" \
    -e "s@share/man@man@" Makefile
make
make install
cd ..
rm rman-3.2

########32 Xorg7/Config
#Configuring the X Window System
#FHS Symlinks
ln -sv ${XORG_PREFIX}/bin /usr/bin/X11
ln -sv ${XORG_PREFIX}/include/X11 /usr/include/X11
ln -sv ${XORG_PREFIX}/lib/X11 /usr/lib/X11
#Creating /etc/X11/xorg.conf
cd ~ &&
Xorg -configure
#edit xorg.conf.new
#test
X -config ~/xorg.conf.new
#work?? OK. install  to /etc/X11/xorg.conf
install -v -m755 -D ~/xorg.conf.new /etc/X11/xorg.conf


############
其实也没什么好总结的了
就是出了几个问题自己好记住以后不再犯而已。。。

1.关于PATH 。就这一步搞了我很多次呀,快哭死了。
chroot "$LFS" /usr/bin/env -i \
HOME=/root TERM="$TERM" PS1='\u:\w\$ ' \
PATH=/bin:/usr/bin:/sbin:/usr/sbin \
/bin/bash --login
一开始我是这样chroot进来装的,结果到了第25步的xcursor-themes的./configure时就说没有找到xcursorgen ,但明明在app的一步时就装了这个东西的了,实在上的确是装了,只不过是装在了/usr/X11R7/bin下面,因为一开始我就写义安装到/usr/X11R7,但这里的PATH没有这个目录,人家./configure就当然找不到啦。。
后来chroot时这样来搞就行了
chroot "$LFS" /usr/bin/env -i \
HOME=/root TERM="$TERM" PS1='\u:\w\$ ' \
PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/X11R7/bin \
/bin/bash --login
当然我也在纯LFS下面装过,也是这种问题,现在就改/etc/profile,加入:
  1. if [ "`id -u`" -eq 0 ]; then
  2. PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/X11R7/b$
  3. else
  4.   PATH="/usr/local/bin:/usr/bin:/bin:/usr/X11R7/bin"
  5. fi
复制代码
其实最后一步的
ln -sv ${XORG_PREFIX}/bin /usr/bin/X11
ln -sv ${XORG_PREFIX}/include/X11 /usr/include/X11
ln -sv ${XORG_PREFIX}/lib/X11 /usr/lib/X11
这三个命令也解决了这个问题。可是当然看到的时候我就不知道重搞了多少次。。我甚至怀疑过是我的LFS太低版本,又或者LFS哪里做得不对,又或者内核编译出问题。呵呵。新手就是这样。


2.这个命令makedepend,装MesaLib时是要用得上,但我的LFS是没有的,不知道别人兄台的有没有,就只好一开始就装上。。。

3.有一些包依赖到Python,记得BLFS上面好像,没有,不知道这里为什么会有,呵呵。一开始没装,有一些包就说我没有Python。。

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?注册

x
发表于 2009-2-19 11:01:12 | 显示全部楼层
谢谢,这样的好文章一定要收藏。
回复 支持 反对

使用道具 举报

发表于 2009-2-19 18:40:01 | 显示全部楼层
谢谢lz的总结,前两天我安装Xserver出错,好像是差MesaLib,今天晚上继续
回复 支持 反对

使用道具 举报

发表于 2009-5-1 12:01:23 | 显示全部楼层
一步步按照楼主的做法,安装MesaLib总是装不过,我是在纯LFS下安装,不知道怎么样的才能通过呢
回复 支持 反对

使用道具 举报

发表于 2009-5-15 09:43:53 | 显示全部楼层
請問版主
我目前募嘗試依照你的方式編譯xorg7.4,請問除了上面提到要安裝的套件包以外,還有什麼編譯時需要的套件呢?(例如:GCC)
回复 支持 反对

使用道具 举报

发表于 2009-5-16 08:08:01 | 显示全部楼层
Post by malu;1987392
請問版主
我目前募嘗試依照你的方式編譯xorg7.4,請問除了上面提到要安裝的套件包以外,還有什麼編譯時需要的套件呢?(例如:GCC)


视乎你要编译的包有何依赖,动手前请详细阅读 BLFS 手册或 CBLFS 的 wiki
回复 支持 反对

使用道具 举报

发表于 2009-5-18 17:24:10 | 显示全部楼层
請問,板主:
我在步驟28,安裝xserver時,出現下列錯誤訊息:
..............
checking for GL... configure: error: Package requirements (glproto >= 1.4.9 gl >= 7.1.0) were not met:

No package 'glproto' found

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables GL_CFLAGS
and GL_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.

make: *** No targets specified and no makefile found.  Stop.
make: *** No rule to make target `install'.  Stop.

我有手動安裝glproto-1.4.9,但是gl-7.1.0我找不到這套件
而網路上有看到相同問題的人提到gcc版本會造成這錯誤,不能用gcc4.3,我改成gcc-4.1還是不行(我是使用debian5.0)

請問這問題該如何解決呢?
回复 支持 反对

使用道具 举报

发表于 2009-5-19 19:41:39 | 显示全部楼层
我用 gcc-4.4 来编译 xorg-7.4 都未见异常,gcc-4.3 会不能用???
請問,板主:
我在步驟28,安裝xserver時,出現下列錯誤訊息:
步骤 28 即是什麽步骤?

看你的问题好像是头文件未齐?

提问时最好说明是手册第几章第几节
回复 支持 反对

使用道具 举报

发表于 2009-5-20 09:49:50 | 显示全部楼层
板主你好:
我說的步驟28是指上面"小李飛刀"大大所提安裝xorg7.4的第28步,如下:

#######28Xorg7/Xserver
tar xvf xorg-server-1.5.0.tar.bz2
cd xorg-server-1.5.0
patch -Np1 -i ../xorg-server-1.5.0-paint_it_black-1.patch
sed -i '/xpconfigdir=/s@=.*@=$datadir/X11/xserver@' configure &&
sed -i '/-DXPRINTDIR/s/libdir/datadir/' hw/xprint/Makefile.in &&
./configure $XORG_CONFIG --enable-install-setuid \
--with-dri-driver-path="${XORG_PREFIX}/lib/xorg/modules/dri" \
--with-fontdir="/usr/share/fonts" \
--with-mesa-source="${PWD}/../Mesa-7.1" \
--disable-dri2
make
make install
cd ..
rm -rf xorg-server-1.5.0
#because the mesa had installed , --with-mesa-source="${PWD}/../Mesa-7.1" can be deleted...
#make sure where the derector your mesa-source is..
#PKG_CONFIG_PATH="${PKG_CONFIG_PATH}" needed here ????
回复 支持 反对

使用道具 举报

发表于 2009-5-21 21:31:18 | 显示全部楼层
MesaLib 装了没?
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表