English Language Learner School District Information Package ...
Package Management - 國立臺灣大學Language package managers are good for quickly sharing code...
Transcript of Package Management - 國立臺灣大學Language package managers are good for quickly sharing code...
![Page 1: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/1.jpg)
Package ManagementTim Liou (@lyt)
5/075/03 (Thu) 11:00 ~ 12:00 @ 2175/10 (Thu) 11:00 ~ 12:00 @ 217
![Page 2: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/2.jpg)
Overview● Motivation● Package manager● Quick overview of Arch Build System (ABS)● In-Class Lab
![Page 3: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/3.jpg)
Motivation
![Page 4: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/4.jpg)
Manual Installation
http://kb.mozillazine.org/Installing_Firefox_on_Windows
Installation wizards are not scalable. (Do you remember last time you reinstall softwares of your choice while reinstalling your Windows box?)
![Page 5: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/5.jpg)
Manual Installationwget https://iperf.fr/download/source/iperf-3.1.3-source.tar.gztar zxf iperf-3.1.3-source.tar.gzcd iperf && ./configure && make && sudo make install
git clone https://github.com/django/django.gitcd djangosudo python setup.py install
● What if they have dependencies?● What if someday you want to remove
them safely?● What if they conflict with installed files?● What if you can’t afford compiling them?● What if the install scripts are malicious?● What if you want to upgrade them?
![Page 6: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/6.jpg)
Oops… I just ran Bumblebee’s install script with root
https://github.com/MrMEEE/bumblebee-Old-and-abbandoned/issues/123
rm -rf /usr /lib/nvidia-current/xorg/xorg
![Page 7: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/7.jpg)
Oops… I just ran Bumblebee’s install script with root
https://github.com/MrMEEE/bumblebee-Old-and-abbandoned/issues/123
![Page 8: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/8.jpg)
Oops… I just ran Steam’s install script with root
https://github.com/ValveSoftware/steam-for-linux/issues/3671
rm -rf “$STEAMROOT/”*
![Page 9: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/9.jpg)
Oops… I just ran Steam’s install script with root
https://github.com/ValveSoftware/steam-for-linux/issues/3671
![Page 10: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/10.jpg)
Package Manager
![Page 11: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/11.jpg)
The goal of package managerEnable the user do the following things with ease:
● Search & install new software● Upgrade software● Safely remove software● Verify the downloaded software content
![Page 12: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/12.jpg)
Language package manager
![Page 13: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/13.jpg)
System package manager
dpkg/aptpacman
rpm/yum/dnf
rpm/zypper
nix
![Page 14: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/14.jpg)
LPM vs SPM● Language package managers are good for quickly sharing code written
purely in that language with other developers.● Some Language package repository allows arbitrary developers to upload
packages. Hard to enforce package signing.● Most system package managers won't let you have multiple versions of a
library installed at all● System package, compare to Language package, usually have to be
checked more carefully to make sure it is acceptable
![Page 15: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/15.jpg)
How are you involved in?
Icons made by Freepik from www.flaticon.com is licensed by CC 3.0 BY
Developer Maintainer User
Work on upstream project
* Every distribution has their own maintainers* Create the distribution-specific experience* Package stability, default options, usability
Enjoy & give feedback
![Page 16: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/16.jpg)
Workflow
Icons made by SimpleIcon from https://www.flaticon.com is licensed by CC 3.0 BY
new release
report bugs,contribute code
patch, review, build
Download
report bugs
feature request
![Page 17: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/17.jpg)
Quick overview of Arch Build System (ABS)
![Page 18: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/18.jpg)
ABS● Official repository
○ core, extra, community, multilib, testing
● PKGBUILD○ a Bash script that contains the compilation and packaging instructions
● makepkg○ shell command tool which reads the PKGBUILDs, automatically downloads and compiles the
sources and creates a package tarball
● pacman○ install and remove the built packages and for fetching dependencies
● AUR○ a community-driven repository for Arch users
![Page 20: Package Management - 國立臺灣大學Language package managers are good for quickly sharing code written purely in that language with other developers. Some Language package repository](https://reader033.fdocuments.in/reader033/viewer/2022050413/5f89f2e176e51777207b322a/html5/thumbnails/20.jpg)
References● https://www.csie.ntu.edu.tw/~hsinmu/courses/_media/nasa_17spring/slides/p
ackage_management.pdf● https://lwn.net/Articles/712318/● https://medium.com/@sdboyer/so-you-want-to-write-a-package-manager-4ae
9c17d9527● https://wiki.archlinux.org/index.php/Arch_Build_System● https://news.ycombinator.com/item?id=11096368