LAB2 Code Building Part 1 - wget

In this post I built GNU wget using make command.

When I first followed the wget's INSTALL guideline it worked fine and everything was well, only to realize that I already had wget installed on my system. (I used Fedora 28 Workstation on VM).

So I figured that my result on the first try was most likely not correct. So I went ahead and removed wget from the system (sudo dnf remove wget).
This is the starting point of my about1 week of nightmare.

First I tried the same method:
- Downloaded the source from ftp://ftp.gnu.org/gnu/wget/
- Unpacked the tar file : tar xvzf wget-1.19.3.tar.gz
- Followed instruction in INSTALL
  - Run ./configure
  - Run make
  - Run make check and if everything went well it'll pass all the tests
FAILED!!!!

So I searched Google frantically looking for a solution, then !!AHA!!
I found wget-1.19.5-5.fc28.x86_64.rpm.
The question now is how do I work with this .rpm?
Another Google search and I got:
  rpm2cpio | cpio -idmv










Then just do ./wget <url>.
Done!!

WRONG!!

The purpose of this lab is to compile software using make command.

So, back to square one.

Whenever I ran make command the error that came up was that 'gnutls' was not found.
So I ran 'sudo dnf install gnutls' hoping this would fix the issue.
Of course nothing is that easy.
After more researching on Google I found that it might be an issue with share library.
So, I ran 'sudo dnf install gnutls-devel' and it worked, I mean the error didn't show up anymore.
But when I ran make check I had 65 test fails.

I checked test log and found missing module. I did this repeatedly and here are the modules I needed to install

I unpacked each rpm packages and copied the files to on location where @INC can find them.
To add the path to the @INC:
export PERL5LIB=path

In my case the modules I needed were
HTTP::
- Daemon.pm
- Date.pm
- Headers.pm
- Message.pm
- Request.pm
- Response.pm
- Status.pm

LWP::
- media.types
- MediaTypes.pm

After it was all set, I ran
make clean to clear the previous make binaries
./configure --prefix=/usr
make
make check to test and........



YAY!!! Passed all 44 tests.

Now to test if this actually works
I ran 'sudo make install' since I had wget removed from system.
(For some reason normal 'make install' didn't work)

I tested the installation by 'wget www.google.ca'
The result



I think I can call this a success.


The link to get the rpm packages:
http://rpmfind.net/linux/rpm2html/search.php


Next expisode: 'Code Building glibc'

Comments