2

I am trying to install git on a SUSE linux server that, to all intents and purposes, doesn't have internet access. It would appear that I also need to install some dependencies for git.

Is there a straightforward way of creating a package that contains git along with all its dependencies on another machine that I can the copy over to this server to install from?

2

Just download git.tar.gz unpack-configure-compile

  • Git is reasonably self-sufficient, but does depend on a few external programs and libraries. Git can be used without most of them by adding the approriate "NO_=YesPlease" to the make command line or config.mak file.

    • "zlib", the compression library. Git won't build without it.

    • "ssh" is used to push and pull over the net.

    • A POSIX-compliant shell is required to run many scripts needed for everyday use (e.g. "bisect", "pull").

    • "Perl" version 5.8 or later is needed to use some of the features (e.g. preparing a partial commit using "git add -i/-p", interacting with svn repositories with "git svn"). If you can live without these, use NO_PERL.

    • "openssl" library is used by git-imap-send to use IMAP over SSL. If you don't need it, use NO_OPENSSL.

      By default, git uses OpenSSL for SHA1 but it will use it's own library (inspired by Mozilla's) with either NO_OPENSSL or BLK_SHA1. Also included is a version optimized for PowerPC (PPC_SHA1).

    • "libcurl" library is used by git-http-fetch and git-fetch. You might also want the "curl" executable for debugging purposes. If you do not use http:// or https:// repositories, you do not have to have them (use NO_CURL).

    • "expat" library; git-http-push uses it for remote lock management over DAV. Similar to "curl" above, this is optional (with NO_EXPAT).

    • "wish", the Tcl/Tk windowing shell is used in gitk to show the history graphically, and in git-gui. If you don't want gitk or git-gui, you can use NO_TCLTK.

| improve this answer | |
0

Please find below the Steps I followed to install Git without internet access on the system

  1. Download the desired tarball from below link, on your PC/Laptop https://www.kernel.org/pub/software/scm/git/ I used the Git-2.8, as the customer requirement was to have version >= Git-2.74

  2. Connect to remote Linux system (via winscp or nay other remote connectivity tool). And Place/Move the downloaded git-XXXXXX.tar.gz file on desired location on the linux system where you want to install ‘git’. I placed it in Directory: /var/opt/teradata/packages/Package/GIT/

  3. From command prompt go to the directory where you placed the above file and run below command to untar the package tar -xvzf git-2.8.0.tar.gz CD into the directory that is newly created because of untar command above. cd git-2.8.0/

  4. Verify that all the needed files and directories have been uncompressed into the above folder ls -ltr

  5. Set the Path and Prefix variables with commands below.

    PATH=$PATH:/var/opt/teradata/packages/Package/GIT/git-2.8.0/usr/bin
    
    PATH=$PATH:/var/opt/teradata/packages/Package/GIT/git-2.8.0
    
    export PATH=$PATH:/var/opt/teradata/packages/Package/GIT/git-2.8.0
    
    make prefix=/usr/local/git all
    
    echo $CC
    
  6. Run Below command to check the preinstall configuration checks ./configure

  7. Run Below command to install. make install

  8. Now see it work with below command git --version

| improve this answer | |
0

Offline Install git on SLES 12 SP2 using SDK ISO

If you do not have direct access to the remote/online SLES zypper repositories, you can add SDK ISO as repository. Some packages are available in this ISO.

1) Download SLE-12-SP2-SDK-DVD-x86_64-GM-DVD1.iso from https://download.suse.com/Download?buildid=g3e7P21X6Lw~ (It requires sign-up). You can also find your desired ISO sdk at https://download.suse.com

2) Copy & transfer downloaded file to the SLES machine. (here we transfer it to /temp/SLE-12-SP2-SDK-DVD-x86_64-GM-DVD1.iso)

3) Add ISO as Zypper repository

zypper ar iso:/?iso=/temp/SLE-12-SP2-SDK-DVD-x86_64-GM-DVD1.iso sdk_dvd

4) install git

zypper install git-core

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.