———————————————安装swftools
http://www.swftools.org/swftools-0.9.1.tar.gz
[root@centos swftools-0.9.1]# tar zxvf /home/xz/swftools-0.9.1.tar.gz -C /home/rt/
[root@centos swftools-0.9.1]# cd /home/rt/swftools-0.9.1/
[root@centos swftools-0.9.1]# ./configure –prefix=/usr/local/swftools
报错
checking build system type… Invalid configuration `x86_64-unknown-linux-‘: machine `x86_64-unknown-linux’ not recognized
configure: error: /bin/sh ./config.sub x86_64-unknown-linux- failed
运行 yum install gcc* automake zlib-devel libjpeg-devel giflib-devel freetype-devel
[root@centos swftools-0.9.1]# ./configure –prefix=/usr/local/swftools
如果报错
ERROR:You need zlib to compile swftools
运行 yum install zlib-devel
make make install安装xpdf语言包
到xpdf网站:http://foolabs.com/xpdf/download.html 上下载xpdf-chinese-simplified.tar.gz文件(ftp://ftp.foolabs.com/pub/xpdf/xpdf-chinese-simplified.tar.gz),下载下来后,解压
然后下载
stsong.tar.gz(http://wiki.bsdn.org/download/attachments/3964937/stsong.tar.gz?version=1&modificationDate=1316678548000)文件下载下来,解压后将其中的STSONG.TTF字体文件放在xpdf-chinese-simplified所在目录下的CMap目录下,然后打开xpdf-chinese-simplified所在目录下add-to-xpdfrc文件
[root@centos swftools-0.9.1]# vi /home/rt/xpdf-chinese-simplified/add-to-xpdfrc
#—– begin Chinese Simplified support package (2011-sep-02)
cidToUnicode Adobe-GB1 /usr/local/share/xpdf/chinese-simplified/Adobe-GB1.cidToUnicode
unicodeMap ISO-2022-CN /usr/local/share/xpdf/chinese-simplified/ISO-2022-CN.unicodeMap
unicodeMap EUC-CN /usr/local/share/xpdf/chinese-simplified/EUC-CN.unicodeMap
unicodeMap GBK /usr/local/share/xpdf/chinese-simplified/GBK.unicodeMap
cMapDir Adobe-GB1 /usr/local/share/xpdf/chinese-simplified/CMap
toUnicodeDir /usr/local/share/xpdf/chinese-simplified/CMap
displayCIDFontTT Adobe-GB1 /usr/share/xpdf-chinese-simplified/CMap/STSONG.TTF 添加这一行目录可以改
#fontFileCC Adobe-GB1 /usr/…./gkai00mp.ttf
#—– end Chinese Simplified support package
[root@centos swftools-0.9.1]# mv /home/rt/xpdf-chinese-simplified/ /usr/share/ /usr/local/swftools/bin/pdf2swf /home/xz/lampp.pdf -o /home/xz/caa.swf -s languagerdir=/usr/share/xpdf-chinese-simplified/ -s flashversion=9 转换ok参考:http://www.cyberciti.biz/faq/linux-install-language-support/
http://deidara.blog.51cto.com/400447/271533———————————————————————安装apache
http://122.228.244.153/8/tech.down.sina.com.cn/20110913/1696ae62/httpd-2.2.21.tar.bz2?fn=&ssig=v1LrjynZTj&Expires=1322203433&KID=sae,230kw3wk15&ip=1322124233,124.193.124.138 下载httpd-2.2.21.tar.bz2先安装apr、apr-util 安装svn时要用到
http://apache.etoak.com/apr/apr-1.4.5.tar.gz
http://apache.etoak.com/apr/apr-util-1.3.12.tar.gz
安装apr、apr-util
[root@centos apr-1.4.5]# # ./configure Cprefix=/usr/local/apr && make && make install
[root@centos apr-1.4.5]# tar zxvf /home/xz/apr-util-1.3.12.tar.gz -C /home/rt/
[root@centos apr-1.4.5]# cd /home/rt/apr-util-1.3.12/
[root@centos apr-util-1.3.12]# ./configure –with-apr=/usr/local/apr/ && make && make install安装apache
[root@centos ~]# tar xvf /home/xz/httpd-2.2.21.tar.bz2 -C /home/rt/
[root@centos ~]# cd /home/rt/httpd-2.2.21/
[root@centos httpd-2.2.21]# ./configure –prefix=/usr/local/apache –enable-maintainer-mode –enable-so –enable-dav –with-mpm=worker –with-apr=/usr/local/apr/bin/apr-1-config –with-apr-util=/usr/local/apr/bin/apu-1-config –with-config-file-path=/usr/local/apache/conf
[root@centos httpd-2.2.21]# make ; make insatll 安装完成
[root@centos httpd-2.2.21]# /usr/local/apache/bin/apachectl start
启动apache 出现
httpd: Could not reliably determine the server’s fully qualified domain name, using ::1 for ServerName
只要把/conf/httpd.conf文件的#ServerName 前的#去掉就好了。
浏览器输入http://127.0.0.1 出现 It works! 安装完成 在/etc/rc.d/rc.local中增加启动apache的命令,例如:/usr/local/httpd/bin/apachectl start 设置apache开机启动————————————————————————-安装php
http://cn.php.net/distributions/php-5.3.8.tar.gz
[root@centos ~]# tar zxvf /home/xz/php-5.3.8.tar.gz -C /home/rt/
[root@centos ~]# cd /home/rt/php-5.3.8/
[root@centos php-5.3.8]# ./configure –prefix=/usr/local/php –with-apxs2=/usr/local/apache/bin/apxs –with-config-file-path=/usr/local/php/etc
报错
configure: error: xml2-config not found. Please check your libxml2 installati
安装libxml2-devel yum install libxml2-devel
[root@centos php-5.3.8]# ./configure –prefix=/usr/local/php –with-apxs2=/usr/local/apache/bin/apxs –with-config-file-path=/usr/local/php/etc
[root@centos php-5.3.8]# make ;make install 安装完成
复制php.ini-development为php.ini,并存放到/usr/local/php/etc目录下!
[root@centos php-5.3.8]# cp /home/rt/php-5.3.8/php.ini-development /usr/local/php/etc/php.ini
编辑/usr/local/php/etc/php.ini文件,找到如下的一行
;default_charset = “iso-8859-1”
在这行下面加一行
default_charset = “gb2312
配置apache+php
找到#AddType application/x-gzip .tgz 这行,在下面加一行。前面不要加#号。
AddType application/x-httpd-php .php
找到下面一行在后面加上index.php,这表示网站的默认页也能够为index.php
DirectoryIndex index.html index.html.var index.php
找到servername 改成 127.0.0.或localhost
让后我们顺手下个测试php的页面吧
[root@centos ~]# vi /usr/local/apache/htdocs/test.php写入
<?php phpinfo(); ?> /usr/www/html/test.php即可,到此处php+apache安装成功———————————————————————–安装mysql
安装cmake (mysql-5.5.X 以后的版本都要用cmake)
http://www.cmake.org/files/v2.8/cmake-2.8.4.tar.gz
[root@centos ~]# tar zxvf /home/xz/cmake-2.8.4.tar.gz -C /home/rt/
[root@centos ~]# cd /home/rt/cmake-2.8.4/
[root@centos cmake-2.8.4]#yum -y install gcc
[root@centos cmake-2.8.4]#yum -y install gcc-c++
[root@centos cmake-2.8.4]#./configure –prefix=/usr/local/cmake
gmake ; gmake install
运行一下防止出现没必要的错误 yum -y install gcc yum -y install gcc-c++ 安装mysql
http://182.84.98.22:82/down/mysql-5.5.17.tar.gz
[root@centos ~]# tar zxvf /home/xz/mysql-5.5.17.tar.gz -C /home/rt/
[root@centos ~]# cd /home/rt/mysql-5.5.17/
[root@centos mysql-5.5.17]# mkdir /usr/local/mysql/
[root@centos mysql-5.5.17]# /usr/local/cmake/bin/cmake -DCMAKE_INSTALL_PREFIX=/usr/local/mysql -DMYSQL_UNIX_ADDR=/usr/local/mysql/data/mysql/mysql.sock -DDEFAULT_CHARSET=utf8 -DDEFAULT_COLLATION=utf8_general_ci -DWITH_EXTRA_CHARSETS:STRING=utf8,gbk -DWITH_MYISAM_STORAGE_ENGINE=1 -DWITH_INNOBASE_STORAGE_ENGINE=1 -DWITH_MEMORY_STORAGE_ENGINE=1 -DWITH_READLINE=1 -DENABLED_LOCAL_INFILE=1 -DMYSQL_DATADIR=/usr/local/mysql/data/mysql -DMYSQL_USER=mysql -DMYSQL_TCP_PORT=3306-DCMAKE_INSTALL_PREFIX=/usr/local/mysql
-DMYSQL_UNIX_ADDR=/usr/local/mysql/data/mysql/mysql.sock
-DDEFAULT_CHARSET=utf8
-DDEFAULT_COLLATION=utf8_general_ci
-DWITH_EXTRA_CHARSETS:STRING=utf8,gbk
-DWITH_MYISAM_STORAGE_ENGINE=1
-DWITH_INNOBASE_STORAGE_ENGINE=1 INNODB 引擎
-DWITH_MEMORY_STORAGE_ENGINE=1
-DWITH_READLINE=1
-DENABLED_LOCAL_INFILE=1
-DMYSQL_DATADIR=/usr/local/mysql/data/mysql
-DMYSQL_USER=mysql
-DMYSQL_TCP_PORT=3306报错
— Could NOT find Curses (missing: CURSES_LIBRARY CURSES_INCLUDE_PATH)
CMake Error at cmake/readline.cmake:83 (MESSAGE):
Curses library not found. Please install appropriate package, remove CMakeCache.txt and rerun cmake.On Debian/Ubuntu, package name is libncurses5-dev, on Redhat and derivates it is ncurses-devel.
Call Stack (most recent call first):
cmake/readline.cmake:118 (FIND_CURSES)
cmake/readline.cmake:214 (MYSQL_USE_BUNDLED_READLINE)
CMakeLists.txt:257 (MYSQL_CHECK_READLINE)
— Configuring incomplete, errors occurred!
需要安装ncurses-devel包
[root@centos mysql-5.5.17]# yum -y install ncurses-devel
删除 /usr/local/cmake-2.8.4/CMakeCache.txt,重新运行cmake 注意这个运行顺序哦
[root@centos mysql-5.5.17]# make ; make install 安装完成更改文件夹权限和初始化数据库
[root@centos mysql-5.5.17]# cp support-files/my-medium.cnf /etc/my.cnf
[root@centos mysql-5.5.17]# chmod 755 /usr/local/mysql/scripts/mysql_install_db
[root@centos mysql-5.5.17]# /usr/local/mysql/scripts/mysql_install_db –user=mysql –basedir=/usr/local/mysql/ –datadir=/usr/local/mysql/data/mysql/
[root@centos mysql-5.5.17]# groupadd mysql
[root@centos mysql-5.5.17]# useradd -g mysql mysql
[root@centos mysql-5.5.17]# chown mysql.mysql -R /usr/local/mysql/data/mysql/
启动mysql
[root@centos mysql-5.5.17]# /usr/local/mysql/support-files/mysql.server start
修改root密码
[root@centos mysql-5.5.17]# /usr/local/mysql/bin/mysqladmin -u root password ‘1111’
开机启动mysql
[root@centos mysql-5.5.17]# cp support-files/mysql.server /etc/init.d/mysql
[root@centos mysql-5.5.17]# chkconfig mysql on
测试使
[root@centos mysql-5.5.17]# /usr/local/mysql/bin/mysql -u root -p 配置mysql完成关于apache和mysql在linux重启后自启动的问题
/etc/rc.d/rc.local文件中直接添加如下语句
/usr/local/apache/bin/apachectl start
/usr/local/mysql/support-files/mysql.server start————————————————————————–安装subversion-1.7.7.tar.gz
http://labs.renren.com/apache-mirror/subversion/subversion-1.7.1.tar.gz
http://www.sqlite.org/sqlite-autoconf-3070900.tar.gz[root@centos ~]# tar zxvf /home/xz/subversion-1.7.1.tar.gz -C /home/rt
[root@centos ~]# cd /home/rt/subversion-1.7.1/
[root@centos subversion-1.7.1]# ./configure –prefix=/usr/local/subversion –with-apxs=/usr/local/apache/bin/apxs –with-apr=/usr/local/apr/bin/apr-1-config –with-apr-util=/usr/local/apr/bin/apu-1-config –with-ssl –with-neon=/usr/neon –enable-maintainer-mode CPPFLAGS=”-Izlib/ -Lzlib/”
报错
An appropriate version of sqlite could not be found. We recommmend
3.7.6.3, but require at least 3.6.18.
Please either install a newer sqlite on this systemorget the sqlite 3.7.6.3 amalgamation from:
http://www.sqlite.org/sqlite-amalgamation-3.7.6.3.tar.gz
unpack the archive using tar/gunzip and copy sqlite3.c from the
resulting directory to:
/home/rt/subversion-1.7.1/sqlite-amalgamation/sqlite3.c
configure: error: Subversion requires SQLite
下载
http://www.sqlite.org/sqlite-autoconf-3070900.tar.gz
[root@centos subversion-1.7.1]# tar zxvf /home/xz/sqlite-autoconf-3070900.tar.gz -C /home/rt/
[root@centos subversion-1.7.1]# mkdir sqlite-amalgamation
[root@centos subversion-1.7.1]# cp /home/rt/sqlite-autoconf-3070900/sqlite3.c /home/rt/subversion-1.7.1/sqlite-amalgamation/
再次
[root@centos subversion-1.7.1]# ./configure –prefix=/usr/local/subversion –with-apxs=/usr/local/apache/bin/apxs –with-apr=/usr/local/apr/bin/apr-1-config –with-apr-util=/usr/local/apr/bin/apu-1-config –with-ssl –with-neon=/usr/neon –enable-maintainer-mode CPPFLAGS=”-Izlib/ -Lzlib/”
安装完成
configure 可能会出现以下错误
configure: maintainer-mode: adding GCC warning flags
configure: error: Cwith-zlib requires an argument.安装zlib,下载subversion-deps-1.6.6.tar.bz2
[root@svn soft]# wget http://subversion.tigris.org/downloads/subversion-deps-1.6.6.tar.bz2
[root@svn soft]# cd subversion-1.6.6/zlib/
[root@svn zlib]# ./configure Cshared
[root@svn zlib]# makelibsvn_ra_neo n-1.so :undefined reference to `SSL_SESSION_cmp’ error 1
http://www.webdav.org/neon下载最新版本neon-0.29.3,并将其单独安装到/usr/neon 进入subversion目录,将serf 目录删除;[root@centos subversion-1.7.1]# make
make 以后出错
/usr/bin/ld: cannot find -lexpat
collect2: ld returned 1 exit status
make: *** [subversion/svn/svn] 错误 1
beiyoong ln -sv /usr/lib64/libexpat.so /lib64/libexpat.so.0.5.0
此时可以使用这样的命令来解决: yum -y install libtool-l expat[root@centos subversion-1.7.1]# make install配置subversion
创建账号密码文件
[root@centos subversion-1.7.1]# /usr/local/apache/bin/htpasswd -c /usr/local/subversion/passwd.conf apache
New password:
Re-type new password:
Adding password for user apache
注意:第一次设置用户密码要加入 Cc 这个参数
创建版本库
[root@centos subversion-1.7.1]# mkdir -p /home/svnroot/test
[root@centos subversion-1.7.1]# /usr/local/subversion/bin/svnadmin create /home/svnroot/test/
到/home/svnroot/test/下看是不是多了文件,多了就是说明创建成功
配置apache的httpd.conf
打开apache的conf/httpd.conf,安装subversion后,apache的conf/httpd.conf文件会自动增加模块
LoadModule dav_svn_module modules/mod_dav_svn.so
LoadModule authz_svn_module modules/mod_authz_svn.so 如果没有就手动加一下在这行下面前面不要带# LoadModule php5_module modules/libphp5.so相应的so文件也自动copy到了apache/modules。这些工作就不用自己动手了。在进行源代码管理时,为了安全起见,需要对用户的权限进行控制,主要通过三个配置文件来实现,svnservice.conf、passwd、authz,第一个文件指明是否需要进行访问控制以及第二、三个文件的位置,第二个文件存放用户帐号信息,第三个文件存放用户的访问权限,具体配置如下:
1.打开svnserve.conf文件,把auth-access=write前面的#号去掉,使受权用户可以进行写操作
2.把password-db=passwd前面的#号去掉,表明密码文件为当前目录下的passwd文件
3.把auth-db=authz前面的#号去掉,表明用户访问权限文件为当前目录下的authz文件
4.打开passwd文件,在末行添加需要的帐号,比如:test=123456
5.打开authz文件,在[/]一行下面添加test=rw,表明数据仓库的根目录下的所有目录,test都可进行读写操作
6.再添加一行*=r,表明其他帐号可以进行只读操作
7.在该文件中还可以为用户分组,添加到[groups]下面,比如:admin=sinboy,others=u1,u2
8.还可以对根目录下的子目录进行具体的权限控制,只需要添加相应目录,比如:
[/web]
u1=rw
*=
表明web子目录只允许u1帐号进行读写操作,禁止其他帐号访问
它的缺点是:
1.对外提供服务时,有可能受到防火墙的阻隔,造成服务无法访问
2.并且它的密码文件是明文显示,没有进行MD5加密,存在安全隐患
3.只能启动一个数据仓库,如果想要创建多个数据仓库,必须启动多个svnserve服务进程需要自己动手修改apache下的httpd.conf最后增加以下内容<VirtualHost *:80>
ServerName svn.server.com
DirectoryIndex index.html <Location /svn>
DAV svn
SVNPath /home/svnroot/test (此处配置你的版本库根目录) 必须和creat 的路径一样
AuthType Basic (连接类型设置 基本验证)
AuthName “Welcome to MySVN” (此处字符串内容修改为提示对话框标题)
AuthUserFile /usr/local/subversion/passwd.conf (此处修改为访问版本库用户的文件,用apache 的htpasswd命令生成)
AuthzSVNAccessFile /home/svnroot/test/conf/authz 权限控制文件
Require valid-user
</Location>
</VirtualHost>http://127.0.0.1/svn/ 或 http://svn.server.com/svn
出现 svn – Revision 0: / 到此svn 也就配置完成
centos6.0 安装apache php mysql subversion(svn) swftools(pdf转换swf)
相关推荐
-      centos mysql 因Out of memory停止服务
-      linode vps系统centos的常用维护命令
-      centos升级iptables到最新版
-      swftools转换文件时线程堵塞问题的解决方法
-      万网centos 64位升级PHP 5.3
-      仿百度文库方案,openoffice.org 3+swftools+flexpaper
-      文档生成技术细节 提取文字图片
-      SWFTools一些参数用法
评论前必须登录!
注册