ubuntuubuntu-16.04aptpackage-managersaptitude

whats the official github link for source code of apt


I am having an older version of apt on the nfs mounted server, its version is around 0.6.x. i want to update it to latest/newer version like 1.2.x. i wanted the link for the source code where can i get it and compile to have my local version of "apt"

exactly using apt-ftparchive for repo creation

the problem that i have with using the older ow is, if i created the packages locally it fails the installation on ubuntu 16.04 system. It fails with "Hash Sum Mismatch" where as if i do it using apt-1.2.x version i am able to configure the repo and install the package as well

i tried to google it, there were many cloned repo in github but i could not link to the official debian one.

any link which i can use (open-source) will be helpful.


Solution

  • I didn't find any Github repository for apt, but instead you can use official guide how to get sources:

    15.1.1. Getting the Sources

    Rebuilding a Debian package starts with getting its source code. The easiest way is to use the apt-get source source-package-name command. This command requires a deb-src line in the /etc/apt/sources.list file, and up-to-date index files (i.e. apt-get update). These conditions should already be met if you followed the instructions from the chapter dealing with APT configuration.

    Note however, that you will be downloading the source packages from the Debian version mentioned in the deb-src line. If you need another version, you may need to download it manually from a Debian mirror or from the web site. This involves fetching two or three files (with extensions *.dsc — for Debian Source Control — *.tar.comp, and sometimes *.diff.gz or *.debian.tar.comp — comp taking one value among gz, bz2 or xz depending on the compression tool in use), then run the dpkg-source -x file.dsc command.

    If the *.dsc file is directly accessible at a given URL, there is an even simpler way to fetch it all, with the dget URL command. This command (which can be found in the devscripts package) fetches the *.dsc file at the given address, then analyzes its contents, and automatically fetches the file or files referenced within. Once everything has been downloaded, it extracts the source package (unless the -d or --download-only option is used).

    Link to the documentation is here.