microchip-mplabx-bin

maintainer mickael9 · 57 votes · scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged The package downloads an official Microchip IDE installer from a plausible project-owned domain (microchip.com) with a valid checksum; the non-standard host flag is a false positive as microchip.com is the legitimate vendor.

Triggered rules

LOW AI review downgraded a static finding llm_review

The static rules flagged this MEDIUM, but an AI model (qwen/qwen3-235b-a22b-07-25) reviewed the full PKGBUILD and judged it LOW (confidence 95%): The package downloads an official Microchip IDE installer from a plausible project-owned domain (microchip.com) with a valid checksum; the non-standard host flag is a false positive as microchip.com is the legitimate vendor.

1 higher static finding superseded - not the current verdict (shown for transparency)
MEDIUM source=() URL on a non-standard host source_untrusted_domain

One or more source=() URLs point to a host outside the trusted allowlist (github.com, gitlab.com, codeberg.org, pypi.org, …).

  • PKGBUILD:33 source=("https://ww1.microchip.com/downloads/aemDocuments/documents/DEV/ProductDocuments/SoftwareTools/${_mplabx_installer}.tar"

PKGBUILD

1 offending line(s) highlighted
1# Maintainer: mickael9 <mickael9 at gmail dot com>
2# Contributor: Peter Ivanov <ivanovp@gmail.com>
3# Contributor: joat
4# Submitter: BxS <bxsbxs at gmail dot com>
5
6pkgname=microchip-mplabx-bin
7pkgver=6.30
8pkgrel=1
9pkgdesc="IDE for Microchip PIC and dsPIC development"
10arch=(x86_64)
11url='http://www.microchip.com/mplabx'
12license=(custom)
13depends=(gtk2 alsa-lib libxslt libxtst jre8-openjdk java8-openjfx)
14makedepends=(fakechroot desktop-file-utils)
15optdepends=('microchip-mplabxc8-bin: C compiler for PIC10 PIC12 PIC16 PIC18 MCUs'
16 'microchip-mplabxc16-bin: C compiler for PIC24 MCUs and dsPIC DSCs'
17 'microchip-mplabxc32-bin: C Compiler for PIC32 MCUs'
18 'microchip-mplabc18-bin: C compiler for PIC18 MCUs'
19 'sdcc: C compiler for PIC16/18 MCUs'
20 )
21provides=(mplab)
22conflicts=(mplab)
23options=(!strip docs libtool emptydirs !zipman)
24
25_mplabx_dir="/opt/microchip/mplabx/v${pkgver}"
26_mplabx_installer="MPLABX-v${pkgver}-linux-installer"
27
28_mplabcomm_dir="/opt/microchip/mplabcomm"
29
30# Override DLAGENTS as microchip doesn't allow direct download if the Referer header is not provided
31DLAGENTS=('https::/usr/bin/curl -qgb "" -fLC - --retry 3 --retry-delay 3 -e "https://www.microchip.com/en-us/tools-resources/develop/mplab-x-ide" -o %o %u')
32
33source=("https://ww1.microchip.com/downloads/aemDocuments/documents/DEV/ProductDocuments/SoftwareTools/${_mplabx_installer}.tar"
34 "LICENSE"
35 "mplabx-override.conf")
36
37md5sums=('b26c0e1633519034f63cac079d1ab25a'
38 'a34a85b2600a26f1c558bcd14c2444bd'
39 'a476a71af625380a2fd52f82fb5d5492')
40
41backup=("etc/mplab_ide.conf")
42
43PKGEXT='.pkg.tar'
44
45build() {
46 chrootdir="${srcdir}"/chroot
47
48 mkdir -p "${chrootdir}"/{etc,usr/{bin,lib},tmp}
49
50 # Create a fake chroot in $chrootdir to run the installer into
51 ln -s /usr/bin "${chrootdir}/"
52
53 echo "root:x:0:0:root:/root:/bin/bash" > "${chrootdir}/etc/passwd"
54 echo "root:x:0:root" > "${chrootdir}/etc/group"
55
56 echo "Extracting installers..."
57 sh ${_mplabx_installer}.sh --tar xf ./${_mplabx_installer}.run
58 mv ${_mplabx_installer}.run "${chrootdir}/tmp"
59 chmod 0755 "${chrootdir}/tmp/${_mplabx_installer}.run"
60
61 # Create install script in chroot
62 cat << EOF > "${chrootdir}/tmp/install.sh"
63#!/bin/sh
64PATH=/bin
65echo Running MPLABX installer...
66tmp/${_mplabx_installer}.run --mode unattended
67EOF
68
69 chmod 0755 "${chrootdir}/tmp/install.sh"
70
71 # Run the installer in the fake chroot
72 fakechroot fakeroot chroot "${chrootdir}" tmp/install.sh
73
74 # Remove uninstaller files
75 rm -f "${chrootdir}${_mplabx_dir}"/Uninstall_*
76
77 # Fix permissions
78 chmod -R og-w "${chrootdir}"
79
80 # Fix ugly fonts
81 sed -i 's/^default_options="/default_options="-J-Dawt.useSystemAAFontSettings=on /' "${chrootdir}${_mplabx_dir}/mplab_platform/etc/mplab_ide.conf"
82
83 # Rename udev rules to avoid conflict with jlink-software-and-documentation
84 mv "${chrootdir}"/etc/udev/rules.d/{99-jlink,98-jlink-mplabx}.rules
85
86 # Move them to /usr/lib/udev/rules.d
87 mv "${chrootdir}/etc/udev" "${chrootdir}/usr/lib/"
88
89 # Patch jdkhome to use system JRE
90 local conf
91 for conf in etc/mplab_ide.conf etc/mplab_ipe.conf harness/etc/app.conf mplab_ipe/ipecmd.sh; do
92 sed -i -r '\@^#?jdkhome=@c\jdkhome=/usr/lib/jvm/java-8-openjdk/jre/' "${chrootdir}${_mplabx_dir}/mplab_platform/${conf}"
93 :
94 done
95
96 # Move config file to /etc (and add a symlink into the old location)
97 mv "${chrootdir}${_mplabx_dir}/mplab_platform/etc/mplab_ide.conf" "${chrootdir}/etc/"
98
99 ln -sf /etc/mplab_ide.conf "${chrootdir}${_mplabx_dir}/mplab_platform/etc/"
100
101 # Remove bundled JRE
102 rm -rf "${chrootdir}${_mplabx_dir}/sys/java"
103 rmdir "${chrootdir}${_mplabx_dir}/sys" # the intent here is to fail if something else than java is put into sys.
104
105 # Remove the /usr/local directory (now empty)
106 rm -rf "${chrootdir}/usr/local/"
107
108 _mplabcomm_chrootdir=("${chrootdir}${_mplabcomm_dir}"/*)
109 _mplabcomm_version=$(basename "${_mplabcomm_chrootdir}")
110 _mplabcomm_dstdir="${_mplabcomm_dir}/${_mplabcomm_version}"
111
112 # Symlink executables
113 ln -sf "${_mplabx_dir}/mplab_platform/bin/mplab_ide" "${chrootdir}/usr/bin/"
114 ln -sf "${_mplabx_dir}/mplab_platform/bin/mdb.sh" "${chrootdir}/usr/bin/mdb"
115 ln -sf "${_mplabx_dir}/mplab_platform/bin/prjMakefilesGenerator.sh" "${chrootdir}/usr/bin/prjMakefilesGenerator"
116 ln -sf "${_mplabx_dir}/mplab_platform/bin/mplab_ipe" "${chrootdir}/usr/bin/"
117 ln -sf "${_mplabcomm_dstdir}/lib/mchplinusbmonitor" "${chrootdir}/etc/.mplab_ide/"
118
119 # Symlink libs from MPLABCOMM
120 local lib
121 for lib in "${_mplabcomm_chrootdir}/lib/"*.so{,.*}; do
122 local bname=$(basename "$lib")
123 ln -sf "${_mplabcomm_dstdir}/lib/${bname}" "${chrootdir}/usr/lib/"
124 done
125
126 # Correctly link .so.* -> .so for all libs
127 for lib in "${chrootdir}"/usr/lib/*.so.*; do
128 local bname=$(basename "$lib")
129 local soname=${bname%.so.*}
130 ln -sf ${bname} "${chrootdir}/usr/lib/${soname}.so"
131 done
132
133 # Make lock files world-writable
134 for lockfile in mchppnplock mchpsegpnplock; do
135 chmod a+w "${chrootdir}/etc/.mplab_ide/${lockfile}"
136 done
137
138 # Tweak .desktop files for better desktop integration
139 echo "StartupWMClass=MPLAB X IDE v${pkgver}" >> "${chrootdir}/usr/share/applications/mplab_ide-v${pkgver}.desktop"
140 echo "StartupWMClass=MPLAB IPE" >> "${chrootdir}/usr/share/applications/mplab_ipe-v${pkgver}.desktop"
141
142 install -Dm 644 -t "${chrootdir}/usr/lib/systemd/system/systemd-udevd.service.d/" "${srcdir}/mplabx-override.conf"
143
144 # Install license files
145 install -Dm 644 "${srcdir}"/LICENSE "${chrootdir}/usr/share/licenses/${pkgname}/LICENSE"
146 install -Dm 644 "${_mplabcomm_chrootdir}"/MPLABCOMMLicense.txt "${chrootdir}/usr/share/licenses/${pkgname}/MPLABCOMMLicense.txt"
147
148 # Cleanup
149 rm "${chrootdir}"/{bin,etc/{group,passwd}}
150 rm -r "${chrootdir}/tmp"
151 # wtf
152 rm -f "${_mplabcomm_chrootdir}"/MPLABCOMM-*.run
153}
154
155package() {
156 # Copy the contents of the chroot to the package dir
157 cp -R "${srcdir}"/chroot/* "${pkgdir}"/
158}
159
160

Scan history

Scanned at (UTC)SeverityRules
2026-08-03 00:08:14 LOW 2
2026-08-02 00:16:08 LOW 2
2026-08-01 00:11:18 LOW 2
2026-07-31 00:14:10 LOW 2
2026-07-30 00:17:23 LOW 2
2026-07-29 00:25:53 LOW 2
2026-07-28 00:07:28 LOW 2
2026-07-27 00:24:32 LOW 2
2026-07-26 00:07:32 LOW 2
2026-07-25 00:13:44 LOW 2
2026-07-24 00:02:28 LOW 2
2026-07-23 00:14:47 LOW 2
2026-07-22 00:29:32 LOW 2
2026-07-21 00:24:15 LOW 2
2026-07-20 00:19:49 LOW 2
2026-07-19 00:17:08 LOW 2
2026-07-18 00:14:48 LOW 2
2026-07-17 00:06:16 LOW 2
2026-07-16 00:05:41 LOW 2
2026-07-15 00:09:25 LOW 2

Report a package

Reports go to the AURWatch maintainer (one person) and are read by hand. No login required.

0 / 4000
Your suggestion