Check the current Python version.
$ python --versionPython 3.4.2
2. modify the Python version at the system level.
We can use update-alternatives to change the Python version for the entire system. Log on as a root user. first, list all available python alternative versions:
# update-alternatives --list pythonupdate-alternatives: error: no
. Enter the following command on the terminal:
Sudo update-alternatives -- install/usr/bin/gcc/usr/bin/gcc-4.4 40
Sudo update-alternatives -- install/usr/bin/gcc/usr/bin/gcc-4.1 30
Set the default GCC version. Run the following command:
Sudo update-alternatives -- config gcc
Result:
There are 2 choices for the alternative gcc (providing/usr/bin/gcc ).Se
->/etc/alternatives/java*
Alternatives is a multiple version management software under Linux, which can be used to achieve version switching of JDK, which is described later. First come to the alternatives directory to see what's on the ground.
fordreamxin@compiler207:/etc/alternatives$ ls java*
Java java.1.gz javac
Ubuntu GNU/Linux 12.04 lts (precise pangolin) released. I wanted to manually install the Sun JDK 6 and 7 on Ubuntu.
Installing Sun JDK 6 on Ubuntu 12.04:
Download the Sun JDK 6 BinFrom here.
Make the BIN file executeable:
chmod +x jdk-6u32-linux-x64.bin
Extract the BIN file:
./jdk-6u32-linux-x64.bin
Move extracted folder to this location:
sudo mv jdk1.6.0_32 /usr/lib/jvm/
Install new Java source in system:
sudo update-alternatives --ins
Tags: des style http color java using OS StrongRecently need to do JSP project, deployed in Ubuntu, the weekend time to configure the Nginx + PHP + mysql + phpmyadmin + tomcat environment, from the Windows C # turn around, how much some do not adapt, estimated to go the whole stack direction. By the way, the introduction of the configuration method, complete under the console. 1.1 Common
Start Terminal
Ctrl+alt+t
Using the root user
Sudo–sh
View process
been looking !) E.g.: grep-R jerry/etc (search for all directories in/etc with files containing jerry (parameter-R indicates all files) If you only want to list file names: www.2cto.com grep-R-l jerry/etc (-l only lists file names) 01root @ why :~ # Grep-R-l jerry/etc02/etc/passwd03/etc/shadow-04grep:/etc/alternatives/ghostscript-current/Resource/CMap/Hojo-EUC-H: there is no file or directory 05 grep:/etc/alterna
First, install the JDK:RPM Installation:# RPM-IVH jdk-8u45-linux-x64.rpmIn the case of a Debian system, tar. Unzip tar.gz to/usr/local/java/and create the corresponding link file. Such as:$ ll/usr/local/java/Total usage 4lrwxrwxrwx 1 root root 6 June 22:31 Default-latestdrwxr-xr-x 8 UUCP 143 4096 April 11 01:26 jdk1.8.0_45lrwxrwxrwx 1 root root 28 June 22:30 latest-/usr/local/java/jdk1.8.0_45/Second, the configuration:Create the/etc/profile.d/java.sh and edit the configuration file:$ cat/etc/pro
GCC is the GNU exclusive C/C ++ compiler. Because GCC has compatibility issues, you must use the specified version of GCC to compile and pass the code, therefore, we should switch to the appropriate GCC compiler in a timely manner.
1. Brief description:In general, the Compilation Program uses:/usr/bin/GCC
In fact, this/usr/bin/GCC is just a symbolic link, it points to/etc/alternatives/GCC, and/etc/alternatives
mockobjects-jdk1.4.x86_64:mockobjects for 1.4 jdk
2. Install JDK
[Root@localhost ~]# yum install java-1.6.0-openjdk.x86_64 ...
Total download size:44 M are this
OK [y/n]: Y
3. After the installation is complete, verify
[Root@localhost ~]# java-version
java Version "1.6.0_37"
OpenJDK Runtime (Environment IcedTea6) ( rhel-1.13.9.4.el5_11-x86_64)
OpenJDK 64-bit Server VM (build 23.25-b01, Mixed mode)
4. The default installation path via Yum is
/usr/lib/jvm
[
Original article name: 7 better alternatives to common Windows appsTranslator:Fish that cannot reach the shore {ttzhang}Link: http://www.makeuseof.com/tag/enhance-or-replace-integrated-windows-applications-with-these-great-alternatives/
There is no doubt, Microsoft is going to dominate the operating system market through Windows 7. who knows where we will be after that. at that point we will likely be
[Odroid-pc] ubuntu12.04 jdk-6u45-linux-x64.bin, jdk6u45linuxx64
1. Download jdk-6u45-linux-x64.bin.tar .**
2) Put it in a directory and decompress it.
3) execute the following command
Chmod + x jdk-6u45-linux-x64.bin
/Jdk-6u45-linux-x64.bin
Mkdir-p/usr/lib/jvmMv jdk1.6.0 _ 45/usr/lib/jvm
Update-alternatives -- install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.6.0 _ 45/bin/java" 1Update-alternatives -- insta
-alternatives to change the Python version for the entire system. Log in as root and first list all available Python alternative version information:# update-alternatives--list python update-alternatives:error:no alternatives for PythonIf the error message shown above is present, the alternate version of Python is not yet recognized by the update-
can use Update-alternatives to change the Python version for the entire system. Log in as root and first list all available Python alternative version information:# update-alternatives--list pythonUpdate-alternatives:error:no Alternatives for PythonIf the error message shown above is present, the alternate version of Python is not yet recognized by the update-
the installation process:Errors were encountered while processing:Libc6-dev:i386E:sub-process/usr/bin/dpkg returned an error code (1)Here's how to fix it:$ sudo apt-get install linux-libc-dev:i386$ sudo apt-get install libc6-dev:i386At this point, even if the build environment is complete, at least on my computer, so we can start to download the Android code to compile.Final installation Ia32-libs$ sudo apt-get install Ia32-libsUbuntu 14.04 x64 Configuring the Android 4.4 KitKat compilation env
to take effect.
$ . ~/.bashrc
Check the current Python version.
$ python--version
Python 3.4.2
2. Modify the Python version at the system levelWe can use Update-alternatives to change the Python version for the entire system. Log in as root and first list all available Python alternative version information:
# update-alternatives--list python
Update-alternatives
1. Download and decompress jdk1.7.0 _ 67, and put it in the/usr/local/lib/JVM directory.
Tar zxvf jdk1.7.0_67.tar.gz
Sudo MV jdk1.7.0 _ 67/usr/local/lib/JVM
2. Edit ~ /. Add the following content to the bashrc file.
The content after java_home is your custom JDK storage directory
Export java_home =/usr/local/lib/JVM/jdk1.7.0 _ 67
Export jre_home =$ {java_home}/JRE
Exportclasspath =.: $ {java_home}/lib: $ {jre_home}/lib
Export path =$ {java_home}/bin: $ path
3. Set the default JDK version
Sudo
1) Download jdk-6u45-linux-x64.bin.tar.**2) put it in a directory and unzip it.3) Execute the following commandchmod +x Jdk-6u45-linux-x64.bin./jdk-6u45-linux-x64.binMkdir-p/USR/LIB/JVMMV JDK1.6.0_45/USR/LIB/JVMUpdate-alternatives--install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.6.0_45/bin/java" 1Update-alternatives--install "/usr/bin/javac" "Javac" "/usr/lib/jvm/jdk1.6.0_45/bin/javac" 1Update-
program runs, of course, can not find the corresponding class. The company compiled server is actually configured with multiple JDK versions, and Android compilation is the JDK version set when setting environment variables.Compiling android4.4 uses jdk1.6, and compiling android5.0 uses jdk1.7, which involves switching the JDK version at any time. First to see how to set the JDK environment variables, Baidu Search to get the answer is to modify the ~/.BASHRC or modify the/etc/profile file to co
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.