mirror of
https://github.com/smittix/intercept.git
synced 2026-07-18 22:38:10 -07:00
Skip dump1090 apt install - not in Debian repos
- dump1090 is not available in standard Debian repositories - Show manual installation instructions with FlightAware link - Add pkg_available() helper for reliable package checks 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -50,6 +50,13 @@ check_cmd() {
|
|||||||
command -v "$1" &> /dev/null
|
command -v "$1" &> /dev/null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Check if a package is installable (has a candidate version)
|
||||||
|
pkg_available() {
|
||||||
|
local candidate
|
||||||
|
candidate=$(apt-cache policy "$1" 2>/dev/null | grep "Candidate:" | awk '{print $2}')
|
||||||
|
[ -n "$candidate" ] && [ "$candidate" != "(none)" ]
|
||||||
|
}
|
||||||
|
|
||||||
# Setup sudo command (empty if running as root)
|
# Setup sudo command (empty if running as root)
|
||||||
setup_sudo() {
|
setup_sudo() {
|
||||||
if [ "$(id -u)" -eq 0 ]; then
|
if [ "$(id -u)" -eq 0 ]; then
|
||||||
@@ -246,24 +253,20 @@ install_debian_tools() {
|
|||||||
$SUDO apt install -y rtl-sdr multimon-ng
|
$SUDO apt install -y rtl-sdr multimon-ng
|
||||||
|
|
||||||
# rtl-433 may be named differently or unavailable
|
# rtl-433 may be named differently or unavailable
|
||||||
if apt-cache show rtl-433 &>/dev/null; then
|
if pkg_available rtl-433; then
|
||||||
$SUDO apt install -y rtl-433
|
$SUDO apt install -y rtl-433
|
||||||
elif apt-cache show rtl433 &>/dev/null; then
|
elif pkg_available rtl433; then
|
||||||
$SUDO apt install -y rtl433
|
$SUDO apt install -y rtl433
|
||||||
else
|
else
|
||||||
echo -e "${YELLOW}Note: rtl-433 not found in repositories. Install manually or from source.${NC}"
|
echo -e "${YELLOW}Note: rtl-433 not found in repositories. Install manually or from source.${NC}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# dump1090 has multiple package variants
|
# dump1090 is not in Debian repos - show manual install info
|
||||||
if apt-cache show dump1090-fa &>/dev/null; then
|
if ! check_cmd dump1090; then
|
||||||
$SUDO apt install -y dump1090-fa
|
echo ""
|
||||||
elif apt-cache show dump1090-mutability &>/dev/null; then
|
echo -e "${YELLOW}Note: dump1090 must be installed manually (not in Debian repos).${NC}"
|
||||||
$SUDO apt install -y dump1090-mutability
|
echo " FlightAware version: https://flightaware.com/adsb/piaware/install"
|
||||||
elif apt-cache show dump1090 &>/dev/null; then
|
echo " Or from source: https://github.com/flightaware/dump1090"
|
||||||
$SUDO apt install -y dump1090
|
|
||||||
else
|
|
||||||
echo -e "${YELLOW}Note: dump1090 not found in repositories.${NC}"
|
|
||||||
echo " Install FlightAware's version from: https://flightaware.com/adsb/piaware/install"
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user