Import Debian changes 2.4.1-0.1
libffado (2.4.1-0.1) unstable; urgency=medium
* Non-maintainer upload.
* New upstream release. Closes: #887846.
Drop sconstruct.patch, applied upstream.
* Switch watch file to format 4.
* Remove obsolete control.in.
The last motivation seems to be @cdbs@, now unused.
* Remove debian/*.dirs, obsolete with recent debhelper.
* Delete trailing whitespaces in this changelog.
* Drop ffado.1 uninstalled Debian manpage.
* Pass Debian build flags to scons and show them in log.
This probably fixes #864717.
Enable all hardening flags.
Link with --as-needed in order to reduce dependencies.
* Build-Dependencies: drop dh-exec (looking for a maintainer).
Sort, drop autotools-dev, dh-buildinfo (see 2.3.0-1 and -3).
* Also drop licensecheck, a long warning about it being unavailable
is better than a short failure report.
* Standards-version: 4.1.4.
* Move ffado-debug manual page to the package providing the executable.
Break/Replace accordingly.
* Replace Debian manpages with upstream manpages when available.
Move manpages to a subdirectory to simplify packaging.
* Check and update the copyright file.
* Clean all *.pyc instead of only one.
* rules: always call scons with same arguments.
* rules: drop makeshlib version argument.
Redundant with "Depend: libffado2 (=${binary:Version}".
* rules: report failures (mkdir -p, rm -f report unexpected problems).
* Drop unneeded shlib:Depends.
-dev does not provide binaries, mixer is arch-independent.
* Switch to python3 and qt4.
* Improve generation of the debug library variant.
Split build and install steps again.
Avoid building twice during -indep builds.
Let the debug library be a Make target, avoiding two scons rebuilds in
case of error in later steps.
* Style. Drop debian/tmp/ prefix from debian/*.install.
* Move the debug library into ffado-tools package.
Almost no user will ever use the debug library without the ffado-debug
wrapper, and most people installing libffado2 loose space for no purpose.
The break/replace dependency already exists, see above.
* .gitignore: keep upstream .gitignore untouched.
* Lintian override explaining why ffado-tools:
package-has-unnecessary-activation-of-ldconfig-trigger
cannot be fixed inside ffado.
* Minor fixes in dependencies.
An explicit python interpreter is redundant with ${python3:Depends}.
The 2.4.1~ snapshots should not conflict with themselves.
* Ensure AUTHORS and README will be installed with debhelper >= 11.
For now, debhelper automatically embeds them in every package.
* Remove obsolete parts of debian/rules.
DEB_CLEAN_EXCLUDE is older than the VCS.
Without it, "rm -f $(DEB_DESTDIR)" is not needed anymore.
DEB_PYTHON3_MODULE_PACKAGES is used for binary packages containing
python modules, not for an executable.
cdbs seems to create DEB_DESTDIR by itself.
cdbs knows that reverse-config should be executed before clean.
config.log scache.conf .sconf_temp are not created anymore.
* Install mixer icon for desktop file. Closes: #834140.
* Upstream has accepted to remove locale dependency from static_info.txt
for reproducible contents, and to install it into /usr/lib.
It may be installed into the binary packages again.
[Felipe Sateler]
* Change maintainer address to debian-multimedia@lists.debian.org.
Nicolas Boulenguez authored 6 years ago
James Cowgill committed 6 years ago
21 | 21 | # You should have received a copy of the GNU General Public License |
22 | 22 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
23 | 23 | # |
24 | from __future__ import print_function | |
24 | 25 | |
25 | 26 | FFADO_API_VERSION = "9" |
26 | FFADO_VERSION="2.4.0" | |
27 | ||
28 | from subprocess import Popen, PIPE | |
27 | FFADO_VERSION="2.4.1" | |
28 | ||
29 | from subprocess import Popen, PIPE, check_output | |
29 | 30 | import os |
30 | 31 | import re |
32 | import sys | |
31 | 33 | from string import Template |
32 | import imp | |
33 | 34 | import distutils.sysconfig |
34 | 35 | |
35 | 36 | if not os.path.isdir( "cache" ): |
36 | os.makedirs( "cache" ) | |
37 | os.makedirs( "cache" ) | |
37 | 38 | |
38 | 39 | opts = Variables( "cache/options.cache" ) |
39 | 40 | |
48 | 49 | PathVariable( "LIBDIR", "Overwrite the directory where libs are installed to.", "$PREFIX/lib", PathVariable.PathAccept ), |
49 | 50 | PathVariable( "INCLUDEDIR", "Overwrite the directory where headers are installed to.", "$PREFIX/include", PathVariable.PathAccept ), |
50 | 51 | PathVariable( "SHAREDIR", "Overwrite the directory where misc shared files are installed to.", "$PREFIX/share/libffado", PathVariable.PathAccept ), |
52 | PathVariable( "LIBDATADIR", "Location for architecture-dependent data.", "$LIBDIR/libffado", PathVariable.PathAccept ), | |
51 | 53 | PathVariable( "MANDIR", "Overwrite the directory where manpages are installed", "$PREFIX/man", PathVariable.PathAccept ), |
52 | 54 | PathVariable( "PYPKGDIR", "The directory where the python modules get installed.", |
53 | 55 | distutils.sysconfig.get_python_lib( prefix="$PREFIX" ), PathVariable.PathAccept ), |
67 | 69 | this code.""", False ), |
68 | 70 | BoolVariable( "ENABLE_ALL", "Enable/Disable support for all devices.", False ), |
69 | 71 | BoolVariable( "SERIALIZE_USE_EXPAT", "Use libexpat for XML serialization.", False ), |
72 | EnumVariable( "BUILD_DOC", "Build API documentation", 'none', allowed_values=('all', 'user', 'none'), ignorecase=2), | |
70 | 73 | EnumVariable( "BUILD_MIXER", "Build the ffado-mixer", 'auto', allowed_values=('auto', 'true', 'false'), ignorecase=2), |
71 | 74 | BoolVariable( "BUILD_TESTS", """\ |
72 | 75 | Build the tests in their directory. As some contain quite some functionality, |
81 | 84 | BoolVariable( "CUSTOM_ENV", "Respect CC, CXX, CFLAGS, CXXFLAGS and LDFLAGS.\nOnly meant for distributors and gentoo-users who want to over-optimize their build.\n Using this is not supported by the ffado-devs!", False ), |
82 | 85 | ( "COMPILE_FLAGS", "Deprecated (use CFLAGS and CXXFLAGS with CUSTOM_ENV=True instead). Add additional flags to the environment.\nOnly meant for distributors and gentoo-users who want to over-optimize their build.\n Using this is not supported by the ffado-devs!" ), |
83 | 86 | EnumVariable( "ENABLE_SETBUFFERSIZE_API_VER", "Report API version at runtime which includes support for dynamic buffer resizing (requires recent jack).", 'auto', allowed_values=('auto', 'true', 'false', 'force'), ignorecase=2), |
87 | ("PYTHON_INTERPRETER", "Python interpreter to be used by FFADO installation.", "/usr/bin/python"), | |
84 | 88 | |
85 | 89 | ) |
86 | 90 | |
141 | 145 | |
142 | 146 | # make sure the necessary dirs exist |
143 | 147 | if not os.path.isdir( "cache" ): |
144 | os.makedirs( "cache" ) | |
148 | os.makedirs( "cache" ) | |
145 | 149 | if not os.path.isdir( 'cache/objects' ): |
146 | 150 | os.makedirs( 'cache/objects' ) |
147 | 151 | |
151 | 155 | |
152 | 156 | def ConfigGuess( context ): |
153 | 157 | context.Message( "Trying to find the system triple: " ) |
154 | ret = os.popen( "/bin/sh admin/config.guess" ).read()[:-1] | |
158 | ret = check_output(("/bin/sh", "admin/config.guess")).rstrip() | |
155 | 159 | context.Result( ret ) |
156 | return ret | |
160 | return ret.decode() | |
157 | 161 | |
158 | 162 | def CheckForApp( context, app ): |
159 | 163 | context.Message( "Checking whether '" + app + "' executes " ) |
163 | 167 | |
164 | 168 | def CheckForPyModule( context, module ): |
165 | 169 | context.Message( "Checking for the python module '" + module + "' " ) |
166 | ret = context.TryAction( "python $SOURCE", "import %s" % module, ".py" ) | |
170 | ret = context.TryAction( "$PYTHON_INTERPRETER $SOURCE", "import %s" % module, ".py" ) | |
167 | 171 | context.Result( ret[0] ) |
168 | 172 | return ret[0] |
169 | 173 | |
214 | 218 | |
215 | 219 | version_re = re.compile(r'^(\d+)\.(\d+)\.(\d+)') |
216 | 220 | |
217 | def VersionInt(vers): | |
218 | match = version_re.match(vers) | |
219 | if not match: | |
220 | return -1 | |
221 | (maj, min, patch) = match.group(1, 2, 3) | |
222 | # For now allow "min" to run up to 65535. "maj" and "patch" are | |
223 | # restricted to 0-255. | |
224 | return (int(maj) << 24) | (int(min) << 8) | int(patch) | |
225 | ||
226 | 221 | def CheckJackdVer(): |
227 | # Suppress newline in python 2 and 3 | |
228 | sys.stdout.write('Checking jackd version...') | |
229 | sys.stdout.flush() | |
230 | ret = Popen("which jackd >/dev/null 2>&1 && jackd --version | tail -n 1 | cut -d ' ' -f 3", shell=True, stdout=PIPE).stdout.read()[:-1].decode() | |
231 | if (ret == ""): | |
222 | print('Checking jackd version...', end='') | |
223 | popen = Popen(("which", 'jackd'), stdout=PIPE, stderr=PIPE) | |
224 | stdout, stderr = popen.communicate() | |
225 | assert popen.returncode in (0, 1), "which returned a unexpected status" | |
226 | if popen.returncode == 1: | |
232 | 227 | print("not installed") |
233 | return -1 | |
234 | else: | |
235 | print(ret) | |
236 | return VersionInt(ret) | |
228 | return None | |
229 | jackd = stdout.decode ().rstrip () | |
230 | ret = check_output ((jackd, '--version')).decode() .rstrip () | |
231 | ret = ret.split ('\n') [-1]; # Last line. | |
232 | ret = ret.split () [2]; # Third field. | |
233 | if not version_re.match (ret): | |
234 | print("failed to parse version") | |
235 | return None | |
236 | print (ret) | |
237 | ||
238 | # Trim off any "rc" (release candidate) components from the end of the | |
239 | # version string | |
240 | ret = ret.split ('rc')[0] | |
241 | ret = ret.split ('.') | |
242 | ret = map (int, ret) | |
243 | return tuple (ret) | |
237 | 244 | |
238 | 245 | if env['SERIALIZE_USE_EXPAT']: |
239 | 246 | env['SERIALIZE_USE_EXPAT']=1 |
282 | 289 | if not('libxml++-3.0' in pkgs): |
283 | 290 | pkgs['libxml++-2.6'] = '2.13.0' |
284 | 291 | |
285 | # Provide a way for users to compile newer libffado which will work | |
292 | # Provide a way for users to compile newer libffado which will work | |
286 | 293 | # against older jack installations which will not accept the new API |
287 | 294 | # version reported at runtime. |
288 | 295 | have_jack = conf.CheckPKG('jack') |
291 | 298 | good_jack2 = conf.CheckPKG('jack >= 1.9.9') |
292 | 299 | else: |
293 | 300 | jackd_ver = CheckJackdVer() |
294 | if (jackd_ver != -1): | |
301 | if jackd_ver: | |
295 | 302 | # If jackd is unknown to pkg-config but is never-the-less |
296 | 303 | # runnable, use the version number reported by it. This means |
297 | 304 | # users don't have to have jack development files present on |
298 | 305 | # their system for this to work. |
299 | have_jack = (jackd_ver >= VersionInt('0.0.0')) | |
300 | good_jack1 = (jackd_ver < VersionInt('1.9.0')) and (jackd_ver >= VersionInt('0.121.4')) | |
301 | good_jack2 = (jackd_ver >= VersionInt('1.9.9')) | |
306 | have_jack = jackd_ver >= (0, 0, 0) | |
307 | good_jack1 = jackd_ver < (1, 9, 0) and jackd_ver >= (0, 121, 4) | |
308 | good_jack2 = jackd_ver >= (1, 9, 9) | |
302 | 309 | |
303 | 310 | if env['ENABLE_SETBUFFERSIZE_API_VER'] == 'auto': |
304 | 311 | if not(have_jack): |
305 | 312 | print(""" |
306 | No Jack Audio Connection Kit (JACK) installed: assuming a FFADO | |
313 | No Jack Audio Connection Kit (JACK) installed: assuming a FFADO | |
307 | 314 | setbuffersize-compatible version will be used. |
308 | 315 | """) |
309 | 316 | elif not(good_jack1 or good_jack2): |
310 | 317 | FFADO_API_VERSION="8" |
311 | 318 | print(""" |
312 | Installed Jack Audio Connection Kit (JACK) jack does not support FFADO | |
313 | setbuffersize API: will report earlier API version at runtime. Consider | |
314 | upgrading to jack1 >=0.122.0 or jack2 >=1.9.9 at some point, and then | |
319 | Installed Jack Audio Connection Kit (JACK) jack does not support FFADO | |
320 | setbuffersize API: will report earlier API version at runtime. Consider | |
321 | upgrading to jack1 >=0.122.0 or jack2 >=1.9.9 at some point, and then | |
315 | 322 | recompile ffado to gain access to this added feature. |
316 | 323 | """) |
317 | 324 | else: |
319 | 326 | elif env['ENABLE_SETBUFFERSIZE_API_VER'] == 'true': |
320 | 327 | if (have_jack and not(good_jack1) and not(good_jack2)): |
321 | 328 | print(""" |
322 | SetBufferSize API version is enabled but no suitable version of Jack Audio | |
323 | Connection Kit (JACK) has been found. The resulting FFADO would cause your | |
324 | jackd to abort with "incompatible FFADO version". Please upgrade to | |
329 | SetBufferSize API version is enabled but no suitable version of Jack Audio | |
330 | Connection Kit (JACK) has been found. The resulting FFADO would cause your | |
331 | jackd to abort with "incompatible FFADO version". Please upgrade to | |
325 | 332 | jack1 >=0.122.0 or jack2 >=1.9.9, or set ENABLE_SETBUFFERSIZE_API_VER to "auto" |
326 | 333 | or "false". |
327 | 334 | """) |
328 | # Although it's not strictly an error, in almost every case that | |
335 | # Although it's not strictly an error, in almost every case that | |
329 | 336 | # this occurs the user will want to know about it and fix the |
330 | 337 | # problem, so we exit so they're guaranteed of seeing the above |
331 | 338 | # message. |
356 | 363 | """) |
357 | 364 | Exit( 1 ) |
358 | 365 | |
359 | # libxml++-2.6 requires a c++11 compiler as of version 2.39.1. The | |
366 | # libxml++-2.6 requires a c++11 compiler as of version 2.39.1. The | |
360 | 367 | # gnu++11 standard seems to work both with these later libxml++ versions |
361 | 368 | # and ffado itself, although a significant number of warnings are |
362 | 369 | # produced. Add the necessary option to CXXFLAGS if required. |
394 | 401 | |
395 | 402 | # PyQT checks |
396 | 403 | if env['BUILD_MIXER'] != 'false': |
397 | have_dbus = (conf.CheckForApp( 'which pyuic4' ) and conf.CheckForPyModule( 'dbus.mainloop.qt' )) | |
398 | have_pyqt4 = (conf.CheckForApp( 'which pyuic4' ) and conf.CheckForPyModule( 'PyQt4' )) | |
399 | have_pyqt5 = (conf.CheckForApp( 'which pyuic5' ) and conf.CheckForPyModule( 'PyQt5' )) | |
400 | if ((have_pyqt4 or have_pyqt5) and have_dbus): | |
404 | if ( conf.CheckForApp( 'which pyuic4' ) \ | |
405 | and conf.CheckForPyModule( 'PyQt4' ) \ | |
406 | and conf.CheckForPyModule( 'dbus.mainloop.qt' )) \ | |
407 | or ( conf.CheckForApp( 'which pyuic5' ) \ | |
408 | and conf.CheckForPyModule( 'PyQt5' ) \ | |
409 | and conf.CheckForPyModule( 'dbus.mainloop.pyqt5' )): | |
401 | 410 | env['BUILD_MIXER'] = 'true' |
402 | 411 | elif not env.GetOption('clean'): |
403 | 412 | if env['BUILD_MIXER'] == 'auto': |
404 | 413 | env['BUILD_MIXER'] = 'false' |
405 | 414 | print(""" |
406 | The prerequisites ('pyuic4'/'pyuic5' and the python-modules 'dbus' and | |
407 | 'PyQt4'/'PyQt5', the packages could be named like dbus-python and PyQt) to | |
415 | The prerequisites ('pyuic4'/'pyuic5' and the python-modules 'dbus' and | |
416 | 'PyQt4'/'PyQt5', the packages could be named like dbus-python and PyQt) to | |
408 | 417 | build the mixer were not found. Therefore the qt mixer will not be installed.""") |
409 | 418 | else: # env['BUILD_MIXER'] == 'true' |
410 | 419 | print(""" |
411 | The prerequisites ('pyuic4'/'pyuic5' and the python-modules 'dbus' and | |
412 | 'PyQt4'/'PyQt5', the packages could be named like dbus-python and PyQt) to | |
420 | The prerequisites ('pyuic4'/'pyuic5' and the python-modules 'dbus' and | |
421 | 'PyQt4'/'PyQt5', the packages could be named like dbus-python and PyQt) to | |
413 | 422 | build the mixer were not found, but BUILD_MIXER was requested.""") |
414 | 423 | Exit( 1 ) |
415 | 424 | |
514 | 523 | env['LIBDIR'] = Template( env['LIBDIR'] ).safe_substitute( env ) |
515 | 524 | env['INCLUDEDIR'] = Template( env['INCLUDEDIR'] ).safe_substitute( env ) |
516 | 525 | env['SHAREDIR'] = Template( env['SHAREDIR'] ).safe_substitute( env ) |
526 | env['LIBDATADIR'] = Template( env['LIBDATADIR'] ).safe_substitute( env ) | |
517 | 527 | env['UDEVDIR'] = Template( env['UDEVDIR'] ).safe_substitute( env ) |
528 | env['PYTHON_INTERPRETER'] = Template( env['PYTHON_INTERPRETER'] ).safe_substitute( env ) | |
518 | 529 | env['prefix'] = Template( env.destdir + env['PREFIX'] ).safe_substitute( env ) |
519 | 530 | env['bindir'] = Template( env.destdir + env['BINDIR'] ).safe_substitute( env ) |
520 | 531 | env['libdir'] = Template( env.destdir + env['LIBDIR'] ).safe_substitute( env ) |
521 | 532 | env['includedir'] = Template( env.destdir + env['INCLUDEDIR'] ).safe_substitute( env ) |
522 | 533 | env['sharedir'] = Template( env.destdir + env['SHAREDIR'] ).safe_substitute( env ) |
534 | env['libdatadir'] = Template( env.destdir + env['LIBDATADIR'] ).safe_substitute( env ) | |
523 | 535 | env['mandir'] = Template( env.destdir + env['MANDIR'] ).safe_substitute( env ) |
524 | 536 | env['pypkgdir'] = Template( env.destdir + env['PYPKGDIR'] ).safe_substitute( env ) |
525 | 537 | env['udevdir'] = Template( env.destdir + env['UDEVDIR'] ).safe_substitute( env ) |
526 | 538 | env['PYPKGDIR'] = Template( env['PYPKGDIR'] ).safe_substitute( env ) |
539 | env['metainfodir'] = Template( env.destdir + "/usr/share/metainfo" ).safe_substitute( env ) | |
527 | 540 | |
528 | 541 | env.Command( target=env['sharedir'], source="", action=Mkdir( env['sharedir'] ) ) |
529 | 542 | |
530 | 543 | env.Alias( "install", env['libdir'] ) |
531 | 544 | env.Alias( "install", env['includedir'] ) |
532 | 545 | env.Alias( "install", env['sharedir'] ) |
546 | env.Alias( "install", env['libdatadir'] ) | |
533 | 547 | env.Alias( "install", env['bindir'] ) |
534 | 548 | env.Alias( "install", env['mandir'] ) |
535 | 549 | if env['BUILD_MIXER'] == 'true': |
536 | 550 | env.Alias( "install", env['pypkgdir'] ) |
551 | env.Alias( "install", env['metainfodir'] ) | |
537 | 552 | |
538 | 553 | # |
539 | 554 | # shamelessly copied from the Ardour scons file |
552 | 567 | |
553 | 568 | needs_fPIC = False |
554 | 569 | |
555 | #=== Begin Revised CXXFLAGS ========================================= | |
556 | def outputof(*cmd): | |
557 | """Run a command without running a shell, return cmd's stdout | |
558 | """ | |
559 | p = Popen(cmd, stdout=PIPE) | |
560 | return p.communicate()[0] | |
561 | ||
570 | #=== Begin Revised CXXFLAGS ========================================= | |
562 | 571 | def cpuinfo_kv(): |
563 | 572 | """generator which reads lines from Linux /proc/cpuinfo and splits them |
564 | 573 | into key:value tokens and yields (key, value) tuple. |
565 | 574 | """ |
566 | f = open('/proc/cpuinfo', 'r') | |
567 | for line in f: | |
575 | with open('/proc/cpuinfo', 'r') as f: | |
576 | for line in f: | |
568 | 577 | line = line.strip() |
569 | 578 | if line: |
570 | 579 | k,v = line.split(':', 1) |
571 | 580 | yield (k.strip(), v.strip()) |
572 | f.close() | |
573 | ||
574 | 581 | |
575 | 582 | class CpuInfo (object): |
576 | 583 | """Collects information about the CPU, mainly from /proc/cpuinfo |
687 | 694 | # run a completely 32-bit system on a 64-bit capable CPU. |
688 | 695 | answer = None |
689 | 696 | |
690 | # If setting DIST_TARGET to i686 on a 64-bit CPU to facilitate | |
697 | # If setting DIST_TARGET to i686 on a 64-bit CPU to facilitate | |
691 | 698 | # compilation of a multilib environment, force 32-bit. |
692 | 699 | if env['DIST_TARGET'] == 'i686': |
693 | 700 | return True |
704 | 711 | real_exe = exe |
705 | 712 | # presumably if a person is running this script, they should have |
706 | 713 | # a gcc toolchain installed... |
707 | x = outputof('objdump', '-Wi', real_exe) | |
714 | x = check_output(('objdump', '-Wi', real_exe)).decode() | |
708 | 715 | # should emit a line that looks like this: |
709 | 716 | # /bin/mount: file format elf32-i386 |
710 | 717 | # or like this: |
845 | 852 | env.MergeFlags( opt_flags ) |
846 | 853 | print("Doing an optimized build...") |
847 | 854 | |
848 | env['REVISION'] = os.popen('svnversion .').read()[:-1] | |
855 | try: | |
856 | env['REVISION'] = check_output(('svnversion', '.',)).decode().rstrip() | |
857 | except: | |
858 | env['REVISION'] = '' | |
859 | ||
849 | 860 | # This may be as simple as '89' or as complex as '4123:4184M'. |
850 | 861 | # We'll just use the last bit. |
851 | 862 | env['REVISION'] = env['REVISION'].split(':')[-1] |
852 | 863 | |
864 | # Assume an unversioned directory indicates a release. | |
865 | if env['REVISION'].startswith ('Unversioned'): | |
866 | env['REVISION'] = '' | |
867 | ||
853 | 868 | # try to circumvent localized versions |
854 | if len(env['REVISION']) >= 5 and env['REVISION'][0:6] == 'export': | |
869 | if env['REVISION'].startswith ('export'): | |
855 | 870 | env['REVISION'] = '' |
856 | 871 | |
857 | 872 | # avoid the 1.999.41- type of version for exported versions |
858 | 873 | if env['REVISION'] != '': |
859 | env['REVISIONSTRING'] = '-' + env['REVISION'] | |
874 | env['REVISIONSTRING'] = '-' + env['REVISION'] | |
860 | 875 | else: |
861 | env['REVISIONSTRING'] = '' | |
876 | env['REVISIONSTRING'] = '' | |
862 | 877 | |
863 | 878 | env['FFADO_API_VERSION'] = FFADO_API_VERSION |
864 | 879 | |
915 | 930 | Default( 'support' ) |
916 | 931 | if env['BUILD_TESTS']: |
917 | 932 | Default( 'tests' ) |
933 | if env['BUILD_DOC'] != 'none': | |
934 | Default( 'doc' ) | |
935 | ||
936 | env.Install( env['metainfodir'], "support/xdg/ffado-mixer.appdata.xml" ) | |
918 | 937 | |
919 | 938 | # |
920 | 939 | # Deal with the DESTDIR vs. xdg-tools conflict (which is basicely that the |
21 | 21 | # |
22 | 22 | |
23 | 23 | # from: http://www.qandr.org/quentin/writings/debscons.html |
24 | import os, shutil, sys | |
24 | import os | |
25 | ||
25 | 26 | Import('env') # exported by parent SConstruct |
26 | 27 | |
27 | 28 | # Here's the core info for the package |
40 | 41 | DEBFILES = [ |
41 | 42 | # Now we specify the files to be included in the .deb |
42 | 43 | # Where they should go, and where they should be copied from. |
43 | # If you have a lot of files, you may wish to generate this | |
44 | # If you have a lot of files, you may wish to generate this | |
44 | 45 | # list in some other way. |
45 | 46 | ("usr/lib/libffado.so", "#src/libffado.so"), |
46 | 47 | ("usr/lib/pkgconfig/libffado.pc", "#/libffado.pc"), |
122 | 123 | control_info = CONTROL_TEMPLATE % ( |
123 | 124 | DEBNAME, installed_size, DEBMAINT, DEBARCH, DEBVERSION, |
124 | 125 | DEBDEPENDS, DEBDESC) |
125 | f = open(str(target[0]), 'w') | |
126 | f.write(control_info) | |
127 | f.close() | |
126 | with open(str(target[0]), 'w') as f: | |
127 | f.write(control_info) | |
128 | 128 | |
129 | 129 | # We can generate the control file by calling make_control |
130 | 130 | env.Command(DEBCONTROLFILE, None, make_control) |
131 | 131 | |
132 | 132 | # And we can generate the .deb file by calling dpkg-deb |
133 | 133 | env.Command(debpkg, DEBCONTROLFILE, |
134 | "dpkg-deb -b %s %s" % ("deb/%s" % DEBNAME, "$TARGET")) | |
134 | "dpkg-deb -b %s %s" % ("deb/%s" % DEBNAME, "$TARGET")) |
0 | libffado (2.4.1-0.1) unstable; urgency=medium | |
1 | ||
2 | * Non-maintainer upload. | |
3 | * New upstream release. Closes: #887846. | |
4 | Drop sconstruct.patch, applied upstream. | |
5 | * Switch watch file to format 4. | |
6 | * Remove obsolete control.in. | |
7 | The last motivation seems to be @cdbs@, now unused. | |
8 | * Remove debian/*.dirs, obsolete with recent debhelper. | |
9 | * Delete trailing whitespaces in this changelog. | |
10 | * Drop ffado.1 uninstalled Debian manpage. | |
11 | * Pass Debian build flags to scons and show them in log. | |
12 | This probably fixes #864717. | |
13 | Enable all hardening flags. | |
14 | Link with --as-needed in order to reduce dependencies. | |
15 | * Build-Dependencies: drop dh-exec (looking for a maintainer). | |
16 | Sort, drop autotools-dev, dh-buildinfo (see 2.3.0-1 and -3). | |
17 | * Also drop licensecheck, a long warning about it being unavailable | |
18 | is better than a short failure report. | |
19 | * Standards-version: 4.1.4. | |
20 | * Move ffado-debug manual page to the package providing the executable. | |
21 | Break/Replace accordingly. | |
22 | * Replace Debian manpages with upstream manpages when available. | |
23 | Move manpages to a subdirectory to simplify packaging. | |
24 | * Check and update the copyright file. | |
25 | * Clean all *.pyc instead of only one. | |
26 | * rules: always call scons with same arguments. | |
27 | * rules: drop makeshlib version argument. | |
28 | Redundant with "Depend: libffado2 (=${binary:Version}". | |
29 | * rules: report failures (mkdir -p, rm -f report unexpected problems). | |
30 | * Drop unneeded shlib:Depends. | |
31 | -dev does not provide binaries, mixer is arch-independent. | |
32 | * Switch to python3 and qt4. | |
33 | * Improve generation of the debug library variant. | |
34 | Split build and install steps again. | |
35 | Avoid building twice during -indep builds. | |
36 | Let the debug library be a Make target, avoiding two scons rebuilds in | |
37 | case of error in later steps. | |
38 | * Style. Drop debian/tmp/ prefix from debian/*.install. | |
39 | * Move the debug library into ffado-tools package. | |
40 | Almost no user will ever use the debug library without the ffado-debug | |
41 | wrapper, and most people installing libffado2 loose space for no purpose. | |
42 | The break/replace dependency already exists, see above. | |
43 | * .gitignore: keep upstream .gitignore untouched. | |
44 | * Lintian override explaining why ffado-tools: | |
45 | package-has-unnecessary-activation-of-ldconfig-trigger | |
46 | cannot be fixed inside ffado. | |
47 | * Minor fixes in dependencies. | |
48 | An explicit python interpreter is redundant with ${python3:Depends}. | |
49 | The 2.4.1~ snapshots should not conflict with themselves. | |
50 | * Ensure AUTHORS and README will be installed with debhelper >= 11. | |
51 | For now, debhelper automatically embeds them in every package. | |
52 | * Remove obsolete parts of debian/rules. | |
53 | DEB_CLEAN_EXCLUDE is older than the VCS. | |
54 | Without it, "rm -f $(DEB_DESTDIR)" is not needed anymore. | |
55 | DEB_PYTHON3_MODULE_PACKAGES is used for binary packages containing | |
56 | python modules, not for an executable. | |
57 | cdbs seems to create DEB_DESTDIR by itself. | |
58 | cdbs knows that reverse-config should be executed before clean. | |
59 | config.log scache.conf .sconf_temp are not created anymore. | |
60 | * Install mixer icon for desktop file. Closes: #834140. | |
61 | * Upstream has accepted to remove locale dependency from static_info.txt | |
62 | for reproducible contents, and to install it into /usr/lib. | |
63 | It may be installed into the binary packages again. | |
64 | ||
65 | [Felipe Sateler] | |
66 | * Change maintainer address to debian-multimedia@lists.debian.org. | |
67 | ||
68 | -- Nicolas Boulenguez <nicolas@debian.org> Thu, 19 Apr 2018 22:03:01 +0200 | |
69 | ||
0 | 70 | libffado (2.4.0-2) unstable; urgency=medium |
1 | 71 | |
2 | 72 | * Update Vcs tags to point at salsa |
412 | 482 | * Initial release |
413 | 483 | |
414 | 484 | -- Pieter Palmers <pieter.palmers@ffado.org> Wed, 29 Oct 2008 21:48:57 +0100 |
415 |
5 | 5 | Free Ekanayaka <freee@debian.org>, |
6 | 6 | Jonas Smedegaard <dr@jones.dk>, |
7 | 7 | Build-Depends: |
8 | cdbs, | |
8 | 9 | dbus (>= 1.0.0), |
10 | # Until CDBS does support debhelper 11, see #885407. | |
11 | debhelper (>= 10), | |
9 | 12 | dh-python, |
10 | 13 | libconfig++-dev, |
11 | 14 | libdbus-1-dev, |
17 | 20 | libxml++2.6-dev, |
18 | 21 | libxml2-dev (>= 2.6.13), |
19 | 22 | pkg-config, |
20 | pyqt4-dev-tools, | |
21 | python (>= 2.6.6-3~), | |
22 | python-dbus, | |
23 | python-qt4, | |
24 | python-qt4-dbus, | |
23 | pyqt5-dev-tools, | |
24 | python3, | |
25 | python3-dbus, | |
26 | python3-dbus.mainloop.pyqt5, | |
27 | python3-pyqt5, | |
25 | 28 | scons, |
26 | dh-exec, | |
27 | cdbs, | |
28 | autotools-dev, | |
29 | debhelper (>= 10~), | |
30 | dh-buildinfo, | |
31 | licensecheck, | |
32 | Standards-Version: 3.9.8 | |
29 | Standards-Version: 4.1.4 | |
33 | 30 | Section: libs |
34 | 31 | Homepage: http://www.ffado.org/ |
35 | 32 | Vcs-Git: https://salsa.debian.org/multimedia-team/ffado.git |
43 | 40 | libffado2 (= ${binary:Version}), |
44 | 41 | libxml2-dev, |
45 | 42 | ${misc:Depends}, |
46 | ${shlibs:Depends}, | |
47 | 43 | Description: FFADO API - development files |
48 | 44 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. |
49 | 45 | . |
72 | 68 | Depends: |
73 | 69 | dbus (>= 1.0.0), |
74 | 70 | libffado2 (= ${binary:Version}), |
75 | python, | |
76 | 71 | ${misc:Depends}, |
72 | ${python3:Depends}, | |
77 | 73 | ${shlibs:Depends}, |
78 | 74 | Replaces: |
79 | 75 | ffado-mixer-qt4 (<< 2.0.1+svn1856-2~), |
80 | libffado2 (<< 2.3.0-3), | |
76 | libffado2 (<< 2.4.1~), | |
81 | 77 | Breaks: |
82 | 78 | ffado-mixer-qt4 (<< 2.0.1+svn1856-2~), |
83 | 79 | jackd1-firewire (<< 1:0.121.3+20120418git75e3e20b-1), |
84 | 80 | jackd2-firewire (<< 1.9.8~dfsg.3+20120418gitf82ec715-1), |
85 | libffado2 (<< 2.3.0-3), | |
81 | libffado2 (<< 2.4.1~), | |
86 | 82 | Description: FFADO debugging and firmware tools |
87 | 83 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. |
88 | 84 | . |
123 | 119 | Depends: |
124 | 120 | ffado-dbus-server (>= ${source:Version}), |
125 | 121 | ffado-tools (>= ${source:Version}), |
126 | python, | |
127 | python-dbus, | |
128 | python-qt4, | |
129 | python-qt4-dbus, | |
122 | python3-dbus, | |
123 | python3-dbus.mainloop.pyqt5, | |
124 | python3-pyqt5, | |
130 | 125 | ${misc:Depends}, |
131 | ${python:Depends}, | |
132 | ${shlibs:Depends}, | |
133 | Description: FFADO D-Bus mixer applets (QT4) | |
126 | ${python3:Depends}, | |
127 | Description: FFADO D-Bus mixer applets | |
134 | 128 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. |
135 | 129 | . |
136 | 130 | The FFADO library permits discovering and configuring such |
137 | 131 | devices and provides an API for streaming clients. |
138 | 132 | . |
139 | 133 | This package holds the mixer and control applications that |
140 | communicate with ffado-dbus-server. (Qt4 version) | |
134 | communicate with ffado-dbus-server. | |
135 | . | |
136 | Despite the package name, the GUI has been updated. |
0 | Source: libffado | |
1 | Priority: optional | |
2 | Maintainer: Debian Multimedia Maintainers <pkg-multimedia-maintainers@lists.alioth.debian.org> | |
3 | Uploaders: | |
4 | Adrian Knoth <adi@drcomp.erfurt.thur.de>, | |
5 | Free Ekanayaka <freee@debian.org>, | |
6 | Jonas Smedegaard <dr@jones.dk>, | |
7 | Build-Depends: | |
8 | dbus (>= 1.0.0), | |
9 | dh-python, | |
10 | libconfig++-dev, | |
11 | libdbus-1-dev, | |
12 | libdbus-c++-bin, | |
13 | libdbus-c++-dev, | |
14 | libexpat1-dev, | |
15 | libiec61883-dev (>= 1.1.0), | |
16 | libraw1394-dev (>= 1.3.0), | |
17 | libxml++2.6-dev, | |
18 | libxml2-dev (>= 2.6.13), | |
19 | pkg-config, | |
20 | pyqt4-dev-tools, | |
21 | python (>= 2.6.6-3~), | |
22 | python-dbus, | |
23 | python-qt4, | |
24 | python-qt4-dbus, | |
25 | scons, | |
26 | dh-exec, | |
27 | @cdbs@, | |
28 | Standards-Version: 3.9.8 | |
29 | Section: libs | |
30 | Homepage: http://www.ffado.org/ | |
31 | Vcs-Git: https://salsa.debian.org/multimedia-team/ffado.git | |
32 | Vcs-Browser: https://salsa.debian.org/multimedia-team/ffado | |
33 | ||
34 | Package: libffado-dev | |
35 | Section: libdevel | |
36 | Architecture: linux-any | |
37 | Multi-Arch: same | |
38 | Depends: | |
39 | libffado2 (= ${binary:Version}), | |
40 | libxml2-dev, | |
41 | ${misc:Depends}, | |
42 | ${shlibs:Depends}, | |
43 | Description: FFADO API - development files | |
44 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. | |
45 | . | |
46 | The FFADO library permits discovering and configuring such | |
47 | devices and provides an API for streaming clients. | |
48 | . | |
49 | This package holds the development files. | |
50 | ||
51 | Package: libffado2 | |
52 | Architecture: linux-any | |
53 | Multi-Arch: same | |
54 | Depends: | |
55 | ${misc:Depends}, | |
56 | ${shlibs:Depends}, | |
57 | Description: FFADO API | |
58 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. | |
59 | . | |
60 | The FFADO library permits discovering and configuring such | |
61 | devices and provides an API for streaming clients. | |
62 | . | |
63 | This package holds the shared library. | |
64 | ||
65 | Package: ffado-tools | |
66 | Section: sound | |
67 | Architecture: linux-any | |
68 | Depends: | |
69 | dbus (>= 1.0.0), | |
70 | libffado2 (= ${binary:Version}), | |
71 | python, | |
72 | ${misc:Depends}, | |
73 | ${shlibs:Depends}, | |
74 | Replaces: | |
75 | ffado-mixer-qt4 (<< 2.0.1+svn1856-2~), | |
76 | libffado2 (<< 2.3.0-3), | |
77 | Breaks: | |
78 | ffado-mixer-qt4 (<< 2.0.1+svn1856-2~), | |
79 | jackd1-firewire (<< 1:0.121.3+20120418git75e3e20b-1), | |
80 | jackd2-firewire (<< 1.9.8~dfsg.3+20120418gitf82ec715-1), | |
81 | libffado2 (<< 2.3.0-3), | |
82 | Description: FFADO debugging and firmware tools | |
83 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. | |
84 | . | |
85 | The FFADO library permits discovering and configuring such | |
86 | devices and provides an API for streaming clients. | |
87 | . | |
88 | This package holds the following tools for firmware updating, | |
89 | troubleshooting and debugging: | |
90 | * ffado-test-streaming | |
91 | * ffado-diag | |
92 | * ffado-test-isoxmit | |
93 | * ffado-test-isorecv | |
94 | * ffado-bridgeco-downloader | |
95 | * ffado-test | |
96 | * ffado-fireworks-downloader | |
97 | * ffado-debug | |
98 | ||
99 | Package: ffado-dbus-server | |
100 | Section: sound | |
101 | Architecture: linux-any | |
102 | Depends: | |
103 | dbus (>= 1.0.0), | |
104 | libffado2 (= ${binary:Version}), | |
105 | ${misc:Depends}, | |
106 | ${shlibs:Depends}, | |
107 | Description: FFADO D-Bus server | |
108 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. | |
109 | . | |
110 | The FFADO library permits discovering and configuring such | |
111 | devices and provides an API for streaming clients. | |
112 | . | |
113 | This package holds the D-Bus server that exposes the mixer | |
114 | and control interfaces through D-Bus. | |
115 | ||
116 | Package: ffado-mixer-qt4 | |
117 | Section: sound | |
118 | Architecture: all | |
119 | Depends: | |
120 | ffado-dbus-server (>= ${source:Version}), | |
121 | ffado-tools (>= ${source:Version}), | |
122 | python, | |
123 | python-dbus, | |
124 | python-qt4, | |
125 | python-qt4-dbus, | |
126 | ${misc:Depends}, | |
127 | ${python:Depends}, | |
128 | ${shlibs:Depends}, | |
129 | Description: FFADO D-Bus mixer applets (QT4) | |
130 | FFADO is a Linux driver for FireWire (IEEE1394) audio devices. | |
131 | . | |
132 | The FFADO library permits discovering and configuring such | |
133 | devices and provides an API for streaming clients. | |
134 | . | |
135 | This package holds the mixer and control applications that | |
136 | communicate with ffado-dbus-server. (Qt4 version) |
0 | This package was debianized by Pieter Palmers <pieter.palmers@ffado.org> on | |
1 | Wed, 29 Oct 2008 21:48:57 +0100. | |
0 | Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ | |
1 | Upstream-Name: libffado | |
2 | Upstream-Contact: http://www.ffado.org/ | |
2 | 3 | |
3 | The current Ubuntu maintainer is the Ubuntu Studio Devel Team | |
4 | <ubuntu-studio-devel@lists.ubuntu.com> | |
4 | Files: * | |
5 | Copyright: 2005-2017 Jonathan Woithe <jwoithe@physics.adelaide.edu.au> | |
6 | 2003-2014 Philippe Carriere | |
7 | 2014-2015 András Murányi | |
8 | 2013 Takashi Sakamoto | |
9 | 2012 Peter Hinkel | |
10 | 2007-2011 Arnold Krille <arnold@arnoldarts.de> | |
11 | 2005-2009 Pieter Palmers <pieter.palmers@ffado.org> | |
12 | 2005-2008 Daniel Wagner <wagi@monom.org> | |
13 | 2015 Hector Martin | |
14 | 2012 Jano Svitok | |
15 | 2004 Kristian Hogsberg, Dan Dennedy, Dan Maas | |
16 | License: GPL-23 | |
5 | 17 | |
6 | It was downloaded from http://www.ffado.org/ | |
18 | Files: admin/config.guess | |
19 | support/mixer-qt4/ffado-mixer.in | |
20 | tests/python/* | |
21 | tests/dbus_test.py | |
22 | Copyright: 2017 Jonathan Woithe <jwoithe@physics.adelaide.edu.au> | |
23 | 1992-2013 Free Software Fundation, Inc. | |
24 | 2013 Per Bothner | |
25 | 2007-2009 Arnold Krille <arnold@arnoldarts.de> | |
26 | 2005-2009 Pieter Palmers <pieter.palmers@ffado.org> | |
27 | License: GPL-3+ | |
7 | 28 | |
8 | Upstream Authors: | |
29 | Files: admin/doxygen.py | |
30 | src/libutil/ringbuffer.c | |
31 | Copyright: 2007-2008 Arnold Krille <arnold@arnoldarts.de> | |
32 | 2005-2006 Matthew A. Nicholson | |
33 | 2006-2006 Tim Blechmann | |
34 | License: GPL-3 | |
35 | Comment: | |
36 | Original authors have graned LGPL-2.1, which allows relicensing to GPL-3+. | |
37 | Arnold Krille grants GPL-2 or GPL-3. | |
38 | We should be safe with GPL-3. | |
9 | 39 | |
10 | Pieter Palmers <pieter.palmers@ffado.org> | |
11 | Daniel Wagner <wagi@monom.org> | |
12 | Jonathan Woithe <jwoithe@physics.adelaide.edu.au> | |
13 | Arnold Krille <arnold@arnoldarts.de> | |
40 | Files: support/tools/* | |
41 | Copyright: 2012 Bent Bisballe Nyeng | |
42 | 2009-2010 Arnold Krille | |
43 | 2005-2008 Peter Palmers | |
44 | 2005-2008 Daniel Wagner | |
45 | License: GPL-3 | |
14 | 46 | |
15 | Copyright: | |
47 | Files: support/alsa/alsa_plugin.cpp | |
48 | src/libutil/float_cast.h | |
49 | Copyright: 2008 Pieter Palmers <pieter.palmers@ffado.org> | |
50 | 2003 Maarten de Boer <mdeboer@iua.upf.es> | |
51 | 2005 Takashi Iwai <tiwai@suse.de> | |
52 | 2001-2004 Erik de Castro Lopo <erikd@mega-nerd.com> | |
53 | 1999-2000 Andreas Bombe | |
54 | License: LGPL-2.1+ | |
16 | 55 | |
17 | <Copyright (C) 2005-2008 Pieter Palmers | |
18 | <Copyright (C) 2005-2008 Daniel Wagner | |
19 | <Copyright (C) 2005-2008 Jonathan Woithe | |
20 | <Copyright (C) 2007-2008 Arnold Krille | |
56 | Files: doc/streaming.xmi | |
57 | Copyright: 2005-2006 Pieter Palmers <pieter.palmers@ffado.org> | |
58 | 2001-2001 Paul Davis | |
59 | 2004-2006 Grame | |
60 | License: GPL-2+ | |
21 | 61 | |
22 | This software contains the following external code: | |
62 | Files: src/libieee1394/csr1212.? | |
63 | Copyright: 2003 Francois Retief <fgretief@sun.ac.za> | |
64 | 2003 Steve Kinneberg <kinnebergsteve@acmsystems.com> | |
65 | License: BSD-3-clause | |
23 | 66 | |
24 | external/dbus - DBUS C++ Bindings | |
25 | Copyright (C) 2005-2007 Paolo Durante <shackan@gmail.com> | |
26 | License for external/dbus: LGPL-2.1 or later (at your option). | |
67 | Files: tests/test-cycle-time.c | |
68 | Copyright: Stefan Richter <stefanr@s5r6.in-berlin.de> | |
69 | License: permissive | |
27 | 70 | |
28 | external/libconfig - A library for processing structured configuration files | |
29 | Copyright (C) 2005-2008 Mark A Lindner | |
30 | License for external/libconfig: LGPL-2.1 or later (at your option). | |
71 | Files: debian/* | |
72 | Copyright: 2018 Benoît Delcour <benoit.delcour@gmail.com> | |
73 | 2018 Nicolas Boulenguez <nicolas@debian.org> | |
74 | 2017-2017 Mattia Rizzolo <mattia@debian.org> | |
75 | 2009-2018 Adrian Knoth <adi@drcomp.erfurt.thur.de> | |
76 | 2010-2016 Jonas Smedegaard <dr@jones.dk> | |
77 | 2014-2014 Sebastian Ramacher <sramacher@debian.org> | |
78 | 2009 Andrew Hunter <andrew@aehunter.net> | |
79 | 2008 Pieter Palmers <pieter.palmers@ffado.org> | |
80 | License: GPL-2+ | |
31 | 81 | |
32 | On Debian systems, the complete text of the GNU Lesser General Public | |
33 | License, version 2.1, can be found in /usr/share/common-licenses/LGPL-2.1. | |
82 | License: BSD-3-clause | |
83 | See /usr/share/common-license/BSD. | |
34 | 84 | |
35 | License: | |
85 | License: GPL-2+ | |
86 | This program is free software; you can redistribute it and/or modify | |
87 | it under the terms of the GNU General Public License as published by | |
88 | the Free Software Foundation; either version 2 of the License, or | |
89 | (at your option) any later version. | |
90 | . | |
91 | On Debian systems, the complete text of the GNU General Public | |
92 | License, version 2, can be found in /usr/share/common-licenses/GPL-2. | |
36 | 93 | |
37 | This program is free software; you can redistribute it and/or modify | |
38 | it under the terms of the GNU General Public License as published by | |
39 | the Free Software Foundation; either version 2 of the License, or | |
40 | (at your option) version 3 of the License. | |
94 | License: GPL-23 | |
95 | This program is free software; you can redistribute it and/or modify | |
96 | it under the terms of the GNU General Public License as published by | |
97 | the Free Software Foundation; either version 2 of the License, or | |
98 | (at your option) version 3 of the License. | |
99 | . | |
100 | On Debian systems, the complete text of the GNU General Public | |
101 | License, version 2, can be found in /usr/share/common-licenses/GPL-2. | |
41 | 102 | |
42 | This program is distributed in the hope that it will be useful, | |
43 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
44 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
45 | GNU General Public License for more details. | |
103 | License: GPL-3 | |
104 | This program is free software; you can redistribute it and/or modify | |
105 | it under the terms of the GNU General Public License as published by | |
106 | the Free Software Foundation; either version 3 of the License. | |
107 | . | |
108 | On Debian systems, the complete text of the GNU General Public | |
109 | License, version 3, can be found in /usr/share/common-licenses/GPL-3. | |
46 | 110 | |
47 | You should have received a copy of the GNU General Public License with | |
48 | the Debian GNU/Linux distribution in file /usr/share/common-licenses/GPL; | |
49 | if not, write to the Free Software Foundation, Inc., 51 Franklin St, | |
50 | Fifth Floor, Boston, MA 02110-1301 USA | |
111 | License: GPL-3+ | |
112 | This program is free software; you can redistribute it and/or modify | |
113 | it under the terms of the GNU General Public License as published by | |
114 | the Free Software Foundation; either version 3 of the License, or | |
115 | (at your option) any later version. | |
116 | . | |
117 | On Debian systems, the complete text of the GNU General Public | |
118 | License, version 3, can be found in /usr/share/common-licenses/GPL-3. | |
51 | 119 | |
52 | On Debian systems, the complete text of the GNU General Public | |
53 | License, version 2, can be found in /usr/share/common-licenses/GPL-2. | |
120 | License: LGPL-2.1+ | |
121 | This library is free software; you can redistribute it and/or modify | |
122 | it under the terms of the GNU Lesser General Public License as | |
123 | published by the Free Software Foundation; either version 2.1 of | |
124 | the License, or (at your option) any later version. | |
125 | . | |
126 | On Debian systems, the complete text of the GNU Lesser General Public | |
127 | License, version 2.1, can be found in /usr/share/common-licenses/LGPL-2.1. | |
54 | 128 | |
55 | On Debian systems, the complete text of the GNU General Public | |
56 | License, version 3, can be found in /usr/share/common-licenses/GPL-3. | |
57 | ||
58 | The Debian packaging is (C) 2008, Pieter Palmers <pieter.palmers@ffado.org> and | |
59 | is licensed under the GPL, see `/usr/share/common-licenses/GPL-2'. | |
129 | License: permissive | |
130 | You may freely use, modify, and/or redistribute this program. |
0 | .TH FFADO-DBUS-SERVER "1" "April 2009" "2.0rc1" | |
1 | .SH NAME | |
2 | \fBffado*\fR \- Free FireWire Audio Drivers | |
3 | .SH SYNOPSYS | |
4 | \fBffado*\fR | |
5 | .SH DESCRIPTION | |
6 | FFADO is work in progress, hence there are no useful manpages. | |
7 | Please refer to \fIhttp://www.ffado.org/\fR for more information. | |
8 | ||
9 | .SH AUTHOR | |
10 | Adrian Knoth | |
11 |
0 | 0 | #!/bin/sh |
1 | 1 | |
2 | export LD_LIBRARY_PATH=/usr/lib/@@MULTIARCH@@/libffado2${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH} | |
2 | export LD_LIBRARY_PATH=@@libdir_dbg@@${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH} | |
3 | 3 | |
4 | 4 | exec "$@" |
0 | .TH FFADO-DEBUG "1" "November 2017" "2.3.0" | |
1 | .SH NAME | |
2 | \fBffado-debug\fR \- Run FFADO in debug mode | |
3 | .SH SYNOPSYS | |
4 | \fBffado-debug command\fR | |
5 | .SH DESCRIPTION | |
6 | ffado-debug is a wrapper-script to make FFADO clients (e.g. jackd) use | |
7 | a debug-enabled version of the library. The script expect this library | |
8 | to reside in | |
9 | .I /usr/lib/<multiarch-triplet>/libffado/ | |
10 | and prefixes | |
11 | .B LD_LIBRARY_PATH | |
12 | accordingly. | |
13 | .SH EXAMPLES | |
14 | ffado-debug jackd -d firewire -v5 | |
15 | .SH AUTHOR | |
16 | Adrian Knoth <adi@drcomp.erfurt.thur.de> | |
17 |
0 | debian/tmp/usr/bin/ffado-mixer | |
1 | debian/tmp/usr/share/ffado-mixer-qt4/ | |
0 | usr/bin/ffado-mixer | |
1 | usr/share/ffado-mixer-qt4/ | |
2 | ||
2 | 3 | support/mixer-qt4/ffado/*.ui usr/share/ffado-mixer-qt4/ffado |
3 | 4 | support/mixer-qt4/ffado/mixer/*.ui usr/share/ffado-mixer-qt4/ffado/mixer |
5 | ||
4 | 6 | support/xdg/ffado.org-ffadomixer.desktop usr/share/applications/ |
7 | support/xdg/hi64-apps-ffado.png usr/share/icons/hicolor/64x64/apps |
0 | .TH FFADO-MIXER "1" "April 2009" "2.0rc1" | |
1 | .SH NAME | |
2 | \fBffado*\fR \- Free FireWire Audio Drivers | |
3 | .SH SYNOPSYS | |
4 | \fBffado*\fR | |
5 | .SH DESCRIPTION | |
6 | FFADO is work in progress, hence there are no useful manpages. | |
7 | Please refer to \fIhttp://www.ffado.org/\fR for more information. | |
8 | ||
9 | .SH AUTHOR | |
10 | Adrian Knoth | |
11 |
0 | .TH FFADO-TOOLS "1" "April 2009" "2.0rc1" | |
1 | .SH NAME | |
2 | \fBffado*\fR \- Free FireWire Audio Drivers | |
3 | .SH SYNOPSYS | |
4 | \fBffado*\fR | |
5 | .SH DESCRIPTION | |
6 | FFADO is work in progress, hence there are no useful manpages. | |
7 | Please refer to \fIhttp://www.ffado.org/\fR for more information. | |
8 | ||
9 | .SH AUTHOR | |
10 | Adrian Knoth | |
11 |
0 | debian/ffado-debug usr/bin/ | |
1 | debian/tmp/usr/bin/ffado-bridgeco-downloader | |
2 | debian/tmp/usr/bin/ffado-diag | |
3 | debian/tmp/usr/bin/ffado-fireworks-downloader | |
4 | debian/tmp/usr/bin/ffado-test | |
5 | debian/tmp/usr/bin/ffado-test-isorecv | |
6 | debian/tmp/usr/bin/ffado-test-isoxmit | |
7 | debian/tmp/usr/bin/ffado-test-streaming | |
8 | debian/tmp/usr/share/libffado2/python/* | |
0 | usr/bin/ffado-bridgeco-downloader | |
1 | usr/bin/ffado-diag | |
2 | usr/bin/ffado-fireworks-downloader | |
3 | usr/bin/ffado-test | |
4 | usr/bin/ffado-test-isorecv | |
5 | usr/bin/ffado-test-isoxmit | |
6 | usr/bin/ffado-test-streaming | |
7 | ||
8 | usr/lib/*/libffado/static_info.txt |
0 | # Probably caused by #204975. | |
1 | # NOSCRIPTS=1 and --no-scripts have been tried unsuccessfully. | |
2 | package-has-unnecessary-activation-of-ldconfig-trigger |
0 | debian/ffado-bridgeco-downloader.1 | |
1 | debian/ffado-diag.1 | |
2 | debian/ffado-fireworks-downloader.1 | |
3 | debian/ffado-test-isorecv.1 | |
4 | debian/ffado-test-isoxmit.1 | |
5 | debian/ffado-test-streaming.1 | |
6 | debian/ffado-test.1 | |
7 | debian/ffado-tools.1 | |
0 | debian/tmp/usr/man/man1/ffado-bridgeco-downloader.1 | |
1 | debian/tmp/usr/man/man1/ffado-diag.1 | |
2 | debian/tmp/usr/man/man1/ffado-fireworks-downloader.1 | |
3 | debian/man/* |
0 | .TH FFADO "1" "April 2009" "2.0rc1" | |
1 | .SH NAME | |
2 | \fBffado*\fR \- Free FireWire Audio Drivers | |
3 | .SH SYNOPSYS | |
4 | \fBffado*\fR | |
5 | .SH DESCRIPTION | |
6 | FFADO is work in progress, hence there are no useful manpages. | |
7 | Please refer to \fIhttp://www.ffado.org/\fR for more information. | |
8 | ||
9 | .SH AUTHOR | |
10 | Adrian Knoth | |
11 |
0 | debian/tmp/usr/lib/*/lib*.so | |
1 | debian/tmp/usr/include/libffado/* | |
2 | debian/tmp/usr/lib/*/pkgconfig/* | |
0 | usr/lib/*/libffado.so | |
1 | usr/include/libffado/* | |
2 | usr/lib/*/pkgconfig/* |
0 | #!/usr/bin/dh-exec | |
1 | debian/tmp/dbg/usr/lib/*/lib*.so.* usr/lib/${DEB_HOST_MULTIARCH}/libffado2/ | |
2 | debian/tmp/lib/udev | |
3 | debian/tmp/usr/lib/*/lib*.so.* | |
4 | debian/tmp/usr/share/libffado2/configuration | |
0 | lib/udev | |
1 | usr/lib/*/libffado.so.* | |
2 | usr/share/libffado2/configuration |
0 | .TH FFADO-DEBUG "1" "November 2017" "2.3.0" | |
1 | .SH NAME | |
2 | \fBffado-debug\fR \- Run FFADO in debug mode | |
3 | .SH SYNOPSIS | |
4 | \fBffado-debug command\fR | |
5 | .SH DESCRIPTION | |
6 | ffado-debug is a wrapper-script to make FFADO clients (e.g. jackd) use | |
7 | a debug-enabled version of the library. The script expect this library | |
8 | to reside in | |
9 | .I /usr/lib/<multiarch-triplet>/libffado/ | |
10 | and prefixes | |
11 | .B LD_LIBRARY_PATH | |
12 | accordingly. | |
13 | .SH EXAMPLES | |
14 | ffado-debug jackd -d firewire -v5 | |
15 | .SH AUTHOR | |
16 | Adrian Knoth <adi@drcomp.erfurt.thur.de> | |
17 |
0 | .so man1/ffado-tools.1 |
0 | .so man1/ffado-tools.1 |
0 | .so man1/ffado-tools.1 |
0 | .so man1/ffado-tools.1 |
0 | .TH FFADO-TOOLS "1" "April 2009" "2.0rc1" | |
1 | .SH NAME | |
2 | \fBffado*\fR \- Free FireWire Audio Drivers | |
3 | .SH SYNOPSIS | |
4 | \fBffado*\fR | |
5 | .SH DESCRIPTION | |
6 | FFADO is work in progress, hence there are no useful manpages. | |
7 | Please refer to \fIhttp://www.ffado.org/\fR for more information. | |
8 | ||
9 | .SH AUTHOR | |
10 | Adrian Knoth | |
11 |
0 | Description: Fix SConstruct import | |
1 | Last-Updated: 2018-02-25 | |
2 | Author: Adrian Knoth <aknoth@google.com> | |
3 | Forwarded: not-needed | |
4 | Applied-upstream: 2.4.1 | |
5 | --- a/SConstruct | |
6 | +++ b/SConstruct | |
7 | @@ -29,6 +29,7 @@ | |
8 | from subprocess import Popen, PIPE | |
9 | import os | |
10 | import re | |
11 | +import sys | |
12 | from string import Template | |
13 | import imp | |
14 | import distutils.sysconfig |
8 | 8 | # |
9 | 9 | |
10 | 10 | include /usr/share/dpkg/architecture.mk |
11 | DEB_BUILD_MAINT_OPTIONS := hardening=+all | |
12 | DEB_CFLAGS_MAINT_APPEND := -fPIC | |
13 | DEB_LDFLAGS_MAINT_APPEND := -Wl,--as-needed | |
14 | include /usr/share/dpkg/buildflags.mk | |
15 | include /usr/share/dpkg/pkg-info.mk | |
11 | 16 | include /usr/share/cdbs/1/rules/debhelper.mk |
12 | 17 | include /usr/share/cdbs/1/rules/utils.mk |
13 | 18 | |
14 | DEB_CLEAN_EXCLUDE=debian/tmp | |
19 | scons := \ | |
20 | $(foreach v,CC CFLAGS CPPFLAGS CXXFLAGS LDFLAGS,$(v)="$($(v))") \ | |
21 | scons \ | |
22 | CUSTOM_ENV=True \ | |
23 | PREFIX=/usr \ | |
24 | DESTDIR=$(DEB_DESTDIR) \ | |
25 | LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH) \ | |
26 | SHAREDIR=/usr/share/libffado2/ \ | |
27 | PYPKGDIR=/usr/share/ffado-mixer-qt4/ \ | |
28 | PYTHON_INTERPRETER=/usr/bin/python3 \ | |
29 | WILL_DEAL_WITH_XDG_MYSELF=1 \ | |
30 | DETECT_USERSPACE_ENV=0 \ | |
31 | $(patsubst parallel=%,-j%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) \ | |
32 | ENABLE_OPTIMIZATION=no | |
33 | common-build-arch common-build-indep:: | |
34 | $(scons) DEBUG=0 | |
35 | common-install-arch common-install-indep:: | |
36 | $(scons) DEBUG=0 install | |
37 | clean:: | |
38 | $(scons) --clean | |
39 | rm -rf cache | |
40 | rm -f .sconsign.dblite | |
41 | find . -name "*.pyc" -delete | |
15 | 42 | |
16 | DEB_PYTHON2_MODULE_PACKAGES := ffado-tools ffado-mixer-qt4 | |
43 | binary-install/ffado-mixer-qt4 binary-install/ffado-tools:: binary-install/%: | |
44 | dh_python3 -p$* | |
17 | 45 | |
18 | ### Add a soname ### | |
46 | # Two versions of the library are built and installed, see #601657. | |
47 | # During architecture-dependent builds, build with debug information | |
48 | # then clean so that the objects are never installed. | |
49 | libdir_dbg := /usr/lib/$(DEB_HOST_MULTIARCH)/libffado2 | |
50 | dbg_so := debian/libffado.so.$(DEB_VERSION_UPSTREAM) | |
19 | 51 | |
20 | DEBIAN_FFADO_COMPATIBLE_VERSION = 2.0 | |
21 | ||
22 | CFLAGS += "-fPIC" | |
23 | ||
24 | ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) | |
25 | NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) | |
26 | NJOBS += -j$(NUMJOBS) | |
27 | endif | |
28 | ||
29 | DEB_SCONS_EXTRA_FLAGS := \ | |
30 | PREFIX=/usr \ | |
31 | LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH) \ | |
32 | SHAREDIR=/usr/share/libffado2/ \ | |
33 | PYPKGDIR=/usr/share/ffado-mixer-qt4/ \ | |
34 | WILL_DEAL_WITH_XDG_MYSELF=1 \ | |
35 | DETECT_USERSPACE_ENV=0 \ | |
36 | $(NJOBS) | |
37 | ||
38 | ||
39 | DEB_SCONS_NOOPT_FLAGS := ENABLE_OPTIMIZATION=no | |
40 | ||
41 | DEB_DH_MAKESHLIBS_ARGS := --version-info="libffado2 (>=${DEBIAN_FFADO_COMPATIBLE_VERSION})" | |
42 | ||
43 | DEB_SCONS_ENVVARS := | |
44 | DEB_SCONS_INVOKE = $(DEB_SCONS_ENVVARS) scons | |
45 | ||
46 | DEB_SCONS_ARGS_COMMON = 'COMPILE_FLAGS=$(CFLAGS)' $(DEB_SCONS_EXTRA_FLAGS) \ | |
47 | $(DEB_SCONS_NOOPT_FLAGS) | |
48 | ||
49 | DEB_SCONS_ARGS_NODBG = $(DEB_SCONS_ARGS_COMMON) DESTDIR=$(DEB_DESTDIR) DEBUG=0 | |
50 | DEB_SCONS_ARGS_DBG = $(DEB_SCONS_ARGS_COMMON) DESTDIR=$(DEB_DESTDIR)/dbg DEBUG=1 | |
51 | ||
52 | #common-build-arch:: debian/stamp-scons-build | |
53 | ### Mangle libffado filename ### | |
54 | debian/stamp-scons-build: | |
55 | -mkdir -p $(DEB_DESTDIR) | |
56 | $(DEB_SCONS_INVOKE) $(DEB_SCONS_ARGS_NODBG) | |
57 | $(DEB_SCONS_INVOKE) $(DEB_SCONS_ARGS_NODBG) install | |
58 | $(DEB_SCONS_INVOKE) $(DEB_SCONS_ARGS_DBG) | |
59 | $(DEB_SCONS_INVOKE) $(DEB_SCONS_ARGS_DBG) install | |
60 | touch debian/stamp-scons-build | |
61 | ||
62 | # this is bad but the only easy way to have ardour.rc generated from | |
63 | # ardour.rc.in | |
64 | common-install-indep:: debian/stamp-scons-build | |
65 | common-install-arch:: debian/stamp-scons-build | |
66 | ||
67 | clean:: scons-clean | |
68 | scons-clean:: | |
69 | $(MAKE) -f debian/rules reverse-config | |
70 | -mkdir -p $(DEB_DESTDIR) | |
71 | -$(DEB_SCONS_INVOKE) --clean | |
72 | -rm -rf $(DEB_DESTDIR) debian/stamp-scons-build | |
73 | -rm -rf config.log scache.conf .sconf_temp .sconsign.dblite cache | |
74 | -rm -rf admin/*.pyc | |
75 | ||
76 | binary-install/ffado-mixer-qt4:: | |
77 | dh_python2 -pffado-mixer-qt4 | |
78 | ||
79 | binary-install/ffado-tools:: | |
80 | sed -i 's/@@MULTIARCH@@/$(DEB_HOST_MULTIARCH)/' debian/ffado-tools/usr/bin/ffado-debug | |
81 | find debian/ffado-tools -type f -name "static_info.txt" -delete | |
82 | dh_python2 -pffado-tools | |
52 | common-build-arch:: $(dbg_so) | |
53 | $(dbg_so): | |
54 | $(scons) DEBUG=1 | |
55 | mv src/libffado.so $(dbg_so) | |
56 | $(scons) --clean | |
57 | binary-install/ffado-tools:: binary-install/%: | |
58 | sed 's|@@libdir_dbg@@|$(libdir_dbg)|' debian/ffado-debug > debian/$*/usr/bin/ffado-debug | |
59 | dh_install -p$* $(dbg_so) $(libdir_dbg) | |
60 | clean:: | |
61 | rm -f $(dbg_so) |
0 | 0 | # Run the "uscan" command to check for upstream updates and more. |
1 | version=3 | |
2 | http://www.ffado.org/ files/libffado-(\d[\d+\.]+)\.tgz | |
1 | ||
2 | version=4 | |
3 | ||
4 | http://www.ffado.org/ \ | |
5 | files/libffado@ANY_VERSION@\.tgz | |
6 | # @ARCHIVE_EXT@ does not match .tgz |
3 | 3 | |
4 | 4 | env = env.Clone() |
5 | 5 | |
6 | # At this point BUILD_DOC is either 'all' or 'user' | |
7 | doxygen_dir_list = [env["top_srcdir"] + "/libffado"] | |
8 | if env["BUILD_DOC"] == 'all': | |
9 | doxygen_dir_list += [env["top_srcdir"] + "/src", | |
10 | env["top_srcdir"] + "/doc"] | |
11 | env["DOXYGEN_INPUT"] = " ".join(doxygen_dir_list) | |
12 | ||
6 | 13 | env.ScanReplace( "reference.doxygen.in" ) |
7 | 14 | |
8 | 15 | env.Doxygen( "reference.doxygen" ) |
9 |
567 | 567 | # directories like "/usr/src/myproject". Separate the files or directories |
568 | 568 | # with spaces. |
569 | 569 | |
570 | INPUT = $top_srcdir/src \ | |
571 | $top_srcdir/doc \ | |
572 | $top_srcdir/libffado | |
570 | INPUT = $DOXYGEN_INPUT | |
573 | 571 | |
574 | 572 | # This tag can be used to specify the character encoding of the source files |
575 | 573 | # that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is |
29 | 29 | libenv.MergeFlags( "-I#/ -I#/src" ) |
30 | 30 | |
31 | 31 | ffado_source = env.Split( '\ |
32 | devicemanager.cpp \ | |
33 | ffado.cpp \ | |
34 | ffadodevice.cpp \ | |
35 | debugmodule/debugmodule.cpp \ | |
36 | DeviceStringParser.cpp \ | |
37 | libieee1394/ARMHandler.cpp \ | |
38 | libieee1394/configrom.cpp \ | |
39 | libieee1394/csr1212.c \ | |
40 | libieee1394/CycleTimerHelper.cpp \ | |
41 | libieee1394/ieee1394service.cpp \ | |
42 | libieee1394/IEC61883.cpp \ | |
43 | libieee1394/IsoHandlerManager.cpp \ | |
44 | libstreaming/StreamProcessorManager.cpp \ | |
45 | libstreaming/util/cip.c \ | |
46 | libstreaming/generic/StreamProcessor.cpp \ | |
47 | libstreaming/generic/Port.cpp \ | |
48 | libstreaming/generic/PortManager.cpp \ | |
49 | libutil/cmd_serialize.cpp \ | |
50 | libutil/DelayLockedLoop.cpp \ | |
51 | libutil/IpcRingBuffer.cpp \ | |
52 | libutil/PacketBuffer.cpp \ | |
53 | libutil/Configuration.cpp \ | |
54 | libutil/OptionContainer.cpp \ | |
55 | libutil/PosixMessageQueue.cpp \ | |
56 | libutil/PosixSharedMemory.cpp \ | |
57 | libutil/PosixMutex.cpp \ | |
58 | libutil/PosixThread.cpp \ | |
59 | libutil/ringbuffer.c \ | |
60 | libutil/StreamStatistics.cpp \ | |
61 | libutil/SystemTimeSource.cpp \ | |
62 | libutil/TimestampedBuffer.cpp \ | |
63 | libutil/Watchdog.cpp \ | |
64 | libcontrol/Element.cpp \ | |
65 | libcontrol/BasicElements.cpp \ | |
66 | libcontrol/MatrixMixer.cpp \ | |
67 | libcontrol/CrossbarRouter.cpp \ | |
68 | libcontrol/ClockSelect.cpp \ | |
69 | libcontrol/Nickname.cpp \ | |
32 | devicemanager.cpp \ | |
33 | ffado.cpp \ | |
34 | ffadodevice.cpp \ | |
35 | debugmodule/debugmodule.cpp \ | |
36 | DeviceStringParser.cpp \ | |
37 | libieee1394/ARMHandler.cpp \ | |
38 | libieee1394/configrom.cpp \ | |
39 | libieee1394/csr1212.c \ | |
40 | libieee1394/CycleTimerHelper.cpp \ | |
41 | libieee1394/ieee1394service.cpp \ | |
42 | libieee1394/IEC61883.cpp \ | |
43 | libieee1394/IsoHandlerManager.cpp \ | |
44 | libstreaming/StreamProcessorManager.cpp \ | |
45 | libstreaming/util/cip.c \ | |
46 | libstreaming/generic/StreamProcessor.cpp \ | |
47 | libstreaming/generic/Port.cpp \ | |
48 | libstreaming/generic/PortManager.cpp \ | |
49 | libutil/cmd_serialize.cpp \ | |
50 | libutil/DelayLockedLoop.cpp \ | |
51 | libutil/IpcRingBuffer.cpp \ | |
52 | libutil/PacketBuffer.cpp \ | |
53 | libutil/Configuration.cpp \ | |
54 | libutil/OptionContainer.cpp \ | |
55 | libutil/PosixMessageQueue.cpp \ | |
56 | libutil/PosixSharedMemory.cpp \ | |
57 | libutil/PosixMutex.cpp \ | |
58 | libutil/PosixThread.cpp \ | |
59 | libutil/ringbuffer.c \ | |
60 | libutil/StreamStatistics.cpp \ | |
61 | libutil/SystemTimeSource.cpp \ | |
62 | libutil/TimestampedBuffer.cpp \ | |
63 | libutil/Watchdog.cpp \ | |
64 | libcontrol/Element.cpp \ | |
65 | libcontrol/BasicElements.cpp \ | |
66 | libcontrol/MatrixMixer.cpp \ | |
67 | libcontrol/CrossbarRouter.cpp \ | |
68 | libcontrol/ClockSelect.cpp \ | |
69 | libcontrol/Nickname.cpp \ | |
70 | 70 | ') |
71 | 71 | |
72 | 72 | if env['SERIALIZE_USE_EXPAT']: |
73 | ffado_source.append('libutil/serialize_expat.cpp') | |
74 | ffado_source.append('libutil/serialize_expat_xml.cpp') | |
73 | ffado_source.append('libutil/serialize_expat.cpp') | |
74 | ffado_source.append('libutil/serialize_expat_xml.cpp') | |
75 | 75 | else: |
76 | ffado_source.append('libutil/serialize_libxml.cpp') | |
76 | ffado_source.append('libutil/serialize_libxml.cpp') | |
77 | 77 | |
78 | 78 | bebob_source = env.Split( '\ |
79 | bebob/bebob_avdevice.cpp \ | |
80 | bebob/bebob_avdevice_subunit.cpp \ | |
81 | bebob/bebob_avplug.cpp \ | |
82 | bebob/bebob_dl_bcd.cpp \ | |
83 | bebob/bebob_dl_codes.cpp \ | |
84 | bebob/bebob_dl_mgr.cpp \ | |
85 | bebob/bebob_functionblock.cpp \ | |
86 | bebob/bebob_mixer.cpp \ | |
87 | bebob/focusrite/focusrite_generic.cpp \ | |
88 | bebob/focusrite/focusrite_saffire.cpp \ | |
89 | bebob/focusrite/focusrite_saffirepro.cpp \ | |
90 | bebob/focusrite/focusrite_cmd.cpp \ | |
91 | bebob/terratec/terratec_device.cpp \ | |
92 | bebob/terratec/terratec_cmd.cpp \ | |
93 | bebob/edirol/edirol_fa101.cpp \ | |
94 | bebob/edirol/edirol_fa66.cpp \ | |
95 | bebob/esi/quatafire610.cpp \ | |
96 | bebob/mackie/onyxmixer.cpp \ | |
97 | bebob/yamaha/yamaha_cmd.cpp \ | |
98 | bebob/yamaha/yamaha_avdevice.cpp \ | |
99 | bebob/maudio/normal_avdevice.cpp \ | |
100 | bebob/maudio/special_avdevice.cpp \ | |
101 | bebob/maudio/special_mixer.cpp \ | |
102 | bebob/presonus/firebox_avdevice.cpp \ | |
103 | bebob/presonus/inspire1394_avdevice.cpp \ | |
79 | bebob/bebob_avdevice.cpp \ | |
80 | bebob/bebob_avdevice_subunit.cpp \ | |
81 | bebob/bebob_avplug.cpp \ | |
82 | bebob/bebob_dl_bcd.cpp \ | |
83 | bebob/bebob_dl_codes.cpp \ | |
84 | bebob/bebob_dl_mgr.cpp \ | |
85 | bebob/bebob_functionblock.cpp \ | |
86 | bebob/bebob_mixer.cpp \ | |
87 | bebob/focusrite/focusrite_generic.cpp \ | |
88 | bebob/focusrite/focusrite_saffire.cpp \ | |
89 | bebob/focusrite/focusrite_saffirepro.cpp \ | |
90 | bebob/focusrite/focusrite_cmd.cpp \ | |
91 | bebob/terratec/terratec_device.cpp \ | |
92 | bebob/terratec/terratec_cmd.cpp \ | |
93 | bebob/edirol/edirol_fa101.cpp \ | |
94 | bebob/edirol/edirol_fa66.cpp \ | |
95 | bebob/esi/quatafire610.cpp \ | |
96 | bebob/mackie/onyxmixer.cpp \ | |
97 | bebob/yamaha/yamaha_cmd.cpp \ | |
98 | bebob/yamaha/yamaha_avdevice.cpp \ | |
99 | bebob/maudio/normal_avdevice.cpp \ | |
100 | bebob/maudio/special_avdevice.cpp \ | |
101 | bebob/maudio/special_mixer.cpp \ | |
102 | bebob/presonus/firebox_avdevice.cpp \ | |
103 | bebob/presonus/inspire1394_avdevice.cpp \ | |
104 | 104 | ' ) |
105 | 105 | |
106 | 106 | bebob_pkgdata = env.Split( '\ |
107 | bebob/maudio/refdesign.xml \ | |
108 | bebob/maudio/fw410.xml \ | |
109 | bebob/maudio/fwap.xml \ | |
107 | bebob/maudio/refdesign.xml \ | |
108 | bebob/maudio/fw410.xml \ | |
109 | bebob/maudio/fwap.xml \ | |
110 | 110 | ' ) |
111 | 111 | |
112 | 112 | genericavc_source = env.Split( '\ |
113 | genericavc/avc_avdevice.cpp \ | |
114 | genericavc/stanton/scs.cpp \ | |
113 | genericavc/avc_avdevice.cpp \ | |
114 | genericavc/stanton/scs.cpp \ | |
115 | 115 | ' ) |
116 | 116 | |
117 | 117 | genericavc_pkgdata = env.Split( '\ |
118 | ' ) | |
118 | ' ) | |
119 | 119 | |
120 | 120 | fireworks_source = env.Split( '\ |
121 | fireworks/fireworks_device.cpp \ | |
122 | fireworks/fireworks_control.cpp \ | |
123 | fireworks/fireworks_firmware.cpp \ | |
124 | fireworks/efc/efc_avc_cmd.cpp \ | |
125 | fireworks/efc/efc_cmd.cpp \ | |
126 | fireworks/efc/efc_cmds_hardware.cpp \ | |
127 | fireworks/efc/efc_cmds_hardware_ctrl.cpp \ | |
128 | fireworks/efc/efc_cmds_flash.cpp \ | |
129 | fireworks/efc/efc_cmds_mixer.cpp \ | |
130 | fireworks/efc/efc_cmds_monitor.cpp \ | |
131 | fireworks/efc/efc_cmds_ioconfig.cpp \ | |
132 | fireworks/fireworks_session_block.cpp \ | |
133 | fireworks/audiofire/audiofire_device.cpp \ | |
121 | fireworks/fireworks_device.cpp \ | |
122 | fireworks/fireworks_control.cpp \ | |
123 | fireworks/fireworks_firmware.cpp \ | |
124 | fireworks/efc/efc_avc_cmd.cpp \ | |
125 | fireworks/efc/efc_cmd.cpp \ | |
126 | fireworks/efc/efc_cmds_hardware.cpp \ | |
127 | fireworks/efc/efc_cmds_hardware_ctrl.cpp \ | |
128 | fireworks/efc/efc_cmds_flash.cpp \ | |
129 | fireworks/efc/efc_cmds_mixer.cpp \ | |
130 | fireworks/efc/efc_cmds_monitor.cpp \ | |
131 | fireworks/efc/efc_cmds_ioconfig.cpp \ | |
132 | fireworks/fireworks_session_block.cpp \ | |
133 | fireworks/audiofire/audiofire_device.cpp \ | |
134 | 134 | ' ) |
135 | 135 | |
136 | 136 | fireworks_pkgdata = env.Split( '\ |
137 | 137 | ' ) |
138 | 138 | |
139 | 139 | oxford_source = env.Split( '\ |
140 | oxford/oxford_device.cpp \ | |
141 | libstreaming/amdtp-oxford/AmdtpOxfordReceiveStreamProcessor.cpp \ | |
140 | oxford/oxford_device.cpp \ | |
141 | libstreaming/amdtp-oxford/AmdtpOxfordReceiveStreamProcessor.cpp \ | |
142 | 142 | ' ) |
143 | 143 | |
144 | 144 | oxford_pkgdata = env.Split( '\ |
145 | ' ) | |
145 | ' ) | |
146 | 146 | |
147 | 147 | motu_source = env.Split( '\ |
148 | motu/motu_avdevice.cpp \ | |
149 | motu/motu_controls.cpp \ | |
150 | motu/motu_mark3_controls.cpp \ | |
151 | motu/motu_mixerdefs.cpp \ | |
152 | motu/motu_mark3_mixerdefs.cpp \ | |
153 | motu/motu_mixer.cpp \ | |
154 | libstreaming/motu/MotuPort.cpp \ | |
155 | libstreaming/motu/MotuPortInfo.cpp \ | |
156 | libstreaming/motu/MotuReceiveStreamProcessor.cpp \ | |
157 | libstreaming/motu/MotuTransmitStreamProcessor.cpp \ | |
148 | motu/motu_avdevice.cpp \ | |
149 | motu/motu_controls.cpp \ | |
150 | motu/motu_mark3_controls.cpp \ | |
151 | motu/motu_mixerdefs.cpp \ | |
152 | motu/motu_mark3_mixerdefs.cpp \ | |
153 | motu/motu_mixer.cpp \ | |
154 | libstreaming/motu/MotuPort.cpp \ | |
155 | libstreaming/motu/MotuPortInfo.cpp \ | |
156 | libstreaming/motu/MotuReceiveStreamProcessor.cpp \ | |
157 | libstreaming/motu/MotuTransmitStreamProcessor.cpp \ | |
158 | 158 | ' ) |
159 | 159 | |
160 | 160 | dice_source = env.Split( '\ |
161 | dice/dice_avdevice.cpp \ | |
162 | dice/dice_firmware_loader.cpp \ | |
163 | dice/dice_eap.cpp \ | |
164 | dice/focusrite/focusrite_eap.cpp \ | |
165 | dice/focusrite/saffire_pro40.cpp \ | |
166 | dice/focusrite/saffire_pro26.cpp \ | |
167 | dice/focusrite/saffire_pro24.cpp \ | |
168 | dice/focusrite/saffire_pro14.cpp \ | |
169 | dice/focusrite/saffire_56.cpp \ | |
170 | dice/maudio/profire_2626.cpp \ | |
171 | dice/presonus/firestudio_tube.cpp \ | |
172 | dice/presonus/firestudio_project.cpp \ | |
173 | dice/presonus/firestudio_mobile.cpp \ | |
161 | dice/dice_avdevice.cpp \ | |
162 | dice/dice_firmware_loader.cpp \ | |
163 | dice/dice_eap.cpp \ | |
164 | dice/focusrite/focusrite_eap.cpp \ | |
165 | dice/focusrite/saffire_pro40.cpp \ | |
166 | dice/focusrite/saffire_pro26.cpp \ | |
167 | dice/focusrite/saffire_pro24.cpp \ | |
168 | dice/focusrite/saffire_pro14.cpp \ | |
169 | dice/focusrite/saffire_56.cpp \ | |
170 | dice/maudio/profire_2626.cpp \ | |
171 | dice/presonus/firestudio_tube.cpp \ | |
172 | dice/presonus/firestudio_project.cpp \ | |
173 | dice/presonus/firestudio_mobile.cpp \ | |
174 | 174 | ' ) |
175 | 175 | |
176 | 176 | bounce_source = env.Split( '\ |
177 | bounce/bounce_avdevice.cpp \ | |
178 | bounce/bounce_slave_avdevice.cpp \ | |
177 | bounce/bounce_avdevice.cpp \ | |
178 | bounce/bounce_slave_avdevice.cpp \ | |
179 | 179 | ' ) |
180 | 180 | |
181 | 181 | metric_halo_source = env.Split( '\ |
182 | metrichalo/mh_avdevice.cpp \ | |
182 | metrichalo/mh_avdevice.cpp \ | |
183 | 183 | ' ) |
184 | 184 | |
185 | 185 | rme_source = env.Split( '\ |
186 | rme/rme_shm.cpp \ | |
187 | rme/rme_avdevice.cpp \ | |
188 | rme/rme_avdevice_settings.cpp \ | |
189 | rme/fireface_flash.cpp \ | |
190 | rme/fireface_hw.cpp \ | |
191 | rme/fireface_settings_ctrls.cpp \ | |
192 | libstreaming/rme/RmePort.cpp \ | |
193 | libstreaming/rme/RmePortInfo.cpp \ | |
194 | libstreaming/rme/RmeReceiveStreamProcessor.cpp \ | |
195 | libstreaming/rme/RmeTransmitStreamProcessor.cpp \ | |
186 | rme/rme_shm.cpp \ | |
187 | rme/rme_avdevice.cpp \ | |
188 | rme/rme_avdevice_settings.cpp \ | |
189 | rme/fireface_flash.cpp \ | |
190 | rme/fireface_hw.cpp \ | |
191 | rme/fireface_settings_ctrls.cpp \ | |
192 | libstreaming/rme/RmePort.cpp \ | |
193 | libstreaming/rme/RmePortInfo.cpp \ | |
194 | libstreaming/rme/RmeReceiveStreamProcessor.cpp \ | |
195 | libstreaming/rme/RmeTransmitStreamProcessor.cpp \ | |
196 | 196 | ' ) |
197 | 197 | |
198 | 198 | digidesign_source = env.Split( '\ |
199 | digidesign/digidesign_avdevice.cpp \ | |
200 | libstreaming/digidesign/DigidesignPort.cpp \ | |
201 | libstreaming/digidesign/DigidesignPortInfo.cpp \ | |
202 | libstreaming/digidesign/DigidesignReceiveStreamProcessor.cpp \ | |
203 | libstreaming/digidesign/DigidesignTransmitStreamProcessor.cpp \ | |
199 | digidesign/digidesign_avdevice.cpp \ | |
200 | libstreaming/digidesign/DigidesignPort.cpp \ | |
201 | libstreaming/digidesign/DigidesignPortInfo.cpp \ | |
202 | libstreaming/digidesign/DigidesignReceiveStreamProcessor.cpp \ | |
203 | libstreaming/digidesign/DigidesignTransmitStreamProcessor.cpp \ | |
204 | 204 | ' ) |
205 | 205 | |
206 | 206 | amdtp_source = env.Split( '\ |
207 | libstreaming/amdtp/AmdtpPort.cpp \ | |
208 | libstreaming/amdtp/AmdtpPortInfo.cpp \ | |
209 | libstreaming/amdtp/AmdtpReceiveStreamProcessor.cpp \ | |
210 | libstreaming/amdtp/AmdtpTransmitStreamProcessor.cpp \ | |
207 | libstreaming/amdtp/AmdtpPort.cpp \ | |
208 | libstreaming/amdtp/AmdtpPortInfo.cpp \ | |
209 | libstreaming/amdtp/AmdtpReceiveStreamProcessor.cpp \ | |
210 | libstreaming/amdtp/AmdtpTransmitStreamProcessor.cpp \ | |
211 | 211 | ' ) |
212 | 212 | |
213 | 213 | libavc_source = env.Split( '\ |
214 | libavc/streamformat/avc_extended_stream_format.cpp \ | |
215 | libavc/musicsubunit/avc_descriptor_music.cpp \ | |
216 | libavc/musicsubunit/avc_musicsubunit.cpp \ | |
217 | libavc/audiosubunit/avc_audiosubunit.cpp \ | |
218 | libavc/audiosubunit/avc_descriptor_audio.cpp \ | |
219 | libavc/audiosubunit/avc_function_block.cpp \ | |
220 | libavc/descriptors/avc_descriptor_cmd.cpp \ | |
221 | libavc/descriptors/avc_descriptor.cpp \ | |
222 | libavc/general/avc_extended_subunit_info.cpp \ | |
223 | libavc/general/avc_unit_info.cpp \ | |
224 | libavc/general/avc_generic.cpp \ | |
225 | libavc/general/avc_subunit_info.cpp \ | |
226 | libavc/general/avc_connect.cpp \ | |
227 | libavc/general/avc_signal_format.cpp \ | |
228 | libavc/general/avc_extended_cmd_generic.cpp \ | |
229 | libavc/general/avc_extended_plug_info.cpp \ | |
230 | libavc/general/avc_plug_info.cpp \ | |
231 | libavc/general/avc_unit.cpp \ | |
232 | libavc/general/avc_subunit.cpp \ | |
233 | libavc/general/avc_plug.cpp \ | |
234 | libavc/general/avc_vendor_dependent_cmd.cpp \ | |
235 | libavc/avc_definitions.cpp \ | |
236 | libavc/ccm/avc_signal_source.cpp \ | |
214 | libavc/streamformat/avc_extended_stream_format.cpp \ | |
215 | libavc/musicsubunit/avc_descriptor_music.cpp \ | |
216 | libavc/musicsubunit/avc_musicsubunit.cpp \ | |
217 | libavc/audiosubunit/avc_audiosubunit.cpp \ | |
218 | libavc/audiosubunit/avc_descriptor_audio.cpp \ | |
219 | libavc/audiosubunit/avc_function_block.cpp \ | |
220 | libavc/descriptors/avc_descriptor_cmd.cpp \ | |
221 | libavc/descriptors/avc_descriptor.cpp \ | |
222 | libavc/general/avc_extended_subunit_info.cpp \ | |
223 | libavc/general/avc_unit_info.cpp \ | |
224 | libavc/general/avc_generic.cpp \ | |
225 | libavc/general/avc_subunit_info.cpp \ | |
226 | libavc/general/avc_connect.cpp \ | |
227 | libavc/general/avc_signal_format.cpp \ | |
228 | libavc/general/avc_extended_cmd_generic.cpp \ | |
229 | libavc/general/avc_extended_plug_info.cpp \ | |
230 | libavc/general/avc_plug_info.cpp \ | |
231 | libavc/general/avc_unit.cpp \ | |
232 | libavc/general/avc_subunit.cpp \ | |
233 | libavc/general/avc_plug.cpp \ | |
234 | libavc/general/avc_vendor_dependent_cmd.cpp \ | |
235 | libavc/avc_definitions.cpp \ | |
236 | libavc/ccm/avc_signal_source.cpp \ | |
237 | 237 | ' ) |
238 | 238 | |
239 | 239 | source = ffado_source |
240 | 240 | pkgdata = [] |
241 | 241 | if env['ENABLE_BEBOB']: |
242 | env['ENABLE_GENERICAVC'] = True | |
243 | libenv.MergeFlags( "-DENABLE_BEBOB" ) | |
244 | source += bebob_source | |
245 | pkgdata += bebob_pkgdata | |
242 | env['ENABLE_GENERICAVC'] = True | |
243 | libenv.MergeFlags( "-DENABLE_BEBOB" ) | |
244 | source += bebob_source | |
245 | pkgdata += bebob_pkgdata | |
246 | 246 | if env['ENABLE_FIREWORKS']: |
247 | env['ENABLE_GENERICAVC'] = True | |
248 | libenv.MergeFlags( "-DENABLE_FIREWORKS" ) | |
249 | source += fireworks_source | |
250 | pkgdata += fireworks_pkgdata | |
247 | env['ENABLE_GENERICAVC'] = True | |
248 | libenv.MergeFlags( "-DENABLE_FIREWORKS" ) | |
249 | source += fireworks_source | |
250 | pkgdata += fireworks_pkgdata | |
251 | 251 | if env['ENABLE_OXFORD']: |
252 | env['ENABLE_GENERICAVC'] = True | |
253 | libenv.MergeFlags( "-DENABLE_OXFORD" ) | |
254 | source += oxford_source | |
255 | pkgdata += oxford_pkgdata | |
252 | env['ENABLE_GENERICAVC'] = True | |
253 | libenv.MergeFlags( "-DENABLE_OXFORD" ) | |
254 | source += oxford_source | |
255 | pkgdata += oxford_pkgdata | |
256 | 256 | if env['ENABLE_MOTU']: |
257 | libenv.MergeFlags( "-DENABLE_MOTU" ) | |
258 | source += motu_source | |
257 | libenv.MergeFlags( "-DENABLE_MOTU" ) | |
258 | source += motu_source | |
259 | 259 | if env['ENABLE_DICE']: |
260 | env['ENABLE_GENERICAVC'] = True | |
261 | libenv.MergeFlags( "-DENABLE_DICE" ) | |
262 | source += dice_source | |
260 | env['ENABLE_GENERICAVC'] = True | |
261 | libenv.MergeFlags( "-DENABLE_DICE" ) | |
262 | source += dice_source | |
263 | 263 | if env['ENABLE_METRIC_HALO']: |
264 | libenv.MergeFlags( "-DENABLE_METRIC_HALO" ) | |
265 | source += metric_halo_source | |
264 | libenv.MergeFlags( "-DENABLE_METRIC_HALO" ) | |
265 | source += metric_halo_source | |
266 | 266 | if env['ENABLE_RME']: |
267 | libenv.MergeFlags( "-DENABLE_RME" ) | |
268 | source += rme_source | |
267 | libenv.MergeFlags( "-DENABLE_RME" ) | |
268 | source += rme_source | |
269 | 269 | if env['ENABLE_DIGIDESIGN']: |
270 | libenv.MergeFlags( "-DENABLE_DIGIDESIGN" ) | |
271 | source += digidesign_source | |
270 | libenv.MergeFlags( "-DENABLE_DIGIDESIGN" ) | |
271 | source += digidesign_source | |
272 | 272 | if env['ENABLE_BOUNCE']: |
273 | env['ENABLE_GENERICAVC'] = True | |
274 | libenv.MergeFlags( "-DENABLE_BOUNCE" ) | |
275 | source += bounce_source | |
273 | env['ENABLE_GENERICAVC'] = True | |
274 | libenv.MergeFlags( "-DENABLE_BOUNCE" ) | |
275 | source += bounce_source | |
276 | 276 | |
277 | 277 | if env['ENABLE_GENERICAVC']: |
278 | libenv.MergeFlags( "-DENABLE_GENERICAVC" ) | |
279 | source += libavc_source | |
280 | source += amdtp_source | |
281 | source += genericavc_source | |
282 | pkgdata += genericavc_pkgdata | |
278 | libenv.MergeFlags( "-DENABLE_GENERICAVC" ) | |
279 | source += libavc_source | |
280 | source += amdtp_source | |
281 | source += genericavc_source | |
282 | pkgdata += genericavc_pkgdata | |
283 | 283 | |
284 | 284 | if not env.GetOption( "clean" ): |
285 | libenv.MergeFlags( "-lrt -lpthread" ) | |
286 | libenv.MergeFlags( env['LIBRAW1394_FLAGS'].decode() ) | |
287 | libenv.MergeFlags( env['LIBIEC61883_FLAGS'].decode() ) | |
288 | libenv.MergeFlags( env['LIBCONFIG_FLAGS'].decode() ) | |
289 | if not env['SERIALIZE_USE_EXPAT']: | |
290 | if 'LIBXML30_FLAGS' in env : | |
291 | libenv.MergeFlags( env['LIBXML30_FLAGS'].decode() ) | |
292 | if not('LIBXML30_FLAGS' in env) : | |
293 | libenv.MergeFlags( env['LIBXML26_FLAGS'].decode() ) | |
294 | else: | |
295 | libenv.PrependUnique( LIBS=["expat"] ) | |
296 | libenv.MergeFlags( "-DSERIALIZE_USE_EXPAT" ) | |
297 | if env['REQUIRE_LIBAVC']: | |
298 | libenv.MergeFlags( env['LIBAVC1394_FLAGS'].decode() ) | |
285 | libenv.MergeFlags( "-lrt -lpthread" ) | |
286 | libenv.MergeFlags( env['LIBRAW1394_FLAGS'].decode() ) | |
287 | libenv.MergeFlags( env['LIBIEC61883_FLAGS'].decode() ) | |
288 | libenv.MergeFlags( env['LIBCONFIG_FLAGS'].decode() ) | |
289 | if not env['SERIALIZE_USE_EXPAT']: | |
290 | if 'LIBXML30_FLAGS' in env : | |
291 | libenv.MergeFlags( env['LIBXML30_FLAGS'].decode() ) | |
292 | if not('LIBXML30_FLAGS' in env) : | |
293 | libenv.MergeFlags( env['LIBXML26_FLAGS'].decode() ) | |
294 | else: | |
295 | libenv.PrependUnique( LIBS=["expat"] ) | |
296 | libenv.MergeFlags( "-DSERIALIZE_USE_EXPAT" ) | |
297 | if env['REQUIRE_LIBAVC']: | |
298 | libenv.MergeFlags( env['LIBAVC1394_FLAGS'].decode() ) | |
299 | 299 | |
300 | 300 | libname_versioned = "libffado.so.%s" % libenv['VERSION'] |
301 | 301 | libname_versioned_short = "libffado.so.%s" % libenv['VERSION'].split('.')[0] |
325 | 325 | # Install the pkgdata to $sharedir |
326 | 326 | # |
327 | 327 | for data in pkgdata: |
328 | libenv.Install( "$sharedir", data ) | |
328 | libenv.Install( "$sharedir", data ) | |
329 | 329 | |
330 | 330 | # |
331 | 331 | # For the debugging apps |
335 | 335 | env2.PrependUnique( LIBS="ffado" ) |
336 | 336 | |
337 | 337 | apps = { \ |
338 | "test-debugmodule" : "debugmodule/test_debugmodule.cpp", \ | |
339 | "test-dll" : "libutil/test-dll.cpp", \ | |
340 | "test-unittests-util" : "libutil/unittests.cpp", \ | |
341 | "test-cyclecalc" : "libieee1394/test-cyclecalc.cpp", \ | |
338 | "test-debugmodule" : "debugmodule/test_debugmodule.cpp", \ | |
339 | "test-dll" : "libutil/test-dll.cpp", \ | |
340 | "test-unittests-util" : "libutil/unittests.cpp", \ | |
341 | "test-cyclecalc" : "libieee1394/test-cyclecalc.cpp", \ | |
342 | 342 | } |
343 | 343 | |
344 | 344 | installapps = [] |
345 | 345 | |
346 | 346 | for app in apps.keys(): |
347 | env2.Program( target=app, source = env.Split( apps[app] ) ) | |
348 | if app.find( "test" ) == -1: | |
349 | env2.Install( "$bindir", app ) | |
350 | ||
347 | env2.Program( target=app, source = env.Split( apps[app] ) ) | |
348 | if app.find( "test" ) == -1: | |
349 | env2.Install( "$bindir", app ) |
538 | 538 | result = false; |
539 | 539 | } |
540 | 540 | } |
541 | printf( "download protocol successfuly completed\n" ); | |
541 | printf( "download protocol successfully completed\n" ); | |
542 | 542 | return result; |
543 | 543 | } |
544 | 544 |
139 | 139 | /** |
140 | 140 | * @brief This is called by the DeviceManager to discover & configure the device |
141 | 141 | * |
142 | * @return true if the device was discovered successfuly | |
142 | * @return true if the device was discovered successfully | |
143 | 143 | */ |
144 | 144 | virtual bool discover() = 0; |
145 | 145 |
772 | 772 | debugOutput(DEBUG_LEVEL_VERBOSE, "saving session\n"); |
773 | 773 | return m_ParentDevice.saveSession(); |
774 | 774 | case eT_Identify: |
775 | debugOutput(DEBUG_LEVEL_VERBOSE, "indentify device\n"); | |
775 | debugOutput(DEBUG_LEVEL_VERBOSE, "identify device\n"); | |
776 | 776 | { |
777 | 777 | EfcIdentifyCmd cmd; |
778 | 778 | if (!m_ParentDevice.doEfcOverAVC(cmd)) |
173 | 173 | } |
174 | 174 | |
175 | 175 | if ( !enumerateSubUnits() ) { |
176 | debugError( "Could not enumarate sub units\n" ); | |
176 | debugError( "Could not enumerate sub units\n" ); | |
177 | 177 | return false; |
178 | 178 | } |
179 | 179 |
614 | 614 | m_sync_delay = max_of_min_delay + signal_delay_ticks; |
615 | 615 | |
616 | 616 | //STEP X: when we implement such a function, we can wait for a signal from the devices that they |
617 | // have aquired lock | |
617 | // have acquired lock | |
618 | 618 | //debugOutput( DEBUG_LEVEL_VERBOSE, "Waiting for device(s) to indicate clock sync lock...\n"); |
619 | 619 | //sleep(2); // FIXME: be smarter here |
620 | 620 |
221 | 221 | { |
222 | 222 | struct sched_param rtparam; |
223 | 223 | int res; |
224 | debugOutput( DEBUG_LEVEL_VERBOSE, "(%s, %p) Aquire realtime, prio %d\n", m_id.c_str(), this, fPriority); | |
224 | debugOutput( DEBUG_LEVEL_VERBOSE, "(%s, %p) Acquire realtime, prio %d\n", m_id.c_str(), this, fPriority); | |
225 | 225 | |
226 | 226 | if (!fThread) |
227 | 227 | return -1; |
294 | 294 | // switch to realtime if necessary |
295 | 295 | if(m_realtime) { |
296 | 296 | if(!m_CheckThread->AcquireRealTime(m_priority)) { |
297 | debugWarning("(%p) Could not aquire realtime priotiry for watchdog thread.\n", this); | |
297 | debugWarning("(%p) Could not acquire realtime priotiry for watchdog thread.\n", this); | |
298 | 298 | } |
299 | 299 | } |
300 | 300 |
607 | 607 | // indicates MIDI control is active while [31] is a submix number. |
608 | 608 | // It's suspected that neither of these are used by the device directly, |
609 | 609 | // and that these elements are just a convenient place for computer |
610 | // control applications to store things. | |
611 | for (out=0; out<30; out++) { | |
610 | // control applications to store things. FFADO does not make use | |
611 | // of these. nch is assumed to be <= RME_FF800_MAX_CHANNELS (28), | |
612 | // the size of the output_faders[] array. | |
613 | for (out=0; out<nch; out++) { | |
612 | 614 | dsettings->output_faders[out] = flashvol2fader(obuf[out]); |
613 | 615 | } |
614 | 616 | |
687 | 689 | // Elements 30 and 31 of obuf[] are not output fader values. See |
688 | 690 | // comments in read_device_mixer_settings(). |
689 | 691 | memset(obuf, 0, sizeof(obuf)); |
690 | for (out=0; out<30; out++) { | |
692 | for (out=0; out<nch; out++) { | |
691 | 693 | obuf[out] = fader2flashvol(dsettings->output_faders[out]); |
692 | 694 | } |
693 | 695 |
41 | 41 | #include <stdint.h> |
42 | 42 | #include <assert.h> |
43 | 43 | #include <unistd.h> |
44 | #include "libutil/ByteSwap.h" | |
45 | 44 | |
46 | 45 | #include <iostream> |
47 | 46 | #include <sstream> |
753 | 752 | // sent to it and the rx stream will fail to start. |
754 | 753 | err = hardware_init_streaming(dev_config->hardware_freq, iso_tx_channel) != 0; |
755 | 754 | if (err) { |
756 | debugFatal("Could not intialise device streaming system\n"); | |
755 | debugFatal("Could not initialise device streaming system\n"); | |
757 | 756 | return false; |
758 | 757 | } |
759 | 758 |
30 | 30 | #include "libavc/avc_definitions.h" |
31 | 31 | |
32 | 32 | #include "libutil/Configuration.h" |
33 | #include "libutil/ByteSwap.h" | |
33 | 34 | |
34 | 35 | #include "fireface_def.h" |
35 | 36 | #include "libstreaming/rme/RmeReceiveStreamProcessor.h" |
0 | #!/usr/bin/python | |
1 | # | |
2 | 0 | # Copyright (C) 2005-2008 by Pieter Palmers |
3 | 1 | # 2007-2009 by Arnold Krille |
4 | 2 | # |
21 | 19 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
22 | 20 | # |
23 | 21 | |
22 | import ctypes | |
23 | import datetime | |
24 | 24 | import os |
25 | 25 | |
26 | 26 | from ffado.config import * |
91 | 91 | self.menuTheme[theme].setCheckable(True) |
92 | 92 | |
93 | 93 | if (ffado_python3 and (self.style().objectName().lower() == theme.lower()) or |
94 | not(ffado_python3) and (self.style().objectName().toLower() == theme.toLower())): | |
94 | not(ffado_python3) and (self.style().objectName().toLower() == theme.toLower() if ffado_pyqt_version == 4 else | |
95 | self.style().objectName().lower() == theme.lower())): | |
95 | 96 | self.menuTheme[theme].setDisabled(True) |
96 | 97 | self.menuTheme[theme].setChecked(True) |
97 | 98 | self.menuTheme[theme].triggered.connect(self.switchTheme ) |
173 | 174 | QMessageBox.about( self, "About FFADO", """ |
174 | 175 | <h1>ffado.org</h1> |
175 | 176 | |
177 | <p>{ffado_version}</p> | |
178 | ||
176 | 179 | <p>FFADO is the new approach to have firewire audio on linux.</p> |
177 | 180 | |
178 | <p>© 2006-2014 by the FFADO developers<br />ffado is licensed under the GPLv3, for the full license text see <a href="http://www.gnu.org/licenses/">www.gnu.org/licenses</a> or the LICENSE.* files shipped with ffado.</p> | |
181 | <p>© 2006-2018 by the FFADO developers<br />ffado is licensed under the GPLv3, for the full license text see <a href="http://www.gnu.org/licenses/">www.gnu.org/licenses</a> or the LICENSE.* files shipped with ffado.</p> | |
179 | 182 | |
180 | 183 | <p>FFADO developers are:<ul> |
181 | 184 | <li>Pieter Palmers |
190 | 193 | <li>Stefan Richter |
191 | 194 | <li>Jano Svitok |
192 | 195 | </ul> |
193 | """ ) | |
194 | ||
196 | """.format(ffado_version=get_ffado_version(), thisyear=datetime.datetime.now().year)) | |
197 | ||
198 | def get_ffado_version(): | |
199 | try: | |
200 | # call the C function ffado_get_version() to figure out the version | |
201 | lib = ctypes.cdll.LoadLibrary('libffado.so') | |
202 | func = ctypes.CFUNCTYPE(ctypes.c_char_p) | |
203 | ffado_get_version = func(('ffado_get_version', lib)) | |
204 | return ffado_get_version() | |
205 | except: | |
206 | return "libffado" | |
195 | 207 | |
196 | 208 | def get_lock(process_name): |
197 | 209 | import socket |
251 | 263 | logging.getLogger('global').setLevel(debug_level) |
252 | 264 | |
253 | 265 | log = logging.getLogger('main') |
266 | log.debug("Using %s with Qt: %s PyQt: %s" % (get_ffado_version(), QtCore.QT_VERSION_STR, QtCore.PYQT_VERSION_STR)) | |
254 | 267 | |
255 | 268 | app = QApplication(args) |
256 | 269 | app.setWindowIcon( QIcon( SHAREDIR + "/icons/hi64-apps-ffado.png" ) ) |
27 | 27 | log = logging.getLogger('logginghandler') |
28 | 28 | |
29 | 29 | class QStatusLogger( QObject, logging.Handler ): |
30 | log = pyqtSignal(QString, int, name='log') | |
30 | log = pyqtSignal(QString if ffado_pyqt_version == 4 else str, int, name='log') | |
31 | 31 | def __init__( self, parent, statusbar, level=logging.NOTSET ): |
32 | 32 | QObject.__init__( self, parent ) |
33 | 33 | logging.Handler.__init__( self, level ) |
142 | 142 | def updateDigIfaceControl(self, a0): |
143 | 143 | sender = self.sender() |
144 | 144 | state = a0 |
145 | # 0/2/3 is available but GUI set 0/1/2 | |
145 | # 0/2/3 is available but GUI set 0/1/2 | |
146 | 146 | if a0 > 0: |
147 | 147 | state += 1 |
148 | 148 | log.debug("set %s to %d" % ( |
149 | 149 | self.DigIfaceControls[sender][0], state)) |
150 | self.hw.setDiscrete(self.DigIfaceControls[sender][0], state) | |
150 | self.hw.setDiscrete(self.DigIfaceControls[sender][0], state) | |
151 | 151 | |
152 | 152 | def updatePlbkRouteControl(self, src): |
153 | 153 | sender = self.sender() |
80 | 80 | self.muteButtonWavePlayR: [self.sldInputWavePlayR, self.muteButtonWavePlayL] |
81 | 81 | } |
82 | 82 | |
83 | # gain control | |
84 | for ctl, params in self.VolumeControls.items(): | |
85 | path = params[0] | |
86 | idx = params[1] | |
83 | # gain control | |
84 | for ctl, params in self.VolumeControls.items(): | |
85 | path = params[0] | |
86 | idx = params[1] | |
87 | 87 | dbmeter = params[5] |
88 | ||
89 | #db = self.hw.getContignuous(path, idx) | |
90 | #vol = self.db2vol(db) | |
88 | ||
89 | #db = self.hw.getContignuous(path, idx) | |
90 | #vol = self.db2vol(db) | |
91 | 91 | vol = self.hw.getContignuous(path, idx) |
92 | 92 | print("%s ch %d volume is %d" % (path, idx, vol)) |
93 | 93 | ctl.setValue(vol) |
94 | 94 | dbmeter.setText(self.vol2dbstr(vol)) |
95 | 95 | self.VolumeControls[ctl][6] = vol |
96 | ||
97 | pair = params[2] | |
98 | pidx = params[3] | |
99 | link = params[4] | |
100 | ||
101 | # pdb = self.hw.getContignuous(path, pidx) | |
102 | # pvol = self.db2vol(db) | |
103 | pvol = self.hw.getContignuous(path, pidx) | |
96 | ||
97 | pair = params[2] | |
98 | pidx = params[3] | |
99 | link = params[4] | |
100 | ||
101 | # pdb = self.hw.getContignuous(path, pidx) | |
102 | # pvol = self.db2vol(db) | |
103 | pvol = self.hw.getContignuous(path, pidx) | |
104 | 104 | |
105 | if pvol == vol: | |
106 | link.setChecked(True) | |
107 | ||
105 | if pvol == vol: | |
106 | link.setChecked(True) | |
107 | ||
108 | 108 | ctl.valueChanged.connect(self.updateVolume) |
109 | 109 | |
110 | # selector controls | |
111 | for ctl, param in self.SelectorControls.items(): | |
112 | state = self.hw.getDiscrete(param) | |
113 | ctl.setCurrentIndex(state) | |
114 | ||
110 | # selector controls | |
111 | for ctl, param in self.SelectorControls.items(): | |
112 | state = self.hw.getDiscrete(param) | |
113 | ctl.setCurrentIndex(state) | |
114 | ||
115 | 115 | ctl.activated.connect(self.updateSelector) |
116 | 116 | |
117 | # mute controls | |
118 | for ctl, param in self.MuteControls.items(): | |
117 | # mute controls | |
118 | for ctl, param in self.MuteControls.items(): | |
119 | 119 | ctl.toggled.connect(self.muteVolume) |
120 | 120 | |
121 | 121 | |
122 | 122 | # helper functions |
123 | 123 | def muteVolume(self, state): |
124 | sender = self.sender() | |
124 | sender = self.sender() | |
125 | 125 | volctl = self.MuteControls[sender][0] |
126 | path = self.VolumeControls[volctl][0] | |
127 | idx = self.VolumeControls[volctl][1] | |
128 | pair = self.VolumeControls[volctl][2] | |
129 | pidx = self.VolumeControls[volctl][3] | |
130 | link = self.VolumeControls[volctl][4] | |
126 | path = self.VolumeControls[volctl][0] | |
127 | idx = self.VolumeControls[volctl][1] | |
128 | pair = self.VolumeControls[volctl][2] | |
129 | pidx = self.VolumeControls[volctl][3] | |
130 | link = self.VolumeControls[volctl][4] | |
131 | 131 | savedvol = self.VolumeControls[volctl][6] |
132 | 132 | psavedvol = self.VolumeControls[pair][6] |
133 | 133 | |
145 | 145 | # self.hw.setContignuous(path, psavedvol, pidx) |
146 | 146 | |
147 | 147 | def updateVolume(self, vol): |
148 | sender = self.sender() | |
149 | path = self.VolumeControls[sender][0] | |
150 | idx = self.VolumeControls[sender][1] | |
151 | pair = self.VolumeControls[sender][2] | |
152 | pidx = self.VolumeControls[sender][3] | |
153 | link = self.VolumeControls[sender][4] | |
148 | sender = self.sender() | |
149 | path = self.VolumeControls[sender][0] | |
150 | idx = self.VolumeControls[sender][1] | |
151 | pair = self.VolumeControls[sender][2] | |
152 | pidx = self.VolumeControls[sender][3] | |
153 | link = self.VolumeControls[sender][4] | |
154 | 154 | dbmeter = self.VolumeControls[sender][5] |
155 | 155 | |
156 | 156 | #db = self.vol2dbstr(vol) |
163 | 163 | pair.setValue(vol) |
164 | 164 | |
165 | 165 | def updateSelector(self, state): |
166 | sender = self.sender() | |
167 | path = self.SelectorControls[sender] | |
166 | sender = self.sender() | |
167 | path = self.SelectorControls[sender] | |
168 | 168 | self.hw.setDiscrete(path, state) |
169 | 169 | # if path == '/Mixer/Selector_7' |
170 | 170 | # ctrl = self.VolumeControls['line78'] |
174 | 174 | # ctrl[1].setValue(-vol) |
175 | 175 | |
176 | 176 | def vol2dbstr(self, vol): |
177 | vol = vol + 25600 | |
177 | vol = vol + 25600 | |
178 | 178 | if vol == 0 : |
179 | 179 | return "- "+u"\u221E"+" dB" |
180 | 180 | return str("{0:.2f}".format(log10( float(abs(vol) + 0.001) / 25600 ) * 20))+"dB" |
37 | 37 | |
38 | 38 | import sys |
39 | 39 | import time |
40 | import importlib | |
40 | 41 | |
41 | 42 | import logging |
42 | 43 | log = logging.getLogger('panelmanager') |
301 | 302 | # |
302 | 303 | # Specific (or dummy) mixer widgets get loaded in the following |
303 | 304 | # |
305 | found = False | |
304 | 306 | if 'mixer' in dev and dev['mixer'] != None: |
305 | 307 | mixerapp = dev['mixer'] |
306 | global mixerwidget | |
307 | exec( """ | |
308 | try: | |
309 | import ffado.mixer.%s | |
310 | globals()["mixerwidget"] = ffado.mixer.%s.%s( w ) | |
311 | found = True | |
312 | except ImportError: | |
313 | log.debug("bypassdbus set, %s module not available: ignored") | |
314 | found = False | |
315 | """ % (mixerapp.lower(), mixerapp.lower(), mixerapp, mixerapp.lower()) ) | |
316 | else: | |
317 | found = False | |
308 | try: | |
309 | mixer_module = importlib.import_module("ffado.mixer.%s" % mixerapp.lower()) | |
310 | mixerwidget = getattr(mixer_module, mixerapp)(w) | |
311 | found = True | |
312 | except ImportError: | |
313 | log.debug("bypassdbus set, %s module not available: ignored" % mixerapp.lower()) | |
318 | 314 | |
319 | 315 | if not found: |
320 | 316 | mixerwidget = Dummy( w ) |
377 | 373 | action = self.sender() |
378 | 374 | # Extract the action data and store as a dbus.String type so |
379 | 375 | # it is usable as a key into self.panels[]. |
380 | panel_key = dbus.String(action.data().toString()) | |
376 | panel_key = dbus.String(action.data().toString() if ffado_pyqt_version == 4 else action.data()) | |
381 | 377 | self.tabs.setCurrentIndex(self.tabs.indexOf(self.panels[panel_key])) |
382 | 378 | |
383 | 379 | def displayPanels(self): |
514 | 510 | saveString.append('</device>\n') |
515 | 511 | # file saving |
516 | 512 | savefilename = QFileDialog.getSaveFileName(self, 'Save File', os.getenv('HOME')) |
513 | if isinstance(savefilename, tuple): # newer PyQt5 | |
514 | savefilename = savefilename[0] | |
517 | 515 | try: |
518 | 516 | f = open(savefilename, 'w') |
519 | 517 | except IOError: |
525 | 523 | |
526 | 524 | def readSettings(self): |
527 | 525 | readfilename = QFileDialog.getOpenFileName(self, 'Open File', os.getenv('HOME')) |
526 | if isinstance(readfilename, tuple): # newer PyQt5 | |
527 | readfilename = readfilename[0] | |
528 | 528 | try: |
529 | 529 | f = open(readfilename, 'r') |
530 | 530 | except IOError: |
97 | 97 | self.combo.setCurrentIndex(self.combo.findText(src)) |
98 | 98 | else: |
99 | 99 | self.combo.setCurrentIndex(0) |
100 | self.combo.activated.connect(self.comboCurrentChanged) | |
100 | self.combo.activated[str].connect(self.comboCurrentChanged) | |
101 | 101 | |
102 | 102 | |
103 | 103 | def peakValue(self, value): |
167 | 167 | self.timer.setInterval(200) |
168 | 168 | self.timer.timeout.connect(self.updateLevels) |
169 | 169 | |
170 | self.vubtn.setChecked(self.settings.value("crossbarrouter/runvu", False).toBool()) | |
170 | if ffado_pyqt_version == 4: | |
171 | self.vubtn.setChecked(self.settings.value("crossbarrouter/runvu", False).toBool()) | |
172 | else: | |
173 | self.vubtn.setChecked(self.settings.value("crossbarrouter/runvu", False) == u'true') | |
171 | 174 | |
172 | 175 | def __del__(self): |
173 | 176 | print( "CrossbarRouter.__del__()" ) |
190 | 193 | #log.debug("Got %i peaks" % len(peakvalues)) |
191 | 194 | for peak in peakvalues: |
192 | 195 | #log.debug("peak = [%s,%s]" % (str(peak[0]),str(peak[1]))) |
193 | if peak[0] >= 0: | |
196 | if peak[1] >= 0: | |
194 | 197 | self.switchers[peak[0]].peakValue(peak[1]) |
195 | 198 | |
196 | 199 | def updateMixerRouting(self): |
199 | 199 | |
200 | 200 | def mousePressEvent(self, ev): |
201 | 201 | if ev.buttons() & Qt.LeftButton: |
202 | self.pos = ev.posF() | |
202 | self.pos = ev.posF() if ffado_pyqt_version == 4 else ev.localPos() | |
203 | 203 | self.tmpvalue = self.value() |
204 | 204 | ev.accept() |
205 | 205 | #log.debug("MixerNode.mousePressEvent() %s" % str(self.pos)) |
206 | 206 | |
207 | 207 | def mouseMoveEvent(self, ev): |
208 | 208 | if hasattr(self, "tmpvalue") and self.pos is not QtCore.QPointF(0, 0): |
209 | newpos = ev.posF() | |
209 | newpos = ev.posF() if ffado_pyqt_version == 4 else ev.localPos() | |
210 | 210 | change = newpos.y() - self.pos.y() |
211 | 211 | #log.debug("MixerNode.mouseReleaseEvent() change %s" % (str(change))) |
212 | 212 | self.setValue( self.tmpvalue - math.copysign(pow(abs(change), 2), change) ) |
214 | 214 | |
215 | 215 | def mouseReleaseEvent(self, ev): |
216 | 216 | if hasattr(self, "tmpvalue") and self.pos is not QtCore.QPointF(0, 0): |
217 | newpos = ev.posF() | |
217 | newpos = ev.posF() if ffado_pyqt_version == 4 else ev.localPos() | |
218 | 218 | change = newpos.y() - self.pos.y() |
219 | 219 | #log.debug("MixerNode.mouseReleaseEvent() change %s" % (str(change))) |
220 | 220 | self.setValue( self.tmpvalue - math.copysign(pow(abs(change), 2), change) ) |
256 | 256 | if v == 0: |
257 | 257 | symb_inf = u"\u221E" |
258 | 258 | text = "-" + symb_inf + " dB" |
259 | if ffado_python3: | |
259 | if ffado_python3 or ffado_pyqt_version == 5: | |
260 | 260 | # Python3 uses native python UTF strings rather than QString. |
261 | 261 | # This therefore appears to be the correct way to display this |
262 | 262 | # UTF8 string, but testing may prove otherwise. |
263 | 263 | p.drawText(rect, Qt.AlignCenter, text) |
264 | 264 | else: |
265 | p.drawText(rect, Qt.AlignCenter, QtCore.QString.fromUtf8(text)) | |
265 | p.drawText(rect, Qt.AlignCenter, QString.fromUtf8(text)) | |
266 | 266 | if (self.inv_action!=None and self.inv_action.isChecked()): |
267 | if ffado_python3: | |
267 | if ffado_python3 or ffado_pyqt_version == 5: | |
268 | 268 | # Refer to the comment about about Python UTF8 strings. |
269 | 269 | p.drawText(rect, Qt.AlignLeft|Qt.AlignTop, " Ï•") |
270 | 270 | else: |
271 | p.drawText(rect, Qt.AlignLeft|Qt.AlignTop, QtCore.QString.fromUtf8(" Ï•")) | |
271 | p.drawText(rect, Qt.AlignLeft|Qt.AlignTop, QString.fromUtf8(" Ï•")) | |
272 | 272 | |
273 | 273 | def internalValueChanged(self, value): |
274 | 274 | #log.debug("MixerNode.internalValueChanged( %i )" % value) |
511 | 511 | self.rowHeaders[j].lbl.setText(row_name) |
512 | 512 | |
513 | 513 | def updateValues(self, n): |
514 | nbitems = len(n)/3 | |
514 | nbitems = len(n) // 3 | |
515 | 515 | for i in range(nbitems): |
516 | 516 | n_0 = n[3*i] |
517 | 517 | n_1 = n[3*i+1] |
950 | 950 | return self.interface.setValue(In, Out, val) |
951 | 951 | |
952 | 952 | def updateValues(self, n): |
953 | nbitems = len(n)/3 | |
953 | nbitems = len(n) // 3 | |
954 | 954 | for j in range(nbitems): |
955 | 955 | n_0 = n[3*j] |
956 | 956 | n_1 = n[3*j+1] |
1405 | 1405 | def matrixControlChanged(self, n): |
1406 | 1406 | # Update value needed for "per Out" view |
1407 | 1407 | #log.debug("Update per Output( %s )" % str(n)) |
1408 | nbitems = len(n)/3 | |
1408 | nbitems = len(n) // 3 | |
1409 | 1409 | if (self.rule == "Columns_are_inputs"): |
1410 | 1410 | n_t = n |
1411 | 1411 | else: |
1419 | 1419 | def sliderControlChanged(self, n): |
1420 | 1420 | # Update value needed for matrix view |
1421 | 1421 | #log.debug("Update Matrix( %s )" % str(n)) |
1422 | nbitems = len(n)/3 | |
1422 | nbitems = len(n) // 3 | |
1423 | 1423 | if (((self.rule == "Columns_are_inputs") and not self.transpose) or ((self.rule != "Columns_are_inputs") and self.transpose)): |
1424 | 1424 | n_t = () |
1425 | 1425 | for i in range(nbitems): |
1511 | 1511 | log.debug("Number of stereo output channels must be specified") |
1512 | 1512 | return False |
1513 | 1513 | n = int(readMixerString[idx+2]) |
1514 | if n > self.perOut.nbOut/2: | |
1514 | if n > self.perOut.nbOut // 2: | |
1515 | 1515 | log.debug("Incoherent number of stereo channels") |
1516 | 1516 | return False |
1517 | 1517 | if n > 0: |
0 | #!/usr/bin/python | |
0 | #!$PYTHON_INTERPRETER | |
1 | 1 | # |
2 | 2 | # Copyright (C) 2005-2008 by Pieter Palmers |
3 | 3 | # 2007-2009 by Arnold Krille |
31 | 31 | # Needed to build ffado-set-nickname |
32 | 32 | e.MergeFlags( "-I#/ -I#/src -L%ssrc -lffado" % env['build_base'] ) |
33 | 33 | if not e.GetOption( "clean" ): |
34 | if not env['SERIALIZE_USE_EXPAT']: | |
35 | if 'LIBXML30_FLAGS' in env : | |
36 | e.MergeFlags( env['LIBXML30_FLAGS'].decode() ) | |
37 | if not('LIBXML30_FLAGS' in env) : | |
38 | e.MergeFlags( env['LIBXML26_FLAGS'].decode() ) | |
39 | else: | |
40 | e.PrependUnique( LIBS=["expat"] ) | |
34 | if not env['SERIALIZE_USE_EXPAT']: | |
35 | if 'LIBXML30_FLAGS' in env : | |
36 | e.MergeFlags( env['LIBXML30_FLAGS'].decode() ) | |
37 | if not('LIBXML30_FLAGS' in env) : | |
38 | e.MergeFlags( env['LIBXML26_FLAGS'].decode() ) | |
39 | else: | |
40 | e.PrependUnique( LIBS=["expat"] ) | |
41 | 41 | |
42 | # | |
43 | # For the the ffado-diag tools | |
44 | e['PYTHONDIR'] = Template( os.path.join( e['SHAREDIR'], 'python' ) ).safe_substitute( e ) | |
45 | # For the installation of the stuff | |
46 | e['pythondir'] = Template( os.path.join( e['sharedir'], 'python' ) ).safe_substitute( e ) | |
47 | ||
48 | e.Command( "static_info.txt", "#/SConstruct", "python support/tools/ffado-diag-static > $TARGET" ) | |
42 | e.Command( "static_info.txt", "ffado-diag", "support/tools/ffado-diag --static > $TARGET" ) | |
49 | 43 | |
50 | 44 | e.ScanReplace( "ffado-diag.in" ) |
51 | 45 | |
52 | 46 | e.Install( "$bindir", "ffado-diag" ) |
53 | e.Install( "$pythondir", "helpstrings.py" ) | |
54 | e.Install( "$pythondir", "listirqinfo.py" ) | |
55 | e.Install( "$pythondir", "static_info.txt" ) | |
56 | e.Install( "$pythondir", "ffado_diag_helpers.py" ) | |
47 | e.Install( "$libdatadir", "static_info.txt" ) | |
57 | 48 | |
58 | 49 | if env['ENABLE_DICE']: |
59 | e.Program( target = "ffado-set-nickname", source = "ffado-set-nickname.cpp" ) | |
60 | e.Install( "$bindir", "ffado-set-nickname" ) | |
50 | e.Program( target = "ffado-set-nickname", source = "ffado-set-nickname.cpp" ) | |
51 | e.Install( "$bindir", "ffado-set-nickname" ) | |
61 | 52 | |
62 | 53 | # Install manpages in section 1 |
63 | 54 | dest = os.path.join("$mandir", "man1", "ffado-diag.1") |
0 | #!/usr/bin/python | |
1 | # | |
2 | ||
3 | # | |
4 | # Copyright (C) 2008 Pieter Palmers | |
5 | # 2009 Arnold Krilles | |
6 | # | |
7 | # This program is free software: you can redistribute it and/or modify | |
8 | # it under the terms of the GNU General Public License as published by | |
9 | # the Free Software Foundation, version 3 of the License. | |
10 | # | |
11 | # This program is distributed in the hope that it will be useful, | |
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 | # GNU General Public License for more details. | |
15 | # | |
16 | # You should have received a copy of the GNU General Public License | |
17 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
18 | # | |
19 | ||
20 | # | |
21 | # Test for common FFADO problems | |
22 | # | |
23 | ||
24 | import sys | |
25 | ||
26 | # Add the path of the installed dependent files | |
27 | import os | |
28 | import commands | |
29 | import re | |
30 | import logging | |
31 | ||
32 | from ffado_diag_helpers import * | |
33 | ||
34 | welcome_msg = """ | |
35 | ||
36 | FFADO static diagnostic utility | |
37 | ============================ | |
38 | (C) 2008 Pieter Palmers | |
39 | (C) 2009 Arnold Krille | |
40 | ||
41 | """ | |
42 | ||
43 | help_msg = """ | |
44 | Usage: ffado-diag [verboselevel] | |
45 | ||
46 | verboselevel : verbosity level. (optional) | |
47 | ||
48 | """ | |
49 | ||
50 | ## logging setup | |
51 | logging.basicConfig() | |
52 | log = logging.getLogger('staticdiag') | |
53 | ||
54 | ## main program | |
55 | if __name__== '__main__': | |
56 | ||
57 | print welcome_msg | |
58 | ||
59 | num_args = len(sys.argv) | |
60 | if num_args not in [1,2]: | |
61 | print help | |
62 | sys.exit(0) | |
63 | ||
64 | if num_args == 2: | |
65 | loglevel = eval(sys.argv[1]) | |
66 | if loglevel == 1: | |
67 | logging.getLogger('staticdiag').setLevel(logging.INFO) | |
68 | elif loglevel == 2: | |
69 | logging.getLogger('staticdiag').setLevel(logging.DEBUG) | |
70 | ||
71 | print "=== CHECK ===" | |
72 | ||
73 | # check libraries | |
74 | print " gcc ............... %s" % get_version_first_line('gcc --version') | |
75 | print " g++ ............... %s" % get_version_first_line('g++ --version') | |
76 | print " PyQt4 (by pyuic4) . %s" % get_version_first_line('pyuic4 --version') | |
77 | print " PyQt5 (by pyuic5) . %s" % get_version_first_line('pyuic5 --version') | |
78 | print " jackd ............. %s" % get_version_first_line('jackd --version') | |
79 | print " path ............ %s" % get_command_path('jackd') | |
80 | print " flags ........... %s" % get_package_flags("jack") | |
81 | print " libraw1394 ........ %s" % get_package_version("libraw1394") | |
82 | print " flags ........... %s" % get_package_flags("libraw1394") | |
83 | print " libavc1394 ........ %s" % get_package_version("libavc1394") | |
84 | print " flags ........... %s" % get_package_flags("libavc1394") | |
85 | print " libiec61883 ....... %s" % get_package_version("libiec61883") | |
86 | print " flags ........... %s" % get_package_flags("libiec61883") | |
87 | print " libxml++-2.6 ...... %s" % get_package_version("libxml++-2.6") | |
88 | print " flags ........... %s" % get_package_flags("libxml++-2.6") | |
89 | print " dbus-1 ............ %s" % get_package_version("dbus-1") | |
90 | print " flags ........... %s" % get_package_flags("dbus-1") | |
91 |
0 | .TH FFADO-DIAG 1 27-Mar-2012 "ffado-diag" | |
0 | .TH FFADO\-DIAG 1 27\-Mar\-2012 "ffado\-diag" | |
1 | 1 | .SH NAME |
2 | ffado-diag \- print system diagnostic information related to FFADO. | |
2 | ffado\-diag \- print system diagnostic information related to FFADO. | |
3 | \" | |
3 | 4 | .SH SYNOPSIS |
4 | .BI "ffado-diag" | |
5 | .sp | |
5 | .BR ffado\-diag [\| \-\-static \||\| \-V \||\| \-\-version \||\| \-\-usage \|] | |
6 | \" | |
6 | 7 | .SH DESCRIPTION |
7 | .B ffado-diag | |
8 | .B ffado\-diag | |
8 | 9 | prints out an extensive collection of diagnostic information about the |
9 | 10 | computer it is run on. Information included is the FFADO version number, |
10 | 11 | the version number of libraries which FFADO depends on, the firewire |
11 | 12 | interface card, interrupt usage, and so on. This is useful for developers |
12 | 13 | to know when giving support via the FFADO mailing lists. For anything other |
13 | than trivial issues, the output of | |
14 | .B | |
15 | ffado-diag | |
14 | than trivial issues, the output of | |
15 | .B ffado\-diag | |
16 | 16 | will be one of the first things asked fro when debugging a problem. |
17 | .SH "OPTIONS" | |
18 | .B | |
19 | ffado-diag | |
20 | does not presently have any command line options. | |
17 | \" | |
18 | .SH OPTIONS | |
19 | .BR \-V ", " \-\-version | |
20 | Display version information. | |
21 | .B \-\-usage | |
22 | Print a short usage message and exit. | |
23 | .B \-\-static | |
24 | Only display executable paths and libraries. |
0 | #!/usr/bin/python | |
1 | # | |
2 | ||
3 | # | |
4 | # Copyright (C) 2008 Pieter Palmers | |
5 | # 2009-2010 Arnold Krille | |
6 | # | |
0 | #!$PYTHON_INTERPRETER | |
1 | # Dollar variables are preprocessed by SConscript at build time. | |
2 | version_info = "FFADO diagnostic utility $VERSION$REVISIONSTRING" | |
3 | copyright_info = """ | |
4 | (C) 2008 Pieter Palmers | |
5 | 2009-2010 Arnold Krille | |
6 | 2018 Nicolas Boulenguez, Jonathan Woithe | |
7 | """ | |
8 | static_info = "$LIBDATADIR/static_info.txt" | |
7 | 9 | # This program is free software: you can redistribute it and/or modify |
8 | 10 | # it under the terms of the GNU General Public License as published by |
9 | 11 | # the Free Software Foundation, version 3 of the License. |
10 | # | |
12 | ||
11 | 13 | # This program is distributed in the hope that it will be useful, |
12 | 14 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
13 | 15 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
14 | 16 | # GNU General Public License for more details. |
15 | # | |
17 | ||
16 | 18 | # You should have received a copy of the GNU General Public License |
17 | 19 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
18 | # | |
19 | ||
20 | # | |
20 | ||
21 | 21 | # Test for common FFADO problems |
22 | # | |
23 | ||
22 | ||
23 | import glob | |
24 | import os.path | |
25 | import re | |
26 | import subprocess | |
24 | 27 | import sys |
25 | 28 | |
26 | # Add the path of the installed dependent files | |
27 | sys.path.insert(0, "$PYTHONDIR" ) | |
28 | ||
29 | from listirqinfo import IRQ,SoftIRQ,IRQInfo | |
30 | from helpstrings import HelpStrings | |
31 | from ffado_diag_helpers import * | |
32 | ||
33 | ## message strings | |
34 | FFADODIAG_VERSION = "$VERSION$REVISIONSTRING" | |
35 | ||
36 | welcome_msg = """ | |
37 | ||
38 | FFADO diagnostic utility """ + FFADODIAG_VERSION + """ | |
39 | ============================ | |
40 | (C) 2008 Pieter Palmers | |
41 | 2009-2010 Arnold Krille | |
42 | ||
43 | """ | |
44 | ||
45 | help_msg = """ | |
46 | Usage: ffado-diag [verboselevel] | |
47 | ||
48 | verboselevel : verbosity level. (optional) | |
49 | ||
50 | """ | |
51 | ||
52 | ## main program | |
53 | if __name__== '__main__': | |
54 | ||
55 | print welcome_msg | |
56 | ||
57 | num_args = len(sys.argv) | |
58 | if num_args not in [1,2]: | |
59 | print help | |
60 | sys.exit(0) | |
61 | ||
62 | if num_args == 2: | |
63 | loglevel = eval(sys.argv[1]) | |
64 | if loglevel == 1: | |
65 | logging.getLogger('diag').setLevel(logging.INFO) | |
66 | elif loglevel == 2: | |
67 | logging.getLogger('diag').setLevel(logging.DEBUG) | |
68 | ||
69 | print "=== CHECK ===" | |
70 | print " Base system..." | |
71 | ||
72 | # check kernel | |
73 | kernel_version = get_kernel_version() | |
74 | print " kernel version............ " + str(kernel_version) | |
75 | kernel_is_preempt = get_kernel_preempt() | |
76 | print " Preempt (low latency)... " + str(kernel_is_preempt) | |
77 | # Hint: The main parts of the rt patches are in mainline-kernels nowadays. Performance with stock kernels is sufficient... | |
78 | kernel_is_rt_patched = get_kernel_rt_patched() | |
79 | print " RT patched.............. " + str(kernel_is_rt_patched) | |
80 | ||
81 | # check modules | |
82 | oldstack_present = check_1394oldstack_present() | |
83 | oldstack_loaded = check_1394oldstack_loaded() | |
84 | oldstack_active = check_1394oldstack_active() | |
85 | oldstack_statically_linked = not check_1394oldstack_loaded() and check_1394oldstack_linked() | |
86 | newstack_present = check_1394newstack_present() | |
87 | newstack_loaded = check_1394newstack_loaded() | |
88 | newstack_active = check_1394newstack_active() | |
89 | newstack_statically_linked = not check_1394newstack_loaded() and check_1394newstack_linked() | |
90 | ||
91 | print " old 1394 stack present.... " + str(oldstack_present) | |
92 | print " old 1394 stack loaded..... " + str(oldstack_loaded) | |
93 | print " old 1394 stack active..... " + str(oldstack_active) | |
94 | print " new 1394 stack present.... " + str(newstack_present) | |
95 | print " new 1394 stack loaded..... " + str(newstack_loaded) | |
96 | print " new 1394 stack active..... " + str(newstack_active) | |
97 | ||
98 | # check /dev/raw1394 node presence | |
99 | devnode_present = check_1394oldstack_devnode_present() | |
100 | print " /dev/raw1394 node present. " + str(devnode_present) | |
101 | if devnode_present: | |
102 | # check /dev/raw1394 access permissions | |
103 | devnode_permissions = check_1394oldstack_devnode_permissions() | |
104 | print " /dev/raw1394 permissions.. " + str(devnode_permissions) | |
29 | # Prefer reproducible output with few non-ASCII characters. | |
30 | os.environ ["LC_ALL"] = "C" | |
31 | ||
32 | # Consistent formatting. | |
33 | def show_pair (key, value): | |
34 | # rstrip () for convenience, but do not assume that value is a string. | |
35 | print ("{:25} {}".format (key, value).rstrip ()) | |
36 | def indent (lines): | |
37 | print (" {}".format (lines.rstrip ().replace ("\n", "\n "))) | |
38 | ||
39 | # Convenient shortcuts. | |
40 | def stdout (*args): | |
41 | return subprocess.check_output (args).decode ("utf8") | |
42 | ||
43 | def which (command): | |
44 | popen = subprocess.Popen (("which", command), stdout=subprocess.PIPE, | |
45 | stderr=subprocess.PIPE) | |
46 | stdout, stderr = popen.communicate () | |
47 | if popen.returncode == 0: | |
48 | return stdout.decode ("utf8").rstrip () | |
49 | elif popen.returncode == 1: | |
50 | return None | |
105 | 51 | else: |
106 | devnode_permissions = None | |
107 | ||
108 | if newstack_active: | |
109 | # check permissions | |
110 | newstack_permissions = get_juju_permissions() | |
111 | print " /dev/fw* permissions:" | |
112 | print newstack_permissions | |
113 | ||
114 | print " User IDs:" | |
115 | print get_user_ids() | |
116 | ||
117 | ||
118 | # check libraries | |
119 | print " Prerequisites (dynamic at run-time)..." | |
120 | print " gcc ............... %s" % get_version_first_line('gcc --version') | |
121 | print " g++ ............... %s" % get_version_first_line('g++ --version') | |
122 | print " PyQt4 (by pyuic4) . %s" % get_version_first_line('pyuic4 --version') | |
123 | print " PyQt5 (by pyuic5) . %s" % get_version_first_line('pyuic5 --version') | |
124 | print " jackd ............. %s" % get_version_first_line('jackd --version') | |
125 | print " path ............ %s" % get_command_path('jackd') | |
126 | print " flags ........... %s" % get_package_flags("jack") | |
127 | print " libraw1394 ........ %s" % get_package_version("libraw1394") | |
128 | print " flags ........... %s" % get_package_flags("libraw1394") | |
129 | print " libavc1394 ........ %s" % get_package_version("libavc1394") | |
130 | print " flags ........... %s" % get_package_flags("libavc1394") | |
131 | print " libiec61883 ....... %s" % get_package_version("libiec61883") | |
132 | print " flags ........... %s" % get_package_flags("libiec61883") | |
133 | print " libxml++-2.6 ...... %s" % get_package_version("libxml++-2.6") | |
134 | print " flags ........... %s" % get_package_flags("libxml++-2.6") | |
135 | print " dbus-1 ............ %s" % get_package_version("dbus-1") | |
136 | print " flags ........... %s" % get_package_flags("dbus-1") | |
137 | print " Prerequisites (static at compile-time)..." | |
138 | f = open( "$PYTHONDIR/static_info.txt", "r" ) | |
52 | print (stderr) | |
53 | sys.exit (1) | |
54 | ||
55 | # Parse command line. | |
56 | usage = """Usage: ffado-diag [--static | -V | --version | --usage] | |
57 | --static Only display executable paths and libraries. | |
58 | -V, --version Display version information. | |
59 | --usage Print a short usage message and exit.""" | |
60 | if len (sys.argv) == 1: | |
61 | static_option = False | |
62 | elif len (sys.argv) == 2: | |
63 | if sys.argv [1] == "--static": | |
64 | static_option = True | |
65 | elif sys.argv [1] in ("-V", "--version"): | |
66 | print (version_info) | |
67 | sys.exit (0) | |
68 | elif sys.argv [1] == "--usage": | |
69 | print (usage) | |
70 | sys.exit (0) | |
71 | else: | |
72 | print (usage) | |
73 | sys.exit (1) | |
74 | else: | |
75 | print (usage) | |
76 | sys.exit (1) | |
77 | ||
78 | if not(static_option): | |
79 | print (version_info) | |
80 | print (copyright_info) | |
81 | ||
82 | for command in ("gcc", "g++", "pyuic4", "pyuic5"): | |
83 | path = which (command) | |
84 | show_pair (command, path) | |
85 | if path: | |
86 | version = stdout (path, "--version") | |
87 | show_pair ('', version [:version.find ("\n")]) | |
88 | ||
89 | # jackd --version exits with a non-zero status (tested with jackd 1.9.10). | |
90 | path = which ("jackd") | |
91 | show_pair ("jackd", path) | |
92 | if path: | |
93 | popen = subprocess.Popen ((path, "--version"), stdout=subprocess.PIPE) | |
94 | version, _ = popen.communicate () | |
95 | version = version.decode ("utf8") | |
96 | show_pair ('', version [:version.find ("\n")]) | |
97 | ||
98 | pkg_config = which ("pkg-config") | |
99 | show_pair ("pkg-config", pkg_config) | |
100 | ||
101 | if pkg_config: | |
102 | for lib in ("jack", "libraw1394", "libavc1394", "libiec61883", "libxml++-2.6", "dbus-1"): | |
103 | if subprocess.call ((pkg_config, "--exists", lib)): | |
104 | show_pair (lib, "not found") | |
105 | else: | |
106 | show_pair (lib, stdout (pkg_config, "--modversion", lib)) | |
107 | show_pair ('', stdout (pkg_config, "--cflags", "--libs", lib)) | |
108 | ||
109 | # If the "static" command line argument has been given, stop here. | |
110 | # Else, attempt to display static_info.txt and go on. | |
111 | if static_option: | |
112 | sys.exit (0) | |
113 | ||
114 | print ('') | |
115 | show_pair ("Build time info", static_info) | |
116 | try: | |
117 | with open (static_info, "r" ) as f: | |
118 | for line in f: | |
119 | indent (line) | |
120 | except: | |
121 | indent ("Failed to read build time info.") | |
122 | ||
123 | print ('') | |
124 | kernel_version = stdout ("uname", "-r").rstrip () | |
125 | show_pair ("kernel version", kernel_version) | |
126 | ||
127 | uname_v = stdout ("uname", "-v") | |
128 | show_pair ("Preempt (low latency)", " PREEMPT " in uname_v and not " RT " in uname_v) | |
129 | show_pair ("RT patched", "PREEMPT RT" in uname_v) | |
130 | # Hint: | |
131 | # The main parts of the rt patches are in mainline-kernels nowadays. | |
132 | # Performance with stock kernels is sufficient... | |
133 | ||
134 | fw_devices = glob.glob ("/dev/fw*") | |
135 | show_pair ("/dev/fw*", fw_devices) | |
136 | if fw_devices: | |
137 | indent (stdout (*(["ls", "-lh"] + fw_devices))) | |
138 | ||
139 | show_pair ("User IDs", stdout ("id")) | |
140 | ||
141 | show_pair ("uname -a", stdout ("uname", "-a")) | |
142 | ||
143 | lspci = which ("lspci") | |
144 | if not lspci and os.path.exists ("/sbin/lspci"): | |
145 | lspci = "/sbin/lspci" | |
146 | show_pair ("lspci", lspci) | |
147 | if lspci: | |
148 | for m in re.findall ("^([^ ]*).*1394.*", stdout (lspci), re.MULTILINE): | |
149 | indent (stdout (lspci, "-vv", "-nn", "-s", m)) | |
150 | ||
151 | lscpu = which ("lscpu") | |
152 | show_pair ("lscpu", lscpu) | |
153 | if lscpu: | |
154 | indent (stdout (lscpu)) | |
155 | else: | |
156 | print ("/proc/cpuinfo") | |
157 | with open ("/proc/cpuinfo") as f: | |
158 | for l in f: | |
159 | indent (l) | |
160 | ||
161 | ###################################################################### | |
162 | class IRQ: | |
163 | def __init__(self, number): | |
164 | self.number = number | |
165 | self.pid = "" | |
166 | self.scheduling_class = "" | |
167 | self.scheduling_priority = "" | |
168 | self.drivers = "" | |
169 | self.cpu_counts = "" | |
170 | def description (self): | |
171 | return "IRQ{:>4} PID{:>5} count{:>18} Sched{:>4} priority{:>4} drivers {}"\ | |
172 | .format (self.number, self.pid, self.cpu_counts, self.scheduling_class, | |
173 | self.scheduling_priority, self.drivers) | |
174 | ||
175 | class SoftIRQ: | |
176 | def __init__(self, pid, scheduling_class, scheduling_priority, fullname): | |
177 | self.pid = pid | |
178 | self.fullname = fullname | |
179 | self.scheduling_class = scheduling_class | |
180 | self.scheduling_priority = scheduling_priority | |
181 | def name (self): | |
182 | return "{}-{}".format (self.fullname, self.pid) | |
183 | def description (self): | |
184 | return "SoftIRQ{:>12} PID{:>6} Sched{:>4} priority{:>4}) name softirq-{}"\ | |
185 | .format (self.name (), self.pid, self.scheduling_class, | |
186 | self.scheduling_priority, self.fullname) | |
187 | ||
188 | # get PID info | |
189 | outtext = stdout ("ps", "-eLo", "pid,cmd,class,rtprio") | |
190 | ||
191 | softIRQs = {} | |
192 | for m in re.findall (r"^([0-9]+) +\[softirq-(.*)\] +([A-Z]+) +([-0-9]+)", outtext, re.MULTILINE): | |
193 | irq = SoftIRQ (pid = m.group (1), | |
194 | fullname = m.group (2), | |
195 | scheduling_class = m.group (3), | |
196 | scheduling_priority = m.group (4)) | |
197 | softIRQs [irq.name ()] = irq | |
198 | ||
199 | IRQs = {} | |
200 | for m in re.findall (r"^([0-9]+) +\[IRQ-([0-9]+)\] +([A-Z]{2}) +([-0-9]+)", outtext, re.MULTILINE): | |
201 | irq = IRQ (number = int (m.group (2))) | |
202 | IRQs [irq.number] = irq | |
203 | irq.pid = m.group (1) | |
204 | irq.scheduling_class = m.group (3) | |
205 | irq.scheduling_priority = m.group (4) | |
206 | ||
207 | # get irq info | |
208 | regex_irq = re.compile (r"^ *([0-9]+): *((?:[0-9]+ +)+)(.*)$") | |
209 | with open ("/proc/interrupts") as f: | |
139 | 210 | for line in f: |
140 | line = line[:-1] | |
141 | if line is not "\n" and line.startswith(" "): | |
142 | print line | |
143 | f.close() | |
144 | ||
145 | # libraw | |
146 | ||
147 | print " uname -a..." | |
148 | print " " + run_command("uname -a") | |
149 | ||
150 | print " Hardware..." | |
151 | # check host controller | |
152 | print " Host controllers:" | |
153 | list_host_controllers() | |
154 | print " CPU info:" | |
155 | if len(run_command("which lscpu")) > 0: | |
156 | print run_command("lscpu") | |
157 | else: | |
158 | print run_command("cat /proc/cpuinfo") | |
159 | ||
160 | print " Configuration..." | |
161 | # check RT settings | |
162 | ||
163 | # check IRQ settings | |
164 | print " IRQ information" | |
165 | info = IRQInfo() | |
166 | ||
167 | info.load() | |
168 | print str(info) | |
169 | ||
170 | print "" | |
171 | print "=== REPORT ===" | |
172 | ||
173 | help = HelpStrings() | |
174 | ||
175 | # do the interpretation of the tests | |
176 | print "FireWire kernel drivers:" | |
177 | if (oldstack_loaded or oldstack_statically_linked) and \ | |
178 | (newstack_loaded or newstack_statically_linked): | |
179 | help.show('MODULES_BOTH_STACKS_LOADED') | |
180 | sys.exit(-1) | |
181 | elif newstack_loaded or newstack_statically_linked: | |
182 | help.show('MODULES_NEW_STACK_LOADED') | |
183 | sys.exit(-1) | |
184 | elif oldstack_statically_linked: | |
185 | print "[PASS] Kernel drivers statically linked into the kernel." | |
186 | elif not oldstack_present: | |
187 | help.show('MODULES_OLD_STACK_NOT_INSTALLED') | |
188 | sys.exit(-1) | |
189 | elif not oldstack_loaded: | |
190 | help.show('MODULES_OLD_STACK_NOT_LOADED') | |
191 | sys.exit(-1) | |
192 | else: | |
193 | print "[PASS] Kernel modules present and correctly loaded." | |
194 | ||
195 | if not devnode_present: | |
196 | help.show('DEVNODE_OLD_STACK_NOT_PRESENT') | |
197 | sys.exit(-1) | |
198 | else: | |
199 | if not devnode_permissions: | |
200 | help.show('DEVNODE_OLD_STACK_NO_PERMISSION') | |
201 | sys.exit(-1) | |
202 | else: | |
203 | print "[PASS] /dev/raw1394 node present and accessible." | |
204 | ||
205 | ||
206 | ||
211 | m = regex_irq.search (line) | |
212 | if m: | |
213 | irq_number = int (m.group(1)) | |
214 | if irq_number in IRQs: | |
215 | irq = IRQs [irq_number] | |
216 | else: | |
217 | irq = IRQ (number = irq_number) | |
218 | IRQs [irq_number] = irq | |
219 | irq.cpu_counts = ",".join (m.group (2).split ()) | |
220 | irq.drivers = ",".join (m.group (3).split ()) | |
221 | ||
222 | print ("\nHardware interrupts") | |
223 | for _, irq in sorted (IRQs.items ()): | |
224 | indent (irq.description ()) | |
225 | print ("\nSoftware interrupts") | |
226 | for _, irq in sorted (softIRQs.items ()): | |
227 | indent (irq.description ()) | |
228 | print ('') | |
229 | ||
230 | ###################################################################### | |
231 | ||
232 | def module_loaded (module_name, procfile): | |
233 | with open (procfile) as f: | |
234 | for l in f: | |
235 | if module_name in l or module_name.replace ("-", "_") in l: | |
236 | return True | |
237 | return False | |
238 | ||
239 | module_dir = "/lib/modules/" + kernel_version | |
240 | show_pair ("module directory", module_dir) | |
241 | ||
242 | class Stack: | |
243 | def __init__ (self, modules, main_module): | |
244 | self.present = True | |
245 | self.loaded = True | |
246 | for module_name in modules: | |
247 | if module_name in stdout ("find", module_dir, "-name", module_name + ".ko"): | |
248 | indent (module_name + " present") | |
249 | else: | |
250 | indent (module_name + " not present") | |
251 | self.present = False | |
252 | ||
253 | if module_loaded (module_name, "/proc/modules"): | |
254 | indent (module_name + " loaded") | |
255 | else: | |
256 | indent (module_name + " not loaded") | |
257 | self.loaded = False | |
258 | ||
259 | self.active = self.loaded and module_loaded (main_module, "/proc/interrupts") | |
260 | show_pair ("stack active", self.active) | |
261 | ||
262 | self.statically_linked = not self.loaded and os.access ("/sys/module/" + main_module, os.F_OK) | |
263 | show_pair ("statically linked", self.statically_linked) | |
264 | ||
265 | print ("Old 1394 stack") | |
266 | oldstack = Stack (("ieee1394", "ohci1394", "raw1394"), "ohci1394") | |
267 | ||
268 | print ("New 1394 stack") | |
269 | newstack = Stack (("firewire-core", "firewire-ohci"), "firewire-ohci") | |
270 | ||
271 | print ("Kernel support:") | |
272 | if (oldstack.loaded or oldstack.statically_linked) and \ | |
273 | (newstack.loaded or newstack.statically_linked): | |
274 | indent ("""Both old and new FireWire kernel modules are loaded, your system | |
275 | configuration is bogus.""") | |
276 | sys.exit (1) | |
277 | elif newstack.loaded or newstack.statically_linked: | |
278 | indent ("""The new FireWire kernel stack is loaded. | |
279 | If running a kernel earlier than 2.6.37 and problems are experienced, either | |
280 | try with the old Firewire kernel stack or upgrade to a newer kernel | |
281 | (preferrably 2.6.37 or later).""") | |
282 | sys.exit (1) | |
283 | elif oldstack.statically_linked: | |
284 | indent ("[PASS] Kernel drivers statically linked into the kernel.") | |
285 | elif not oldstack.present: | |
286 | indent ("""FireWire kernel module(s) not found. | |
287 | Please ensure that the raw1394 module is loaded.""") | |
288 | sys.exit (1) | |
289 | elif not oldstack.loaded: | |
290 | indent ("""FireWire kernel stack not present. | |
291 | Please compile the kernel with FireWire support.""") | |
292 | sys.exit (1) | |
293 | else: | |
294 | indent ("[PASS] Kernel modules present and correctly loaded.") | |
295 | ||
296 | ###################################################################### | |
297 | print ("/dev/raw1394 devices:") | |
298 | ||
299 | if not os.path.exists ("/dev/raw1394"): | |
300 | indent ("""/dev/raw1394 device node not present. | |
301 | Please fix your udev configuration or add it as a static node.""") | |
302 | sys.exit (1) | |
303 | ||
304 | try: | |
305 | with open ("/dev/raw1394", "w"): | |
306 | pass | |
307 | except: | |
308 | indent ("""Not enough permissions to access /dev/raw1394 device. | |
309 | Please fix your udev configuration, the node permissions or | |
310 | the user/group permissions.""") | |
311 | sys.exit (1) | |
312 | ||
313 | indent ("[PASS] /dev/raw1394 node present and accessible.") |
17 | 17 | # |
18 | 18 | |
19 | 19 | # |
20 | # A script to install FFADO in a 'sandbox', i.e. without changing the | |
20 | # A script to install FFADO in a 'sandbox', i.e. without changing the | |
21 | 21 | # system installation. |
22 | 22 | # |
23 | import os | |
23 | ||
24 | import os.path | |
25 | import shutil | |
26 | import subprocess | |
27 | ||
28 | try: | |
29 | raw_input # Error in python3. | |
30 | except: | |
31 | raw_input = input | |
24 | 32 | |
25 | 33 | FFADOSBI_VERSION = '0.1' |
26 | 34 | LATEST_FFADO_RELEASE_URL = 'http://www.ffado.org/files/libffado-2.0-beta7.tar.gz' |
62 | 70 | else: |
63 | 71 | continue |
64 | 72 | else: |
65 | os.system('rm -Rf "%s"' % ret_dir) | |
73 | shutil.rmtree (ret_dir) | |
66 | 74 | os.makedirs(ret_dir) |
67 | 75 | break |
68 | 76 | return ret_dir |
69 | 77 | |
70 | 78 | def fetch_source(build_dir, source_descriptor, target): |
71 | logfile = "%s/%s.log" % (build_dir, target) | |
72 | os.system('echo "" > %s' % logfile) | |
79 | logfile = "%s/%s.log" % (build_dir, target) | |
80 | with open (logfile, 'w') as log: | |
73 | 81 | |
74 | 82 | if source_descriptor[1] == 'svn': |
75 | 83 | print( " Checking out SVN repository: %s" % source_descriptor[2] ) |
76 | 84 | cwd = os.getcwd() |
77 | 85 | os.chdir(build_dir) |
78 | retval = os.system('svn co "%s" "%s" >> %s' % (source_descriptor[2], target, logfile)) | |
86 | retval = subprocess.call (('svn', 'co', source_descriptor[2], target), | |
87 | stdout=log) | |
79 | 88 | os.chdir(cwd) |
80 | 89 | if retval: |
81 | 90 | print( " Failed to checkout the SVN repository. Inspect %s for details. (is subversion installed?)" % logfile ) |
93 | 102 | cwd = os.getcwd() |
94 | 103 | os.chdir(build_dir) |
95 | 104 | print( " extracting tarball..." ) |
96 | retval = os.system('tar -zxf "%s" > %s' % (tmp_file, logfile)) | |
105 | retval = subprocess.call (('tar', '-zxf', tmp_file), stdout=log) | |
97 | 106 | if retval: |
98 | 107 | print( " Failed to extract the source tarball. Inspect %s for details." % logfile ) |
99 | 108 | os.chdir(cwd) |
100 | 109 | return False |
101 | 110 | if source_descriptor[3]: |
102 | retval = os.system('mv "%s" "%s"' % (source_descriptor[3], target)) | |
103 | if retval: | |
111 | try: | |
112 | os.rename (source_descriptor[3], target) | |
113 | except: | |
104 | 114 | print( " Failed to move the extracted tarball" ) |
105 | 115 | os.chdir(cwd) |
106 | 116 | return False |
144 | 154 | SANDBOX DIRECTORY |
145 | 155 | ================= |
146 | 156 | |
147 | The sandbox directory is the directory where all built files are | |
157 | The sandbox directory is the directory where all built files are | |
148 | 158 | installed into. It should be writable by your user, and will |
149 | 159 | contain the evaluation binaries if this tool is successful. If |
150 | 160 | it doesn't exist, it will be created. |
212 | 222 | while True: |
213 | 223 | ffado_version = raw_input("Please select a FFADO version: ") |
214 | 224 | try: |
215 | ffado_version_int = eval(ffado_version) | |
225 | ffado_version_int = int (ffado_version) | |
216 | 226 | if ffado_version_int not in [0, 1, 2]: |
217 | 227 | raise |
218 | 228 | except: |
242 | 252 | while True: |
243 | 253 | jack_version = raw_input("Please select a jack version: ") |
244 | 254 | try: |
245 | jack_version_int = eval(jack_version) | |
255 | jack_version_int = int (jack_version) | |
246 | 256 | if jack_version_int not in [0, 1, 2]: |
247 | 257 | raise |
248 | 258 | except: |
285 | 295 | cwd = os.getcwd() |
286 | 296 | |
287 | 297 | ffado_log = "%s/ffadobuild.log" % build_dir |
288 | ffado_scons_options = "-j2" # TODO: interactive config of the build | |
289 | os.system('echo "" > %s' % ffado_log) | |
290 | ||
291 | # configure FFADO | |
292 | os.chdir("%s/libffado/" % build_dir) | |
293 | print( "Building FFADO..." ) | |
294 | print( " Compiling..." ) | |
295 | retval = os.system('scons PREFIX="%s" %s >> %s' % (sandbox_dir, ffado_scons_options, ffado_log)) | |
296 | if retval: | |
297 | print( """ ) | |
298 | ffado_scons_options = ("-j2",) # TODO: interactive config of the build | |
299 | with open (ffado_log, 'w') as log: | |
300 | ||
301 | # configure FFADO | |
302 | os.chdir("%s/libffado/" % build_dir) | |
303 | print( "Building FFADO..." ) | |
304 | print( " Compiling..." ) | |
305 | if subprocess.call (('scons', 'PREFIX="' + sandbox_dir + '"') + ffado_scons_options, | |
306 | stdout=log): | |
307 | print( """ ) | |
298 | 308 | Failed to configure/build FFADO. Most likely this is due to uninstalled dependencies. |
299 | 309 | Check %s for details. |
300 | 310 | """ % ffado_log |
301 | exit(-1) | |
302 | ||
303 | # install FFADO | |
304 | print( " Installing into %s..." % sandbox_dir ) | |
305 | retval = os.system('scons install >> %s' % (ffado_log)) | |
306 | if retval: | |
307 | print( "Failed to install FFADO. Check %s for details." % ffado_log ) | |
308 | exit(-1) | |
311 | exit(-1) | |
312 | ||
313 | # install FFADO | |
314 | print( " Installing into %s..." % sandbox_dir ) | |
315 | if subprocess.check_output (('scons', 'install'), stdout=log): | |
316 | print( "Failed to install FFADO. Check %s for details." % ffado_log ) | |
317 | exit(-1) | |
309 | 318 | |
310 | 319 | # configure JACK |
311 | 320 | os.chdir("%s/jack/" % build_dir) |
312 | 321 | jack_log = "%s/jackbuild.log" % build_dir |
313 | os.system('echo "" > %s' % jack_log) | |
314 | ||
315 | print( "Building Jack..." ) | |
316 | if use_jack_version[1] == 'svn': | |
317 | print( " Initializing build system..." ) | |
318 | retval = os.system('./autogen.sh >> %s' % jack_log) | |
319 | if retval: | |
320 | print( """ ) | |
322 | with open (jack_log, 'w') as log: | |
323 | log.write ('\n') | |
324 | ||
325 | print( "Building Jack..." ) | |
326 | if use_jack_version[1] == 'svn': | |
327 | print( " Initializing build system..." ) | |
328 | if subprocess.check_output (('./autogen.sh',), stdout=log): | |
329 | print( """ ) | |
321 | 330 | Failed to initialize the jack build system. Most likely this is due to uninstalled dependencies. |
322 | 331 | Check %s for details. |
323 | 332 | """ % jack_log |
324 | exit(-1) | |
325 | ||
326 | print( " Configuring build..." ) | |
327 | retval = os.system('./configure --prefix="%s" >> %s' % (sandbox_dir, jack_log)) | |
328 | if retval: | |
329 | print( """ ) | |
333 | exit(-1) | |
334 | ||
335 | print( " Configuring build..." ) | |
336 | if subprocess.check_output (('./configure', '--prefix="' + sandbox_dir + '"'), | |
337 | stdout=log): | |
338 | print( """ ) | |
330 | 339 | Failed to configure the jack build. Most likely this is due to uninstalled dependencies. |
331 | 340 | Check %s for details. |
332 | 341 | """ % jack_log |
333 | exit(-1) | |
334 | ||
335 | # build and install jack | |
336 | print( " Compiling..." ) | |
337 | retval = os.system('make >> %s' % (jack_log)) | |
338 | if retval: | |
339 | print( "Failed to build jack. Check %s for details." % jack_log ) | |
340 | exit(-1) | |
341 | ||
342 | print( " Installing into %s..." % sandbox_dir ) | |
343 | retval = os.system('make install >> %s' % (jack_log)) | |
344 | if retval: | |
345 | print( "Failed to install jack. Check %s for details." % jack_log ) | |
346 | exit(-1) | |
342 | exit(-1) | |
343 | ||
344 | # build and install jack | |
345 | print( " Compiling..." ) | |
346 | if subprocess.check_output (('make',), stdout=log): | |
347 | print( "Failed to build jack. Check %s for details." % jack_log ) | |
348 | exit(-1) | |
349 | ||
350 | print( " Installing into %s..." % sandbox_dir ) | |
351 | if subprocess.check_output (('make', 'install'), stdout=log): | |
352 | print( "Failed to install jack. Check %s for details." % jack_log ) | |
353 | exit(-1) | |
347 | 354 | |
348 | 355 | # write the bashrc file |
349 | 356 | sandbox_bashrc = """ |
362 | 369 | print( "Writing shell configuration file..." ) |
363 | 370 | sandbox_rc_file = "%s/ffado.rc" % sandbox_dir |
364 | 371 | try: |
365 | fid = open(sandbox_rc_file, "w") | |
366 | fid.write(sandbox_bashrc) | |
367 | fid.close() | |
372 | with open (sandbox_rc_file, "w") as fid: | |
373 | fid.write(sandbox_bashrc) | |
368 | 374 | except: |
369 | 375 | print( "Could not write the sandbox rc file." ) |
370 | 376 | exit(-1) |
0 | # | |
1 | # Copyright (C) 2008 Pieter Palmers | |
2 | # | |
3 | # This program is free software: you can redistribute it and/or modify | |
4 | # it under the terms of the GNU General Public License as published by | |
5 | # the Free Software Foundation, version 3 of the License. | |
6 | # | |
7 | # This program is distributed in the hope that it will be useful, | |
8 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
9 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
10 | # GNU General Public License for more details. | |
11 | # | |
12 | # You should have received a copy of the GNU General Public License | |
13 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
14 | # | |
15 | ||
16 | # | |
17 | # Test for common FFADO problems | |
18 | # | |
19 | ||
20 | import sys | |
21 | ||
22 | import os | |
23 | import re | |
24 | import logging | |
25 | ||
26 | # Allow for the movement of getstatusoutput from the "commands" module (in | |
27 | # python2) to the "subprocess" module in python3. | |
28 | try: | |
29 | from subprocess import getstatusoutput | |
30 | except ImportError: | |
31 | from commands import getstatusoutput | |
32 | ||
33 | ## logging setup | |
34 | logging.basicConfig() | |
35 | log = logging.getLogger('diag') | |
36 | ||
37 | ## helper routines | |
38 | ||
39 | # kernel | |
40 | def get_kernel_version(): | |
41 | return run_command('uname -r') | |
42 | ||
43 | def get_kernel_rt_patched(): | |
44 | l = run_command('uname -v') | |
45 | if l.find("PREEMPT RT") > -1: | |
46 | return True | |
47 | return False | |
48 | ||
49 | def get_kernel_preempt(): | |
50 | l = run_command('uname -v') | |
51 | if l.find(" PREEMPT ") > -1 and l.find(" RT ") == -1: | |
52 | return True | |
53 | return False | |
54 | ||
55 | # modules | |
56 | def check_for_module_loaded(modulename, procfile): | |
57 | log.info("Checking if module '%s' is present in %s... " % (modulename, procfile)) | |
58 | f = open(procfile) | |
59 | lines = f.readlines() | |
60 | f.close() | |
61 | for l in lines: | |
62 | if l.find(modulename) > -1 or l.find(modulename.replace('-', '_')) > -1: | |
63 | log.info(" found") | |
64 | return True | |
65 | log.info(" not found") | |
66 | return False | |
67 | ||
68 | def check_for_module_present(modulename): | |
69 | log.info("Checking if module '%s' is present... " % modulename) | |
70 | kver = get_kernel_version() | |
71 | (exitstatus, outtext) = getstatusoutput("find \"/lib/modules/%s/\" -name '%s.ko' | grep '%s'" % \ | |
72 | (kver, modulename, modulename) ) | |
73 | log.debug("find outputs: %s" % outtext) | |
74 | if outtext == "": | |
75 | log.info(" not found") | |
76 | return False | |
77 | else: | |
78 | log.info(" found") | |
79 | return True | |
80 | ||
81 | def check_1394oldstack_active(): | |
82 | return check_for_module_loaded('ohci1394', '/proc/interrupts') | |
83 | ||
84 | def check_1394oldstack_linked(): | |
85 | return os.access('/sys/module/ohci1394', os.F_OK) and \ | |
86 | os.access('/sys/module/raw1394', os.F_OK) | |
87 | ||
88 | def check_1394oldstack_loaded(): | |
89 | retval = True | |
90 | for modulename in ('ieee1394', 'ohci1394', 'raw1394'): | |
91 | if not check_for_module_loaded(modulename, '/proc/modules'): | |
92 | retval = False | |
93 | return retval | |
94 | ||
95 | def check_1394oldstack_present(): | |
96 | retval = True | |
97 | for modulename in ('ieee1394', 'ohci1394', 'raw1394'): | |
98 | if not check_for_module_present(modulename): | |
99 | retval = False | |
100 | return retval | |
101 | ||
102 | def check_1394newstack_active(): | |
103 | return check_for_module_loaded('firewire_ohci', '/proc/interrupts') | |
104 | ||
105 | def check_1394newstack_linked(): | |
106 | return os.access('/sys/module/firewire_ohci', os.F_OK) | |
107 | ||
108 | def check_1394newstack_loaded(): | |
109 | retval = True | |
110 | for modulename in ('firewire_core', 'firewire_ohci'): | |
111 | if not check_for_module_loaded(modulename, '/proc/modules'): | |
112 | retval = False | |
113 | return retval | |
114 | ||
115 | def check_1394newstack_present(): | |
116 | retval = True | |
117 | for modulename in ('firewire-core', 'firewire-ohci'): | |
118 | if not check_for_module_present(modulename): | |
119 | retval = False | |
120 | return retval | |
121 | ||
122 | def check_1394oldstack_devnode_present(): | |
123 | return os.path.exists('/dev/raw1394') | |
124 | ||
125 | def check_1394oldstack_devnode_permissions(): | |
126 | f = open('/dev/raw1394','w') | |
127 | if f: | |
128 | f.close() | |
129 | return True | |
130 | else: | |
131 | return False | |
132 | ||
133 | def run_command(cmd): | |
134 | (exitstatus, outtext) = getstatusoutput(cmd) | |
135 | log.debug("%s outputs: %s" % (cmd, outtext)) | |
136 | return outtext | |
137 | ||
138 | # package versions | |
139 | def get_package_version(name): | |
140 | cmd = "pkg-config --modversion %s" % name | |
141 | return run_command(cmd) | |
142 | ||
143 | def get_package_flags(name): | |
144 | cmd = "pkg-config --cflags --libs %s" % name | |
145 | return run_command(cmd) | |
146 | ||
147 | def get_command_path(name): | |
148 | cmd = "which %s 2> /dev/null" % name | |
149 | return run_command(cmd) | |
150 | ||
151 | def get_version_first_line(cmd): | |
152 | ver = run_command(cmd).split("\n") | |
153 | if len(ver) == 0: | |
154 | ver = ["None"] | |
155 | if "sh: " in ver[0]: | |
156 | ver = ["Not found"] | |
157 | return ver[0] | |
158 | ||
159 | ||
160 | def list_host_controllers(): | |
161 | lspci_cmd = get_command_path("lspci") | |
162 | if lspci_cmd == "": | |
163 | lspci_cmd = "/sbin/lspci" | |
164 | cmd = lspci_cmd + " | grep 1394" | |
165 | controllers = run_command(cmd).split("\n") | |
166 | log.debug(lspci_cmd + " | grep 1394: %s" % controllers) | |
167 | for c in controllers: | |
168 | tmp = c.split() | |
169 | if len(tmp) > 0: | |
170 | tmp | |
171 | cmd = lspci_cmd + " -vv -nn -s %s" % tmp[0] | |
172 | print( run_command(cmd) ) | |
173 | ||
174 | def get_juju_permissions(): | |
175 | return run_command('ls -lh /dev/fw*') | |
176 | ||
177 | def get_user_ids(): | |
178 | return run_command('id'); |
0 | # | |
1 | # Copyright (C) 2008 Pieter Palmers | |
2 | # | |
3 | # This program is free software: you can redistribute it and/or modify | |
4 | # it under the terms of the GNU General Public License as published by | |
5 | # the Free Software Foundation, version 3 of the License. | |
6 | # | |
7 | # This program is distributed in the hope that it will be useful, | |
8 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
9 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
10 | # GNU General Public License for more details. | |
11 | # | |
12 | # You should have received a copy of the GNU General Public License | |
13 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
14 | # | |
15 | ||
16 | # | |
17 | # Help strings for ffado problems | |
18 | # | |
19 | ||
20 | class HelpStrings: | |
21 | def __init__(self): | |
22 | strings = {} | |
23 | strings['MODULES_OLD_STACK_NOT_INSTALLED']=""" | |
24 | FireWire kernel stack not present. Please compile the kernel with | |
25 | FireWire support. | |
26 | """ | |
27 | strings['MODULES_BOTH_STACKS_LOADED']=""" | |
28 | Both old and new FireWire kernel modules are loaded, your system | |
29 | configuration is bogus. | |
30 | """ | |
31 | strings['MODULES_NEW_STACK_LOADED']=""" | |
32 | The new FireWire kernel stack is loaded. | |
33 | If running a kernel earlier than 2.6.37 and problems are experienced, either | |
34 | try with the old Firewire kernel stack or upgrade to a newer kernel | |
35 | (preferrably 2.6.37 or later). | |
36 | """ | |
37 | strings['MODULES_OLD_STACK_NOT_LOADED']=""" | |
38 | FireWire kernel module(s) not found. | |
39 | Please ensure that the raw1394 module is loaded. | |
40 | """ | |
41 | strings['DEVNODE_OLD_STACK_NOT_PRESENT']=""" | |
42 | /dev/raw1394 device node not present. | |
43 | Please fix your udev configuration or add it as a static node. | |
44 | """ | |
45 | strings['DEVNODE_OLD_STACK_NO_PERMISSION']=""" | |
46 | Not enough permissions to access /dev/raw1394 device. | |
47 | Please fix your udev configuration, the node permissions or | |
48 | the user/group permissions. | |
49 | """ | |
50 | ||
51 | self.strings=strings | |
52 | ||
53 | def get(self, sid): | |
54 | return self.strings[sid] | |
55 | ||
56 | def show(self, sid): | |
57 | print( self.get(sid) ) | |
58 |
0 | #!/usr/bin/python | |
1 | # | |
2 | ||
3 | # | |
4 | # Copyright (C) 2008 Pieter Palmers | |
5 | # | |
6 | # This program is free software: you can redistribute it and/or modify | |
7 | # it under the terms of the GNU General Public License as published by | |
8 | # the Free Software Foundation, version 3 of the License. | |
9 | # | |
10 | # This program is distributed in the hope that it will be useful, | |
11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | # GNU General Public License for more details. | |
14 | # | |
15 | # You should have received a copy of the GNU General Public License | |
16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
17 | # | |
18 | ||
19 | import os | |
20 | import re | |
21 | ||
22 | # Allow for the movement of getstatusoutput from the "commands" module (in | |
23 | # python2) to the "subprocess" module in python3. | |
24 | try: | |
25 | from subprocess import getstatusoutput | |
26 | except ImportError: | |
27 | from commands import getstatusoutput | |
28 | ||
29 | LISTIRQINFO_VERSION="0.3" | |
30 | ||
31 | def sortedDictValues(adict): | |
32 | items = sorted(adict.items()) | |
33 | return [value for key, value in items] | |
34 | ||
35 | class IRQ: | |
36 | def __init__(self): | |
37 | self.number = None | |
38 | self.scheduling_class = None | |
39 | self.scheduling_priority = None | |
40 | self.process_id = None | |
41 | self.drivers = [] | |
42 | self.cpu_counts = [] | |
43 | def __str__(self): | |
44 | s = " IRQ %4s: PID: %5s, count: %18s, Sched %4s (priority %4s), drivers: %s" % \ | |
45 | (self.number, self.process_id, self.cpu_counts, | |
46 | self.scheduling_class, self.scheduling_priority, | |
47 | self.drivers) | |
48 | return s | |
49 | ||
50 | class SoftIRQ: | |
51 | def __init__(self): | |
52 | self.name = None | |
53 | self.fullname = None | |
54 | self.scheduling_class = None | |
55 | self.scheduling_priority = None | |
56 | self.process_id = None | |
57 | self.cpu_counts = [] | |
58 | def __str__(self): | |
59 | s = " SoftIRQ %12s: PID %6s, Sched %4s (priority %4s), name: %s" % \ | |
60 | (self.name, self.process_id ,self.scheduling_class, self.scheduling_priority, self.fullname) | |
61 | return s | |
62 | ||
63 | class IRQInfo: | |
64 | def __init__(self): | |
65 | self.softIRQs = {} | |
66 | self.IRQs = {} | |
67 | ||
68 | def load(self): | |
69 | # get PID info | |
70 | (exitstatus, outtext) = getstatusoutput('ps -eLo pid,cmd,class,rtprio | grep IRQ') | |
71 | ||
72 | rawstr = r"""([0-9]+) +\[IRQ-([0-9]+)\] +([A-Z]{2}) +([-0-9]+)""" | |
73 | compile_obj = re.compile(rawstr) | |
74 | ||
75 | IRQs = {} | |
76 | for line in outtext.splitlines(): | |
77 | match_obj = compile_obj.search(line) | |
78 | if match_obj: | |
79 | irq = IRQ() | |
80 | irq.process_id = int(match_obj.group(1)) | |
81 | irq.number = int(match_obj.group(2)) | |
82 | irq.scheduling_class = match_obj.group(3) | |
83 | if match_obj.group(4) != '-': | |
84 | irq.scheduling_priority = int(match_obj.group(4)) | |
85 | else: | |
86 | irq.scheduling_priority = None | |
87 | IRQs[irq.number] = irq | |
88 | ||
89 | (exitstatus, outtext) = getstatusoutput('ps -eLo pid,cmd,class,rtprio | grep softirq') | |
90 | ||
91 | rawstr = r"""([0-9]+) +\[softirq-(.*)\] +([A-Z]+) +([-0-9]+)""" | |
92 | compile_obj = re.compile(rawstr) | |
93 | ||
94 | softIRQs = {} | |
95 | for line in outtext.splitlines(): | |
96 | match_obj = compile_obj.search(line) | |
97 | if match_obj: | |
98 | irq = SoftIRQ() | |
99 | irq.process_id = int(match_obj.group(1)) | |
100 | irq.name = "%s-%s" % (match_obj.group(2),irq.process_id) | |
101 | irq.fullname = "softirq-%s" % match_obj.group(2) | |
102 | irq.scheduling_class = match_obj.group(3) | |
103 | if match_obj.group(4) != '-': | |
104 | irq.scheduling_priority = int(match_obj.group(4)) | |
105 | else: | |
106 | irq.scheduling_priority = None | |
107 | softIRQs[irq.name] = irq | |
108 | ||
109 | # get irq info | |
110 | (exitstatus, outtext) = getstatusoutput('cat /proc/interrupts') | |
111 | lines = outtext.splitlines() | |
112 | nb_cpus = len(lines[0].split()) | |
113 | str0 = "([0-9]+): +"; | |
114 | str_cpu = "([0-9]+) +" | |
115 | str1="([\w\-]+) +([\w\-, :]+)" | |
116 | ||
117 | rawstr = str0; | |
118 | for i in range(nb_cpus): | |
119 | rawstr += str_cpu | |
120 | rawstr += str1 | |
121 | compile_obj = re.compile(rawstr) | |
122 | ||
123 | for line in outtext.splitlines(): | |
124 | match_obj = compile_obj.search(line) | |
125 | if match_obj: | |
126 | irq_number = int(match_obj.group(1)) | |
127 | if not irq_number in IRQs.keys(): | |
128 | IRQs[irq_number] = IRQ() | |
129 | IRQs[irq_number].number = irq_number | |
130 | ||
131 | irq = IRQs[irq_number] | |
132 | cpu_counts = [] | |
133 | for i in range(nb_cpus): | |
134 | cpu_counts.append(int(match_obj.group(i + 2))) | |
135 | irq.cpu_counts = cpu_counts | |
136 | irq.type = match_obj.group(nb_cpus + 2) | |
137 | drivers = match_obj.group(nb_cpus + 3).split(',') | |
138 | for driver in drivers: | |
139 | irq.drivers.append(driver.strip()) | |
140 | ||
141 | IRQs[irq.number] = irq | |
142 | ||
143 | self.softIRQs = softIRQs | |
144 | self.IRQs = IRQs | |
145 | ||
146 | def __str__(self): | |
147 | s = "" | |
148 | s += "Hardware Interrupts:\n" | |
149 | s += "--------------------\n" | |
150 | ||
151 | for irq in sortedDictValues(self.IRQs): | |
152 | s += str(irq) + "\n" | |
153 | ||
154 | s += "\n" | |
155 | s += "Software Interrupts:\n" | |
156 | s += "--------------------\n" | |
157 | for irq in sortedDictValues(self.softIRQs): | |
158 | s += str(irq) + "\n" | |
159 | ||
160 | return s | |
161 | ||
162 | if __name__== '__main__': | |
163 | ||
164 | print( "" ) | |
165 | print( "Interrupt list utility " + LISTIRQINFO_VERSION ) | |
166 | print( "==========================" ) | |
167 | print( "(C) 2008 Pieter Palmers" ) | |
168 | print( "" ) | |
169 | ||
170 | info = IRQInfo() | |
171 | ||
172 | info.load() | |
173 | print( str(info) ) | |
174 | ||
175 | print( "" ) |
0 | <?xml version="1.0" encoding="UTF-8"?> | |
1 | <!-- Copyright (C) 2006-2018 FFADO development team --> | |
2 | <component type="desktop"> | |
3 | <id>ffado.org-ffadomixer.desktop</id> | |
4 | <metadata_license>CC0-1.0</metadata_license> | |
5 | <project_license>GPL-2.0 OR GPL-3.0</project_license> | |
6 | <name>ffado-mixer</name> | |
7 | <summary>A graphical front-end for the FFADO mixer DBus controls exposed by ffado-dbus-server</summary> | |
8 | <translation/> | |
9 | <description> | |
10 | <p> | |
11 | ffado-mixer presents a graphical application allowing a firewire audio interface to be controlled. | |
12 | The extent of the control is determined by the level of support for the | |
13 | device in FFADO and in ffado-dbus-server. | |
14 | Typical controls offered by ffado-mixer include faders for the on-board mixer, | |
15 | phantom power control, mode switches and so on. | |
16 | </p> | |
17 | </description> | |
18 | <screenshots> | |
19 | <screenshot type="default"> | |
20 | <image>http://ffado.org/appdata/ffado-mixer-screenshot.png</image> | |
21 | <caption>Example of main ffado-mixer window.</caption> | |
22 | </screenshot> | |
23 | </screenshots> | |
24 | ||
25 | <url type="homepage">http://ffado.org/</url> | |
26 | <update_contact>ffado-devel@lists.sourceforge.net</update_contact> | |
27 | </component> |
11 | 11 | Icon=hi64-apps-ffado |
12 | 12 | Type=Application |
13 | 13 | Categories=Mixer;Audio;AudioVideo;HardwareSettings;Qt; |
14 | Keywords=Firewire;Sound Interface; |
27 | 27 | env.MergeFlags( "-I#/ -I#/src -L%ssrc -lffado" % env['build_base'] ) |
28 | 28 | |
29 | 29 | if not env.GetOption( "clean" ): |
30 | env.MergeFlags( "-lpthread" ) | |
31 | env.MergeFlags( env['LIBIEC61883_FLAGS'].decode() ) | |
32 | env.MergeFlags( env['LIBRAW1394_FLAGS'].decode() ) | |
33 | if not env['SERIALIZE_USE_EXPAT']: | |
34 | if 'LIBXML30_FLAGS' in env : | |
35 | env.MergeFlags( env['LIBXML30_FLAGS'].decode() ) | |
36 | if not('LIBXML30_FLAGS' in env) : | |
37 | env.MergeFlags( env['LIBXML26_FLAGS'].decode() ) | |
38 | else: | |
39 | env.PrependUnique( LIBS=["expat"] ) | |
30 | env.MergeFlags( "-lpthread" ) | |
31 | env.MergeFlags( env['LIBIEC61883_FLAGS'].decode() ) | |
32 | env.MergeFlags( env['LIBRAW1394_FLAGS'].decode() ) | |
33 | if not env['SERIALIZE_USE_EXPAT']: | |
34 | if 'LIBXML30_FLAGS' in env : | |
35 | env.MergeFlags( env['LIBXML30_FLAGS'].decode() ) | |
36 | if not('LIBXML30_FLAGS' in env) : | |
37 | env.MergeFlags( env['LIBXML26_FLAGS'].decode() ) | |
38 | else: | |
39 | env.PrependUnique( LIBS=["expat"] ) | |
40 | 40 | |
41 | 41 | static_env = env.Clone() |
42 | 42 | |
45 | 45 | # test-mixer, test-volume |
46 | 46 | # |
47 | 47 | apps = { |
48 | "ffado-test" : "test-ffado.cpp", | |
49 | "test-fw410" : "test-fw410.cpp", | |
50 | #"test-extplugcmd" : "test-extplugcmd.cpp", | |
51 | #"test-mixer" : "test-mixer.cpp", | |
52 | "test-timestampedbuffer" : "test-timestampedbuffer.cpp", | |
53 | "test-ieee1394service" : "test-ieee1394service.cpp", | |
54 | "test-streamdump" : "test-streamdump.cpp", | |
55 | "test-bufferops" : "test-bufferops.cpp", | |
56 | "test-watchdog" : "test-watchdog.cpp", | |
57 | "test-messagequeue" : "test-messagequeue.cpp", | |
58 | "test-shm" : "test-shm.cpp", | |
59 | "test-ipcringbuffer" : "test-ipcringbuffer.cpp", | |
60 | "test-devicestringparser" : "test-devicestringparser.cpp", | |
61 | "dumpiso_mod" : "dumpiso_mod.cpp", | |
62 | "scan-devreg" : "scan-devreg.cpp", | |
63 | "test-cycle-time" : "test-cycle-time.c" | |
48 | "ffado-test" : "test-ffado.cpp", | |
49 | "test-fw410" : "test-fw410.cpp", | |
50 | #"test-extplugcmd" : "test-extplugcmd.cpp", | |
51 | #"test-mixer" : "test-mixer.cpp", | |
52 | "test-timestampedbuffer" : "test-timestampedbuffer.cpp", | |
53 | "test-ieee1394service" : "test-ieee1394service.cpp", | |
54 | "test-streamdump" : "test-streamdump.cpp", | |
55 | "test-bufferops" : "test-bufferops.cpp", | |
56 | "test-watchdog" : "test-watchdog.cpp", | |
57 | "test-messagequeue" : "test-messagequeue.cpp", | |
58 | "test-shm" : "test-shm.cpp", | |
59 | "test-ipcringbuffer" : "test-ipcringbuffer.cpp", | |
60 | "test-devicestringparser" : "test-devicestringparser.cpp", | |
61 | "dumpiso_mod" : "dumpiso_mod.cpp", | |
62 | "scan-devreg" : "scan-devreg.cpp", | |
63 | "test-cycle-time" : "test-cycle-time.c" | |
64 | 64 | } |
65 | 65 | |
66 | 66 | if env['ENABLE_BEBOB']: |
67 | apps.update( { "test-focusrite" : "test-focusrite.cpp" } ) | |
67 | apps.update( { "test-focusrite" : "test-focusrite.cpp" } ) | |
68 | 68 | if env['ENABLE_GENERICAVC']: |
69 | if 'ALSA_FLAGS' in env and env["ALSA_FLAGS"]: | |
70 | env.MergeFlags( env["ALSA_FLAGS"].decode() ) | |
71 | apps.update( { "test-scs" : "test-scs.cpp" } ) | |
72 | apps.update( { "test-volume" : "test-volume.cpp" } ) | |
73 | apps.update( { "test-enhanced-mixer" : "test-enhanced-mixer.cpp" } ) | |
74 | # MB: utility to unmute M-Audio Ozonic | |
75 | apps.update( { "unmute-ozonic" : "unmute-ozonic.cpp" } ) | |
76 | apps.update( { "test-avccmd" : "test-avccmd.cpp" } ) | |
69 | if 'ALSA_FLAGS' in env and env["ALSA_FLAGS"]: | |
70 | env.MergeFlags( env["ALSA_FLAGS"].decode() ) | |
71 | apps.update( { "test-scs" : "test-scs.cpp" } ) | |
72 | apps.update( { "test-volume" : "test-volume.cpp" } ) | |
73 | apps.update( { "test-enhanced-mixer" : "test-enhanced-mixer.cpp" } ) | |
74 | # MB: utility to unmute M-Audio Ozonic | |
75 | apps.update( { "unmute-ozonic" : "unmute-ozonic.cpp" } ) | |
76 | apps.update( { "test-avccmd" : "test-avccmd.cpp" } ) | |
77 | 77 | if env['ENABLE_FIREWORKS']: |
78 | apps.update( { "test-echomixer" : "test-echomixer.cpp" } ) | |
78 | apps.update( { "test-echomixer" : "test-echomixer.cpp" } ) | |
79 | 79 | if env['ENABLE_DICE']: |
80 | apps.update( { "test-dice-eap" : "test-dice-eap.cpp" } ) | |
81 | apps.update( { "set-default-router-config-dice-eap" : "set-default-router-config-dice-eap.cpp" } ) | |
80 | apps.update( { "test-dice-eap" : "test-dice-eap.cpp" } ) | |
81 | apps.update( { "set-default-router-config-dice-eap" : "set-default-router-config-dice-eap.cpp" } ) | |
82 | 82 | |
83 | 83 | for app in apps.keys(): |
84 | env.Program( target=app, source = env.Split( apps[app] ) ) | |
85 | env.Install( "$bindir", app ) | |
84 | env.Program( target=app, source = env.Split( apps[app] ) ) | |
85 | env.Install( "$bindir", app ) | |
86 | 86 | |
87 | 87 | env.SConscript( dirs=["streaming", "systemtests"], exports="env" ) |
88 | 88 |
30 | 30 | |
31 | 31 | |
32 | 32 | apps = { |
33 | "ffado-test-streaming" : "teststreaming3.cpp", | |
34 | "ffado-test-streaming-ipc" : "teststreaming-ipc.cpp", | |
35 | "ffado-test-streaming-ipcclient" : "test-ipcclient.cpp", | |
33 | "ffado-test-streaming" : "teststreaming3.cpp", | |
34 | "ffado-test-streaming-ipc" : "teststreaming-ipc.cpp", | |
35 | "ffado-test-streaming-ipcclient" : "test-ipcclient.cpp", | |
36 | 36 | } |
37 | 37 | |
38 | 38 | for app in apps.keys(): |
39 | env.Program( target=app, source = env.Split( apps[app] ) ) | |
40 | env.Install( "$bindir", app ) | |
41 | ||
39 | env.Program( target=app, source = env.Split( apps[app] ) ) | |
40 | env.Install( "$bindir", app ) |
29 | 29 | env.PrependUnique( LIBS=["ffado"] ) |
30 | 30 | |
31 | 31 | if not env.GetOption( "clean" ): |
32 | env.MergeFlags( env['LIBRAW1394_FLAGS'].decode() ) | |
33 | env.MergeFlags( "-lrt -lpthread" ) | |
32 | env.MergeFlags( env['LIBRAW1394_FLAGS'].decode() ) | |
33 | env.MergeFlags( "-lrt -lpthread" ) | |
34 | 34 | |
35 | 35 | static_env = env.Clone() |
36 | 36 | |
39 | 39 | # test-mixer, test-volume |
40 | 40 | # |
41 | 41 | apps = { |
42 | "ffado-test-isorecv" : ["test-isorecv-1.cpp", "realtimetools.cpp"], | |
43 | "ffado-test-isoxmit" : ["test-isoxmit-1.cpp", "realtimetools.cpp"], | |
44 | "test-sysload" : ["test-sysload.cpp", "realtimetools.cpp"], | |
45 | "gen-loadpulses" : ["gen-loadpulses.cpp", "realtimetools.cpp"], | |
46 | "test-clock_nanosleep" : ["test-clock_nanosleep.cpp", "realtimetools.cpp"], | |
42 | "ffado-test-isorecv" : ["test-isorecv-1.cpp", "realtimetools.cpp"], | |
43 | "ffado-test-isoxmit" : ["test-isoxmit-1.cpp", "realtimetools.cpp"], | |
44 | "test-sysload" : ["test-sysload.cpp", "realtimetools.cpp"], | |
45 | "gen-loadpulses" : ["gen-loadpulses.cpp", "realtimetools.cpp"], | |
46 | "test-clock_nanosleep" : ["test-clock_nanosleep.cpp", "realtimetools.cpp"], | |
47 | 47 | } |
48 | 48 | |
49 | 49 | for app in apps.keys(): |
50 | env.Program( target=app, source = env.Split( apps[app] ) ) | |
51 | env.Install( "$bindir", app ) | |
52 | ||
50 | env.Program( target=app, source = env.Split( apps[app] ) ) | |
51 | env.Install( "$bindir", app ) |
27 | 27 | |
28 | 28 | #include "libieee1394/ieee1394service.h" |
29 | 29 | #include <string.h> |
30 | #include <cerrno.h> | |
30 | 31 | |
31 | 32 | DECLARE_GLOBAL_DEBUG_MODULE; |
32 | 33 | |
226 | 227 | exit(0); |
227 | 228 | } |
228 | 229 | |
229 | int errno = 0; | |
230 | errno = 0; | |
230 | 231 | char* tail; |
231 | 232 | int port = strtol( argv[1], &tail, 0 ); |
232 | 233 | int node_id = strtol( argv[2], &tail, 0 ); |
25 | 25 | #include "libutil/cmd_serialize.h" |
26 | 26 | |
27 | 27 | #include "libieee1394/ieee1394service.h" |
28 | #include <cerrno> | |
28 | 29 | |
29 | 30 | const bool bVerbose = false; |
30 | 31 | |
130 | 131 | exit(0); |
131 | 132 | } |
132 | 133 | |
133 | int errno = 0; | |
134 | errno = 0; | |
134 | 135 | char* tail; |
135 | 136 | int node_id = strtol( argv[1], &tail, 0 ); |
136 | 137 | int fb_id = strtol( argv[2], &tail, 0 ); |
11 | 11 | #define PACKAGE_NAME "$PACKAGE" |
12 | 12 | |
13 | 13 | /* Define to the full name and version of this package. */ |
14 | #define PACKAGE_STRING "$PACKAGE $VERSION-$REVISION" | |
14 | #define PACKAGE_STRING "$PACKAGE $VERSION$REVISIONSTRING" | |
15 | 15 | |
16 | 16 | /* Define to the one symbol short name of this package. */ |
17 | 17 | #define PACKAGE_TARNAME "$PACKAGE" |
18 | 18 | |
19 | 19 | /* Define to the version of this package. */ |
20 | #define PACKAGE_VERSION "$VERSION-$REVISION" | |
20 | #define PACKAGE_VERSION "$VERSION$REVISIONSTRING" | |
21 | 21 | |
22 | 22 | /* Define to the version of the cace. */ |
23 | #define CACHE_VERSION "$VERSION-$REVISION" | |
23 | #define CACHE_VERSION "$VERSION$REVISIONSTRING" | |
24 | 24 | |
25 | 25 | /* Define to the api version */ |
26 | 26 | #define FFADO_API_VERSION $FFADO_API_VERSION |