Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 914968

Summary: app-admin/syslog-ng-4.2.0 - does not byte compile python modules
Product: Gentoo Linux Reporter: Daniel Pielmeier <billie>
Component: Current packagesAssignee: Tomáš Mózes <hydrapolic>
Status: CONFIRMED ---    
Severity: normal CC: proxy-maint
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Daniel Pielmeier gentoo-dev 2023-09-30 10:12:41 UTC
syslog-ng python modules are byte compiled at runtime and thus outside of the control of the package manager and will remain as cruft after removing syslog-ng.

E.g. python modules in this directories will be byte compiled when fist running syslog-ng:
/usr/lib64/syslog-ng/python/syslogng
/usr/lib64/syslog-ng/python/syslogng/modules/hypr

There are more python modules around but maybe they are not used.

The ebuild calls python_optimize [1] to byte compile modules. This however only works if the modules are installed to standard locations. If this is not the case the paths to the modules have to be specified. 

python_optimize "${ED}"/usr/lib64/syslog-ng/python

[1] https://projects.gentoo.org/python/guide/helper.html#byte-compiling-python-modules