Tag Archive : slackware

/ slackware

Turn Slackware64 to be Multilib

December 3, 2015 | Article | 7 Comments

A multilib 64bit Linux OS is system which capable of running 64bit as well as 32bit software. By default, a fresh installation of Slackware64 bit is a multilib-ready. This article will discuss about how to turn our pure slackware64 to be multilib.

In FHS (Filesystem Hierarchy Standards), there is a separation of library, the one for 64bit is located on /lib64 directory while the 32bit on /lib directory. This separation ensure a clean system and the slackware team has chose this for the system.

The 64bit application will look for library on /lib64 hence we said the Slackware64 is a multilib-ready. The 32bit application will look for library on /lib, but Slackware is not shipped with any 32bit software.

Basically, what will we do are:

  1. switch the glibc (gnu library c) and gcc (compiler) to multilib version.
  2. System libraries are taken from 32bit Slackware and installed in the 64bit Slackware system which completes the process of creating a 32bit software layer.

We will use the simplest but work method.

Create a working directory. In this article I will use /tmp for that. You might use other directory if you want. Change to that directory and then invoke this command.

lftp -c 'open http://slackware.com/~alien/multilib/ ; mirror 14.0'

That command will download required packages to build multilib system. Wait until the download finished.

Now upgrade the glib and gcc to multilib system (the downloaded one) with this command:

upgradepkg --reinstall --install-new *.t?z

Now proceed with this if you download the directory slackware64-compat32 (in the default you do):

upgradepkg --install-new slackware64-compat32/*-compat32/*.t?z

Congratulations, now your system is Slackware64 multilib-enabled. Now you can download and run any 32bit applications.

For you who use package manager such as slackpkg, you need to add glibc and gcc packages names to blacklist. Otherwise, you have a chance that your multilib version is replaced with pure 64bit version.

Edit /etc/slackpkg/blacklist and add this line:

[0-9]+alien

When you want to install a 32-bit package to multilib Slackware and want to make sure that the system is not tainted, you can do following:

convertpkg-compat32 -i <package>

The script then check the package for compatibility and then make the compatible package for you to install.

Installing Eclipse IDE for Slackware64 14.0

December 3, 2015 | Article | 2 Comments

We have install java (see here) now we will install an IDE for developing in our Slackware machine. In this article we will install latest Eclipse IDE using generic method. Alternatively you can install it using SlackBuild but we won’t cover that.

What you need:

  1. Slackware64 14.0 (well, that’s obvious)
  2. Eclipse binary for linux. download from here

The latest Eclipse IDE (per January 15th 2013) is Juno. Select the appropriate one, the one for Linux 64 bit. Of course you need to download the Eclipse for JAVA, although Eclipse for C++ is good too. The latest eclipse would be eclipse-java-juno-SR1-linux-gtk-x86_64.tar.gz. download it.

Now extract the file you have download to /opt/ directory. You might need root privileges to do this. Installing to /opt/ is a good practice for FHS (Filesystem Hierarchy Standard) as optional software is installed on separated place. To do so in command line, invoke this:

tar -xvf eclipse-java-juno-SR1-linux-gtk-x86_64.tar.gz -C /opt

Once you have done, you will get a new directory eclipse under /opt. Change the ownership to your username, for example user xathrya, by invoking this:

chown -R xathrya eclipse

Of course, change the xathrya with your username.

Now create the link to your menu or desktop. Link it to /opt/eclipse/eclipse. If you are using KDE, you can follow this guide. Point your application to /opt/eclipse/eclipse.

Congratulation! You have successfully install Eclipse!

But wait, if you face something like this:

A Java Runtime Environment (JRE) or Java Development Kit (JDK)must be available in order to run Eclipse.
No Java virtual machinewas found after searching the following locations:<some path here> in your current PATH

Then you need to do extra thing!

Edit /opt/eclipse/eclipse.ini so it would be be like this:

[sourcecode language="bash"]-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.gtk.linux.x86_64_1.1.200.v20120522-1813
-product
org.eclipse.epp.package.cpp.product
--launcher.defaultAction
openFile
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vm
/usr/lib64/java/bin/java
-vmargs
-dosgi.requiredJavaVersion=1.5
-dhelp.lucene.tokenizer=standard
-XX:MaxPermSize=256m
-Xms40m
-Xmx512m[/sourcecode]

Now run your eclipse once more 😀

Installing JAVA to Slackware64 14.0

December 3, 2015 | Article | 2 Comments

JAVA is one of popular programming language today. Made by Sun Microsystem, and later bought by Oracle. However, JAVA programming language is restricted so most linux distribution not include it. This article will discuss about installing latest JAVA 7 (January 15th, 2013) to Slackware Linux 64 bit.

What we need:

  1. Slackware 64 bit, version 14.0
  2. Oracle’s JRE or JDK
  3. SlackBuild script

The Latest JAVA version per January 15th 2013 would be Java 7u11. You can download the binary from here. Decide what you want to install, either the JDK or JRE but not both. If you are developing application for JAVA, use JDK instead of JRE. Use JRE if you only want to run some application but not developing one. Thus, JDK might be safe choice for you.

If you want to install Oracle JRE you may download the jre-7u11-linux-x64.tar.gz. The JDK version would be jdk-7u11-linux-x64.tar.gz. Be sure you have accept the license agreement otherwise you can’t download it. And remember to download only the .tar.gz version to follow this article.

Now, download the slackbuild script. You can visit here. Actually you can read the README file but let this article be your only source hahaha ^^.

Update 2: There’s now a script that can repackage Oracle’s JRE or JDK into a Slackware package here (64-bit here). Just follow the instructions in the README file. Again, here is some information about installing OpenJDK.

What you must download:

  1. java.SlackBuild
  2. slack-desc.jdk or slack-desc.jre (depend on what you want to install)
  3. some script on profile.d/

Now, download all the required material and place in on same directory. Let say /tmp/java

execute the slackbuild script by invoking

/bin/sh java.SlackBuild

Wait until the process finished and you will get a new installation file on /tmp. Install it by invoking (for JDK):

upgradepkg --install-new /tmp/jdk-7u11-x86_64-1.txz

If you want to install JRE you would get jre one, so install it by invoking:

upgradepkg --install-new /tmp/jre-7u11-x86_64-1.txz

Congratulations! You have successfully install Java to your system. But wait, it’s not finished yet.

Our installation would be on /usr/lib64/java directory so we must update our environment variable so the system can find the JAVA. If you are using bash you can edit ~/.bashrc using nano or vi and add this snippet in the end of your file (or you must create new one if you don’t have any)

export JAVA_HOME=/usr/lib64/java export PATH="${PATH}:${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" 
export MANPATH="${MANPATH}:${JAVA_HOME}/man"

Now reopen your shell and type java.

And that’s all 😀

Slackware Linux, one of oldest linux distribution available, can’t be denied as on of popular distro over many other distros. Slackware power lies on it’s simplicity which gives its user the freedom to customize their machine. Slackware bring genuine kernel and all software without modification which gives you the software as is.

In this article we will discuss a way to install Slackware into UEFI-base machine (as title suggests). What I use for this article:

  1. Lenovo Z480 laptop (UEFI-based laptop)
  2. Slackware installer DVD (see http://slackware.com/getslack/ to obtain it)
  3. USB flash disk (or USB stick)

Preparing the Machine

Things to be prepared: the UEFI itself! Make sure your machine is booted with UEFI mode enabled. This article will explain how to install using UEFI system, not using GRUB legacy mode. Another thing you must pay attention to is your hard disk partition scheme. We will use GPT (GUID Partition Table) instead of the old MBR (Master Boot Record) scheme.

Create USB Stick

A slackware DVD by default is not UEFI boot capable, therefore we must create an USB Stick with UEFI capable. The one I use can be downloaded from here (or here).

Make a partition for your USB stick with FAT32 partition with boot flag enabled. You can use either gparted or gdisk to accomplish it.

Just extract what inside the archive to your USB flash disk. Make sure you have 2 folders: EFI and slackware64. If you have done, stick your USB flash disk and boot your machine from it.

Create Partition to the Disk

I warn you for the last time, we will use GPT. If your disk is still in MBR scheme, you can use gdisk (should be available at USB stick) to change the partition to GPT. Of course if you have some data, the data would be erased / inaccessible. Well, I have warn you.

For comparison of GPT and MBR will be discussed on another article.

You can create as many partition as you like, but you need at least 2 partition:

  1. boot partition, located on partition 1 with FAT32 file system, takes about 100MB for it. Let say /dev/sda1
  2. a root partition for linux file system, with EXT4 file system. Let say /dev/sda2.

For other partition, you can use any file system you like, such as: XFS, JFS, ReiserFS, etc (aside from those 2, i use XFS for my partitions).

Install

Ok, here is our main issue.

Mount the USB stick. You can accomplish it by invoking following command:

mkdir /src
mount /dev/sdb1 /src

Invoke setup and adjust the setting like normal installation until you reach installation media stage.

Press ALT+F2 to switch to another screen.

Install temporary system using USB stick. Invoke these commands:

cd /src/slackware64
installpkg -root /mnt [az]*/*
cd

Press ALT+F1 to go back to our main setup and choose install from CD/DVD. Thing to note before you finish your installation: We won’t use LILO, instead we will use ELILO. So don’t install LILO.

After we finish the installation, don’t restart your machine now. We will configure the boot using ELILO. Please follow every character written here, even ‘.’ matters. Now, invoke these commands:

mkdir /mnt/root
mount /dev/sda1 /mnt/boot/efi
mount /dev/sda2 /mnt/root
cd /mnt/boot/efi
cp -rvf /src/EFI /mnt/boot/efi
cd /mnt/boot/efi/EFI
mv BOOT Slackware
cd Slackware
mv bootx64.efi elilo.efi
cp /mnt/root/boot/vmlinuz-huge-3.2.29 .
vi elilo.conf

You have come to configure the elilo.conf file. Here is my configuration:

prompt
image = vmlinuz-huge-3.2.29
label = Slackware
root = /dev/sda2

Last, we will register our boot so that the machine can boot our machine. To do so, invoke this command:

modprobe efivars
cd /mnt
usr/sbin/efibootmgr -c -L "XathryaBootCode" -l "\\EFI\\Slackware\\elilo.efi"

restart your machine (press CTRL+ALT+DELETE) and you machine should be boot to your Slackware now. Happy hacking 🙂

Social media & sharing icons powered by UltimatelySocial