How to Install Checkinstall on RHEL

Applies to: All Linux versions of Ephesoft Transact

This page provides instructions for how to install checkinstall on RedHat Enterprise Linux (RHEL). Checkinstall files are included in the installation zip file from Ephesoft, however Transact does not install checkinstall by default.

If you find an error while installing Ephesoft where it was unable to install ImageMagick or Ghostscript. Check the /var/log/install-ephesoft.log. Scroll up above the Ephesoft ASCII graphics and if you see a mention of the install unable to find checkinstall, you will need to follow the instructions below in order to install checkinstall.

Prerequisites

  • You must be the root user.
  • All required packages must be installed prior to following the instructions listed here. If you need to install the required packages, enter the following command:
sudo yum install unzip rpmdevtools gcc*

Instructions

  1. Download the Ephesoft installer zip file.
  2. Unzip the Ephesoft installer to its own directory.
unzip <zip file name>.zip -d Ephesoft
  1. Change directory to the Ephesoft install directory.
cd Ephesoft
  1. In that directory, you will see a tar.gz file which contains all of the files that will be installed. Extract the checkinstall files from that tar.gz.
tar -xvf ./<tar file name>.tar.gz Ephesoft/Dependencies/checkinstall.tar.gz
  1. Change directory to the newly created Dependencies directory.
cd ./Ephesoft/Dependencies
  1. Decompress the checkinstall.tar.gz file.
tar xzvf ./checkinstall.tar.gz
  1. Change the directory to the newly installed checkinstall directory.
cd checkinstall
  1. Prepare the source code for installation.
make
  1. Compile and install checkinstall.
make install
  1. Verify the installation path of checkinstall is at /usr/local/sbin.
which checkinstall
  1. Verify that /usr/local/sbin is in the path for the root user.
echo $PATH
  1. If the $PATH return does not include /usr/local/sbin, you will need to add it to the path temporarily.
export PATH=$PATH:/usr/local/sbin
  1. Now that you have installed checkinstall, you will have to tell Ephesoft that it is already installed. Start the installation, you may receive an error and close the application.
  2. Once that happens, open the file /etc/Ephesoft/ephesoft.conf and change the value in it for checkinstall from 0 to 1.
  3. Save the file and start the installation over.

Troubleshooting

  1. If you receive the following error when running the “make” command in step 8, then you have not installed gcc first:
[root@localhost checkinstall]# make
for file in locale/checkinstall-*.po ; do \
case ${file} in \
locale/checkinstall-template.po) ;; \
*) \
out='echo $file | sed -s 's/po/mo/'' ; \
msgfmt -o ${out} ${file} ; \
if [ $? != 0 ] ; then \
exit 1 ; \
fi ; \
;; \
esac ; \
done
make -C installwatch
make[1]: Entering directory /path/to/folder/checkinstall/installwatch'
./create-localdecls
Checking truncate argument type... off_t
Checking readlinkat result type... ssize_t
Checking libc version... ./create-localdecls: line 47: gcc: command not found
ldd: ./libctest: No such file or directory
rm: cannot remove 'libctest': No such file or directory
gcc -Wall -c -D_GNU_SOURCE -DPIC -fPIC -D_REENTRANT -DVERSION=\"0.7.0beta7\" installwatch.c
make[1]: gcc: Command not found
make[1]: *** [installwatch.0] Error 127
make[1]: Leaving directory '/path/to/folder/checkinstall/installwatch'
make: *** [1ll] Error 2

2. If you receive the following error when running the “make” command, you will have to modify the /checkinstall/installwatch/installwatch.c file at the lines mentioned in the fix below and then start at step 8 again.

installwatch.c:2942: error: conflicting types for 'readlink'
/usr/include/unistd.h:828: note: previous declaration of 'readlink' was here
installwatch.c:3080: error: conflicting types for 'scandir'
/usr/include/dirent.h:252: note: previous declaration of 'scandir' was here
installwatch.c:3692: error: conflicting types for 'scandir64'
/usr/include/dirent.h:275: note: previous declaration of 'scandir64' was here

Note: When you edit the installwatch.c file, there will be an “if-then” statement for a static int on each item listed. You want them to match, which is what we are doing here.

Make the following changes to the ./checkinstall/installwatch/installwatch.c file:

    1. At line 110, change the “static int” to match the previous “static int”:

Original:

static int (*true_scandir)( const char *,struct dirent ***,
int (*)(const struct dirent *),
int (*)(const void *,const void *));

Edited:

static int (*true_scandir)( const char *,struct dirent ***,
int (*)(const struct dirent *),
int (*)(const struct dirent **,const struct dirent **));
    1. At line 138, change the “static int” to match the previous “static int”:

Original:

static int (*true_scandir64)( const char *,struct dirent64 ***,
int (*)(const struct dirent64 *),
int (*)(const void *,const void *));

Edited:

static int (*true_scandir64)( const char *,struct dirent64 ***,
int (*)(const struct dirent64 *),
int (*)(const struct dirent64 **,const struct dirent64 **));
    1. At line 2959, change:

Original:

#if (GLIBC_MINOR <= 4)

Edited:

#if (0)
    1. At line 3103, change the “static int” to match the previous “static int”:

Original:

int scandir( const char *dir,struct dirent ***namelist,
int (*select)(const struct dirent *),
int (*compar)(const void *,const void *) ) {

Edited:

int scandir( const char *dir,struct dirent ***namelist,
int (*select)(const struct dirent *),
int (*compar)(const struct dirent **,const struct dirent **) ) {[/code]
at line 3719, change the static int to match the previous static int:

Original:

int scandir64( const char *dir,struct dirent64 ***namelist,
int (*select)(const struct dirent64 *),
int (*compar)(const void *,const void *) ) {

Edited:

int scandir64( const char *dir,struct dirent64 ***namelist,
int (*select)(const struct dirent64 *),
int (*compar)(const struct dirent64 **,const struct dirent64 **) ) {