Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Config update #850

Merged
merged 3 commits into from
Sep 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions autospec/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,7 @@ def __init__(self, download_path):
(r"checking for [a-zA-Z0-9\_\-]+ in (.*?)\.\.\. no", 0, None),
(r"checking for library containing (.*)... no", 0, None),
(r"checking for perl module ([a-zA-Z:]+) [0-9\.]+... no", 0, 'perl'),
("checking if (.*) is available...", 0, None),
(r"configure: error: (?:pkg-config missing|Unable to locate) (.*)", 0, None),
(r"configure: error: ([a-zA-Z0-9]+) (?:is required to build|not found)", 0, None),
(r"configure: error: Cannot find (.*)\. Make sure", 0, None),
Expand Down
12 changes: 12 additions & 0 deletions autospec/failed_commands
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,9 @@ ACL_TYPE_EXTENDED, acl-dev
ALSA, alsa-lib-dev
APR, apr-dev
APR-util, apr-util-dev
ARPACK-NG, arpack-ng-dev
ASSIMP, assimp-dev
Adwaita, libadwaita-dev
Analitza, analitza-dev
Analitza5, analitza-dev
BABL, babl-dev
Expand Down Expand Up @@ -175,6 +177,7 @@ EXPAT, expat-dev
Eet.h, eet-dev
Eigen/Core, eigen-dev
Eigen/Dense, eigen-dev
Eigen/Sparse, eigen-dev
Eigen3, eigen-dev
Epoxy, pkgconfig(epoxy)
Exiv2, exiv2-dev
Expand Down Expand Up @@ -284,6 +287,7 @@ GSTREAMER, gstreamer-dev
GSettingSchemas, gsettings-desktop-schemas
GSettingSchemas, gsettings-desktop-schemas-dev
GTK, gtk+-dev
GTK4, gtk4-dev
GnuTLS, gnutls-dev
GooglePerftools, gperftools-dev
Gperf, gperf
Expand Down Expand Up @@ -459,6 +463,7 @@ KF6NewStuff, knewstuff-def
KF6Notifications, knotifications-dev
KF6NotifyConfig, knotifyconfig-dev
KF6Package, kpackage-dev
KF6Prison, kprison-dev
KF6Purpose, purpose-dev
KF6QuickCharts, kquickcharts-dev
KF6Runner, krunner-dev
Expand Down Expand Up @@ -548,6 +553,7 @@ NETTLE, nettle-dev
NUMA, numactl-dev
Nepomuk, nepomuk-core-dev
NetworkManager, NetworkManager-dev
Nice, libnice-dev
NumPy, pypi-numpy
Numa, numactl-dev
OPENEXR, openexr-dev
Expand Down Expand Up @@ -621,6 +627,7 @@ Qt5Xdg, libqtxdg-dev
Qt5XdgIconLoader, libqtxdg-dev
Qt5XmlPatterns, qtxmlpatterns-dev
Qt6Positioning, qt6positioning-dev
Qt6Qml, qt6declarative-dev
Qt6Quick, qt6declarative-dev
Qt6QuickTimeline, qt6quicktimeline-dev
Qt6ShaderTools, qt6shadertools-dev
Expand Down Expand Up @@ -650,6 +657,7 @@ Soprano, soprano-dev
SpatialIndex, libspatialindex-dev
Sphinx, pypi-sphinx
Sqlite, sqlite-autoconf-dev
Srtp2, libsrtp-dev
Startup notification library, libnotify-dev
TBB, tbb-dev
TIFF, tiff-dev
Expand Down Expand Up @@ -1124,6 +1132,7 @@ libsecret-unstable, libsecret-dev
libsoup-2.4, libsoup-dev
libssh, libssh-dev
libssh2.h, libssh2-dev
libssl, openssl-dev
libsystemd, pkgconfig(systemd)
libtirpc (via pkg-config), pkgconfig(libtirpc)
libudev.h, systemd-dev
Expand Down Expand Up @@ -1298,6 +1307,8 @@ pycparser, pypi(pycparser)
pycurl, pypi(pycurl)
pylint, pypi(pylint)
pyperclip, pypi(pyperclip)
pypi(openvino), openvino-python3
pypi(pytorch), pytorch-python3
pytest, pypi-pytest
pytest-cov, pypi(pytest_cov)
python lxml, pypi(lxml)
Expand Down Expand Up @@ -1492,6 +1503,7 @@ yaml-cpp, yaml-cpp-dev
yarg, pypi-yarg
yasm, yasm
yytext is a pointer, flex
zconf.h, zlib-dev
zenity, zenity
zip, zip
zlib, zlib-dev
Expand Down
54 changes: 43 additions & 11 deletions autospec/license_blacklist
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
# This file is sorted with LC_COLLATE=C
# Lines beginning with '#' are ignored.
# For strings that start with '#', escape the '#' as '\#'.
=========================
%
%license
(LGPL)
(new)
(specified
*
+
-
-MIT
Expand All @@ -26,6 +26,8 @@
3-Clause
3-clause
3BSD
=========================
>=-2
@CPACK_RPM_PACKAGE_LICENSE@
AGPLv3+
ALv2
Expand All @@ -35,14 +37,20 @@ APPLICATION__TYPE
ASL
Artistic
BSD
BSD(2
BSD(3
BSD-2-Clause-Views
BSD-3
BSD-compatible
BSD-derived(Repoze)
BSD-like
BSD-style
BSDL
BSD_3_clause
BSDish
BSL
CC-BY
Clause
Commercial
Corp.
Distribution
Expand All @@ -53,37 +61,47 @@ EPL
Eclipse
Expat(MIT/X11)
Expat/MIT
FOUNDATION
Foundation
FreeBSD
GENERAL
GFDL
GNU
GPL
GPL+
GPL-1.0-only
GPL/BSD
GPL/BSD/CPL
GPLv2.1
General
IBM
Jupyter
LESSER
LGPL
LGPL+BSD
LGPL/MIT
LICENCE
Lesser
Library
Licences
License
License(2.0)
License(==-2.0)
License(>=-2)
License(>=-2.0)
License(LGPL)
License(MIT)
License,
License-2
License-2.0
License-2.0(MPL-2.0)
License-3(GPLv3)
Licensing
Lucent
MIT-0
MIT/Expat
MPL
Minpack
Modified
Mozilla
Muddy-MIT
Expand All @@ -95,9 +113,13 @@ Open
PIL
PSF-2+
PUBLIC
PYTHON
Permission
Public
Revised
SIL
SIP
SOFTWARE
See
Set
Software
Expand All @@ -111,43 +133,63 @@ UNKNOWN
Unknown
Unkown
Unlimited
VERSION-2
Version
Version-2.0
Version-3
WITH
What
\#
a
advertising
and
any
bsd
charge
classifiers)
clause)
copy
cryptsetup-OpenSSL-exception
details
domain
domain.
dual
exceptions
for
free
gpl
granted
hereby
http://nmap.org/man/man-legal.html
into
is
it
later
later(LGPLv2+)
license
licensing
ndg/httpsclient/LICENCE
new
none
obtaining
of
on
open_source
option
option)
or
or(at
others
person
public
released
software
style
terms
the
to
under?
unencumbered
unknown
unrestricted
uses
Expand All @@ -160,13 +202,3 @@ with
your
|
~
Permission
a
charge
copy
granted
hereby
obtaining
of
person
to
2 changes: 2 additions & 0 deletions autospec/license_translations
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,11 @@ Apache License 2.0, Apache-2.0
Apache License, Version 2.0, Apache-2.0
Apache, Apache-2.0
Apache-2, Apache-2.0
Apache2, Apache-2.0
Apache2.0, Apache-2.0
Apachev2, Apache-2.0
Artistic-1.0+GPL-1.0, Artistic-1.0 GPL-1.0
Artistic/GPL, Artistic-1.0-Perl GPL-1.0-or-later
Artistic_2, Artistic-2.0
BSD(3-clause), BSD-3-Clause
BSD-2-clause, BSD-2-Clause
Expand Down
26 changes: 25 additions & 1 deletion tests/test_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
import os
import tempfile
import unittest
import unittest.mock
from unittest.mock import MagicMock, mock_open, patch

import util


Expand Down Expand Up @@ -64,5 +65,28 @@ def test_binary_in_path(self):
self.assertTrue(util.binary_in_path('testbin'))
self.assertEqual(util.os_paths, [tmpd])

def test__process_build_log_bad_patch(self):
"""
Test _process_build_log with a bad patch
"""
def isfile_mock(_):
return True
isfile_backup = util.os.path.isfile
util.os.path.isfile = isfile_mock
call_backup = util.call
util.call = MagicMock()
open_name = 'util.open_auto'
content = "Patch #1 (bad.patch):\nHunk #1 FAILED at 1."
m_open = mock_open(read_data=content)
with patch(open_name, m_open, create=True):
util._process_build_log('filename')

util.os.path.isfile = isfile_backup
mock_call = util.call
util.call = call_backup
self.assertTrue(len(mock_call.mock_calls) == 3)



if __name__ == '__main__':
unittest.main(buffer=True)
Loading