packages:add_local_directory_to_apt_sources.list
Differences
This shows you the differences between two versions of the page.
packages:add_local_directory_to_apt_sources.list [2017/04/03 14:23] – created peter | packages:add_local_directory_to_apt_sources.list [2019/12/01 11:45] (current) – removed peter | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Packages - Add local directory to apt sources.list ====== | ||
- | |||
- | 1. Create the directory to put all the deb files, for example / | ||
- | |||
- | <code bash> | ||
- | mkdir / | ||
- | </ | ||
- | |||
- | 2. Put all the deb files into the directory: | ||
- | |||
- | <code bash> | ||
- | mv / | ||
- | </ | ||
- | |||
- | |||
- | 3. Check the current priorities and section for the package, find entry named Section and Priority: | ||
- | |||
- | <code bash> | ||
- | dpkg --info example_1.2.3-1@i386.deb | ||
- | </ | ||
- | |||
- | This returns some information including Section and Priority: | ||
- | |||
- | Here is some of the info: | ||
- | Package: example | ||
- | Section: editors | ||
- | Priority: optional | ||
- | Homepage: http:// | ||
- | |||
- | |||
- | 4. Create an override file. | ||
- | |||
- | An Override file is used to override the default Priority and Section setting of the package. | ||
- | |||
- | Example of override file content: | ||
- | |||
- | < | ||
- | ## Override | ||
- | #Package priority section | ||
- | example low editors | ||
- | </ | ||
- | |||
- | |||
- | 5. Create Packages.gz inside / | ||
- | |||
- | <code bash> | ||
- | cd / | ||
- | sudo dpkg-scanpackages . override | gzip -c9 > Packages.gz | ||
- | </ | ||
- | |||
- | |||
- | 6. If you are too lazy to do the override file, you do not have to. Just change the "dpkg --scanpackages" | ||
- | |||
- | <code bash> | ||
- | cd / | ||
- | sudo dpkg-scanpackages . /dev/null | gzip -c9 > Packages.gz | ||
- | </ | ||
- | |||
- | If you follow this path, ignore step 4 and 5. | ||
- | |||
- | |||
- | 7. Add this line to / | ||
- | |||
- | < | ||
- | deb file:/// | ||
- | </ | ||
- | |||
- | |||
- | 8. Re-synchronize the package index files from their sources | ||
- | |||
- | <code bash> | ||
- | sudo apt-get update | ||
- | </ | ||
- | |||
- | |||
- | 9. Install your application: | ||
- | |||
- | <code bash> | ||
- | sudo apt-get install example | ||
- | </ | ||
- | |||
- | |||
- | This has just created a local file repository. | ||
- | |||
- | Apt will fetch the deb files from your local file directory also. | ||
packages/add_local_directory_to_apt_sources.list.1491229438.txt.gz · Last modified: 2020/07/15 09:30 (external edit)