Skip to content
This repository has been archived by the owner on Dec 29, 2020. It is now read-only.

Commit

Permalink
Update documentation about using LD_LIBRARY_PATH (dynamic linking)
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrea De Pasquale committed Apr 6, 2016
1 parent f881f73 commit 1d633ef
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 17 deletions.
35 changes: 20 additions & 15 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,12 @@ OPSEC_LIBS = \
-lDataStruct \
-lOS

INSTALL_PREFIX = /usr/local/fw1-loggrabber
SYSCONFDIR=${INSTALL_PREFIX}/etc
BINDIR=${INSTALL_PREFIX}/bin
MANDIR=${INSTALL_PREFIX}/man
TEMPDIR=/tmp
INSTALL_DIR = /usr/local/fw1-loggrabber
INSTALL_BIN_DIR=${INSTALL_DIR}/bin
INSTALL_ETC_DIR=${INSTALL_DIR}/etc
INSTALL_LIB_DIR=${INSTALL_DIR}/lib
INSTALL_MAN_DIR=${INSTALL_DIR}/man
TEMP_DIR=/tmp

%.o: %.c
$(CC) $(CFLAGS) -I$(OPSEC_INC_DIR) -c -o $@ $*.c
Expand All @@ -52,21 +53,25 @@ $(EXE_NAME): $(OBJ_FILES)

install:
@echo
@echo "Installing FW1-Loggrabber to ${INSTALL_PREFIX}:"
@echo "Installing FW1-Loggrabber to ${INSTALL_DIR}:"
@echo
install -v -d -o root -g root -m 755 ${BINDIR}
install -v -d -o root -g root -m 755 ${SYSCONFDIR}
install -v -d -o root -g root -m 755 ${MANDIR}/man1
install -v -o root -g root -m 755 -p fw1-loggrabber ${BINDIR}/fw1-loggrabber
install -v -o root -g root -m 644 -p fw1-loggrabber.conf ${SYSCONFDIR}/fw1-loggrabber.conf-sample
install -v -o root -g root -m 644 -p lea.conf ${SYSCONFDIR}/lea.conf-sample
install -v -o root -g root -m 644 -p fw1-loggrabber.1 ${MANDIR}/man1/fw1-loggrabber.1
@install -v -o root -g root -m 755 -d ${INSTALL_BIN_DIR}
@install -v -o root -g root -m 755 -d ${INSTALL_ETC_DIR}
@install -v -o root -g root -m 755 -d ${INSTALL_LIB_DIR}
@install -v -o root -g root -m 755 -d ${INSTALL_MAN_DIR}/man1
@install -v -o root -g root -m 755 -p fw1-loggrabber ${INSTALL_BIN_DIR}/fw1-loggrabber
@install -v -o root -g root -m 644 -p fw1-loggrabber.conf ${INSTALL_ETC_DIR}/fw1-loggrabber.conf-sample
@install -v -o root -g root -m 644 -p lea.conf ${INSTALL_ETC_DIR}/lea.conf-sample
@install -v -o root -g root -m 644 -t ${INSTALL_LIB_DIR} ${OPSEC_LIB_DIR}/*.so
@install -v -o root -g root -m 644 -p fw1-loggrabber.1 ${INSTALL_MAN_DIR}/man1/fw1-loggrabber.1
@echo
@echo "Installation complete! Please declare the following environment variables in your shell configuration file:"
@echo
@echo " LOGGRABBER_CONFIG_PATH=${SYSCONFDIR}"
@echo " LD_LIBRARY_PATH=\$$LD_LIBRARY_PATH:${INSTALL_LIB_DIR}"
@echo " export LD_LIBRARY_PATH"
@echo " LOGGRABBER_CONFIG_PATH=${INSTALL_ETC_DIR}"
@echo " export LOGGRABBER_CONFIG_PATH"
@echo " LOGGRABBER_TEMP_PATH=${TEMPDIR}"
@echo " LOGGRABBER_TEMP_PATH=${TEMP_DIR}"
@echo " export LOGGRABBER_TEMP_PATH"
@echo

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# FW1-LogGrabber

FW1-LogGrabber is a command-line tool to grab logfiles from Checkpoint FW-1 remotely using Checkpoints LEA (Log Export Api), which is one part of Checkpoints OPSEC API.
FW1-Loggrabber is a command-line tool to grab logfiles from remote Checkpoint devices using OPSEC LEA (Log Export API).

## Installation

Expand All @@ -11,7 +11,7 @@ FW1-LogGrabber uses API-functions from Checkpoint's [OPSEC SDK 6.0 for Linux 50]

If you are using Ubuntu, install required libraries with ``sudo apt-get install gcc-multilib g++-multilib libelf-dev:i386``. You might also need to tweak some ``Makefile`` variables (e.g. ``CC``, ``LD`` and ``OPSEC_PKG_DIR``) according to your environment.

Then run ``make`` to build and ``sudo make install`` to install.
Then run ``make`` to build and ``sudo make install`` to install into default location ``/usr/local/fw1-loggrabber`` (defined by ``INSTALL_DIR`` variable). Since the binary is dynamically linked, please add ``/usr/local/fw1-loggrabber/lib`` to your ``LD_LIBRARY_PATH``.

## Documentation

Expand Down

0 comments on commit 1d633ef

Please sign in to comment.