RJ45 jack (tenon faces to ground..):
Normal:
Both jacks: 白橘 橘 白綠 藍 白藍 綠 白棕 棕
Cross-over:
a jack: 白綠 綠 白橘 藍 白藍 橘 白棕 棕
b jack: 白橘 橘 白綠 藍 白藍 綠 白棕 棕
Cyber memos for my personal knowledge.
2009-01-16
2009-01-08
How to install p7zip 4.61 - UNIX/Linux version of 7-zip on openSUSE 11.1
I install it because I love it...;=)
Again, I'd like to compile it via source code by myself.
BTW, if you are NOT an advanced user I think, you should try the pre-built binary package instead of compiling it by yourself.
Well, if you now stay with M$ Windows I still recommend it. Check it out.
1. Get source code package from here. Currently, latest verson is 4.61.
2. My box is openSUSE 11.1 x86_64, T9500 CPU...;-). So I just un-tar and cd into the directory:
$ cd ./p7zip_4.61/
$ sudo zypper search -d yasm
I got output such as follows:
正在載入套件庫資料...
讀取已安裝的套件...
S | 名稱 | 摘要 | 類型
Again, I'd like to compile it via source code by myself.
BTW, if you are NOT an advanced user I think, you should try the pre-built binary package instead of compiling it by yourself.
Well, if you now stay with M$ Windows I still recommend it. Check it out.
1. Get source code package from here. Currently, latest verson is 4.61.
2. My box is openSUSE 11.1 x86_64, T9500 CPU...;-). So I just un-tar and cd into the directory:
$ cd ./p7zip_4.61/
$ sudo zypper search -d yasm
I got output such as follows:
正在載入套件庫資料...
讀取已安裝的套件...
S | 名稱 | 摘要 | 類型
--+----------+--------------------------------------------------+-----
---| yasm | YASM is a complete rewrite of the NASM assembler | 套件
3. Install yasm:
$ sudo zypper install yasm
I got output such as follows:
正在載入套件庫資料...
讀取已安裝的套件...
正在解決套件相依性...
將會安裝下列新的套件:
yasm
全部下載大小: 240.0 K。 完成操作後,將增加 654.0 K 的使用。
要繼續嗎? [是/否]: y
正在取出 套件 yasm-0.6.2-1.75.x86_64 (1/1), 240.0 K (已解開 654.0 K)
正在取出: yasm-0.6.2-1.75.x86_64.rpm [完成]
正在安裝: yasm-0.6.2-1.75 [完成]
4. Modify ./makefile.machine. Here is my makefile.machine:
$ cp makefile.machine makefile.machine.backup
$ cp makefile.linux_x86_asm_gcc_4.X makefile.machine
$ vim ./makefile.machine
I modify ./makefile.machine as following RED words for my T9500 x86_64 system:
#
# makefile for Linux (x86, PPC, alpha ...)
#
OPTFLAGS=-O
ALLFLAGS=${OPTFLAGS} -m64 -s \
-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE \
-DNDEBUG -D_REENTRANT -DENV_UNIX \
$(LOCAL_FLAGS)
CXX=g++ $(ALLFLAGS) -DHAVE_GCCVISIBILITYPATCH -fvisibility=hidden -fvisibility-inlines-hidden
CC=gcc $(ALLFLAGS)
CC_SHARED=-fPIC
LINK_SHARED=-fPIC -shared
ASM=yasm -f elf -m amd64
LOCAL_LIBS=-lpthread
LOCAL_LIBS_DLL=$(LOCAL_LIBS) -ldl
CPU=x64
OBJ_CRC32=$(OBJ_CRC32_x86_64)
5. Of course, make it!
$ make clean; make all2; sudo ./install.sh
Note that if you need 7zr just replace above "make all2" with "make all3".
Done...;-)
---| yasm | YASM is a complete rewrite of the NASM assembler | 套件
3. Install yasm:
$ sudo zypper install yasm
I got output such as follows:
正在載入套件庫資料...
讀取已安裝的套件...
正在解決套件相依性...
將會安裝下列新的套件:
yasm
全部下載大小: 240.0 K。 完成操作後,將增加 654.0 K 的使用。
要繼續嗎? [是/否]: y
正在取出 套件 yasm-0.6.2-1.75.x86_64 (1/1), 240.0 K (已解開 654.0 K)
正在取出: yasm-0.6.2-1.75.x86_64.rpm [完成]
正在安裝: yasm-0.6.2-1.75 [完成]
4. Modify ./makefile.machine. Here is my makefile.machine:
$ cp makefile.machine makefile.machine.backup
$ cp makefile.linux_x86_asm_gcc_4.X makefile.machine
$ vim ./makefile.machine
I modify ./makefile.machine as following RED words for my T9500 x86_64 system:
#
# makefile for Linux (x86, PPC, alpha ...)
#
OPTFLAGS=-O
ALLFLAGS=${OPTFLAGS} -m64 -s \
-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE \
-DNDEBUG -D_REENTRANT -DENV_UNIX \
$(LOCAL_FLAGS)
CXX=g++ $(ALLFLAGS) -DHAVE_GCCVISIBILITYPATCH -fvisibility=hidden -fvisibility-inlines-hidden
CC=gcc $(ALLFLAGS)
CC_SHARED=-fPIC
LINK_SHARED=-fPIC -shared
ASM=yasm -f elf -m amd64
LOCAL_LIBS=-lpthread
LOCAL_LIBS_DLL=$(LOCAL_LIBS) -ldl
CPU=x64
OBJ_CRC32=$(OBJ_CRC32_x86_64)
5. Of course, make it!
$ make clean; make all2; sudo ./install.sh
Note that if you need 7zr just replace above "make all2" with "make all3".
Done...;-)
2009-01-04
How to install mplayer and browser plug-in on openSUSE 11.1 w/ Firefox 3.0.5
OK first, HAPPY NEW YEAR...X-D
Today I just want to install a movie player for my openSUSE 11.1 box.
Well, mplayer is always my favorite one...;-)
BTW, I know there are several repositories which provided pre-built package.
Hmm..., I think I just like to do this by myself instead of using package which I don't trust (security reason...:-P).
So, here is a very simple memo for installation steps.
Basically I want to do 2 tasks:
A.) Install mplayer with GUI enabled (gmplayer).
B.) Install mplayer plug-in for Firefox web browser.
=======================
==== A. Install mplayer ====
=======================
1. Get source code. Use following command to do so:
$ svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer
There is a directory called "mplayer" which will be created under current directory for storing source code of mplayer. So you should have the write permission for this dir. Note that if you use this way to get source code (svn) you will have libav* from FFmpeg inside already.
2. Get proper binary codecs package. Go to here and look for your CPU arch. type and download a binary codecs package. Note the if you used a wrong codecs package, the compile and install process will be failed. In my box I use Linux x86 20071007.
3. Get mplayer skin for enabling GUI feature. Go to here and scroll down the page to skins section. Select any skin you prefer and download it. I use Blue.
4. Install the binary codecs package. In my box I install into /usr/local/lib/codecs which is the default path that mplayer will look for. Issue followinig commands:
$ tar jxvf essential-20071007.tar.bz2
$ cd ./essential-20071007/
$ sudo mkdir -p /usr/local/lib/codecs
$ sudo cp -rfv ./* /usr/local/lib/codecs
5. Compile and install mplayer w/ GUI enabled. Issue following commands:
$ cd ./mplayer/
$ ./configure --enable-gui --enable-menu
$ make
$ sudo make install
6. Create a symbolic link for ttf. It will be used for mplayer OSD. In my box I issue following commands:
$ cd /usr/local/share/mplayer
$ sudo ln -s /usr/share/fonts/truetypes/uming.ttf subfont.ttf
7. Install the skin for GUI (gmplayer). Issue following commands:
$ tar jxvf ./Blue-1.7.tar.bz2
$ cd ./Blue/
$ sudo mkdir -p /usr/local/share/mplayer/skins/default
$ sudo cp -rfv ./* /usr/local/share/mplayer/skins/default/
8. It's done!! Let's play!!...;-) Just type mplayer or gmplayer with a movie file.
=======================
==== B. Install plug-in ====
=======================
1. Since the browser plug-in path between every distros is a little bit different. So we need to identify where we should copy our mplayer plug-in to. An easy way to do this just search a plug-in which was already installed for your browser. In my box I type:
$ sudo find / -name npwrapper.libflashplayer.so -print
Then I know the plug-ins are in the path /usr/lib64/browser-plugins/.
2. Grep the source package from here.
3. Un-tar the package and read the README/INSTALL first. Then I know that I have to install Mozilla devel files or Gecko SDK to compile mplayer plug-in. Issue following commands to install Gecko SDK package on openSUSE 11.1:
$ zypper search -d gecko
$ sudo zypper install mozilla-xulrunner190-devel
4. Change to mplayer-plugin's directory. And compile it:
$ cd ./mplayerplug-in-3.55/
$ ./configure --with-gecko-sdk=/path/to/gecko-sdk (replace /path/to with the correct value on your system)
$ make
5. Install *.so and *.xpt files, close your Firefox now and:
$ sudo cp mplayerplug-in*.so /usr/lib64/browser-plugins/
$ sudo cp mplayerplug-in*.xpt /usr/lib64/firefox/components/
6. Bingo! Launch your Firefox and enter "about:plugins" in the URL box then hit Enter, check the mplayer plug-ins are all installed...;-)
Today I just want to install a movie player for my openSUSE 11.1 box.
Well, mplayer is always my favorite one...;-)
BTW, I know there are several repositories which provided pre-built package.
Hmm..., I think I just like to do this by myself instead of using package which I don't trust (security reason...:-P).
So, here is a very simple memo for installation steps.
Basically I want to do 2 tasks:
A.) Install mplayer with GUI enabled (gmplayer).
B.) Install mplayer plug-in for Firefox web browser.
=======================
==== A. Install mplayer ====
=======================
1. Get source code. Use following command to do so:
$ svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer
There is a directory called "mplayer" which will be created under current directory for storing source code of mplayer. So you should have the write permission for this dir. Note that if you use this way to get source code (svn) you will have libav* from FFmpeg inside already.
2. Get proper binary codecs package. Go to here and look for your CPU arch. type and download a binary codecs package. Note the if you used a wrong codecs package, the compile and install process will be failed. In my box I use Linux x86 20071007.
3. Get mplayer skin for enabling GUI feature. Go to here and scroll down the page to skins section. Select any skin you prefer and download it. I use Blue.
4. Install the binary codecs package. In my box I install into /usr/local/lib/codecs which is the default path that mplayer will look for. Issue followinig commands:
$ tar jxvf essential-20071007.tar.bz2
$ cd ./essential-20071007/
$ sudo mkdir -p /usr/local/lib/codecs
$ sudo cp -rfv ./* /usr/local/lib/codecs
5. Compile and install mplayer w/ GUI enabled. Issue following commands:
$ cd ./mplayer/
$ ./configure --enable-gui --enable-menu
$ make
$ sudo make install
6. Create a symbolic link for ttf. It will be used for mplayer OSD. In my box I issue following commands:
$ cd /usr/local/share/mplayer
$ sudo ln -s /usr/share/fonts/truetypes/uming.ttf subfont.ttf
7. Install the skin for GUI (gmplayer). Issue following commands:
$ tar jxvf ./Blue-1.7.tar.bz2
$ cd ./Blue/
$ sudo mkdir -p /usr/local/share/mplayer/skins/default
$ sudo cp -rfv ./* /usr/local/share/mplayer/skins/default/
8. It's done!! Let's play!!...;-) Just type mplayer or gmplayer with a movie file.
=======================
==== B. Install plug-in ====
=======================
1. Since the browser plug-in path between every distros is a little bit different. So we need to identify where we should copy our mplayer plug-in to. An easy way to do this just search a plug-in which was already installed for your browser. In my box I type:
$ sudo find / -name npwrapper.libflashplayer.so -print
Then I know the plug-ins are in the path /usr/lib64/browser-plugins/.
2. Grep the source package from here.
3. Un-tar the package and read the README/INSTALL first. Then I know that I have to install Mozilla devel files or Gecko SDK to compile mplayer plug-in. Issue following commands to install Gecko SDK package on openSUSE 11.1:
$ zypper search -d gecko
$ sudo zypper install mozilla-xulrunner190-devel
4. Change to mplayer-plugin's directory. And compile it:
$ cd ./mplayerplug-in-3.55/
$ ./configure --with-gecko-sdk=/path/to/gecko-sdk (replace /path/to with the correct value on your system)
$ make
5. Install *.so and *.xpt files, close your Firefox now and:
$ sudo cp mplayerplug-in*.so /usr/lib64/browser-plugins/
$ sudo cp mplayerplug-in*.xpt /usr/lib64/firefox/components/
6. Bingo! Launch your Firefox and enter "about:plugins" in the URL box then hit Enter, check the mplayer plug-ins are all installed...;-)
Subscribe to:
Posts (Atom)