Thanks for the helpful meeting guys. > reglookup will be updated by Christophe Monniez > - Adian will update reglookup trunk with build changes > submitted by Adam Golebiowski of PLD Linux > - Mika will help in packaging (scons & CO)
I've attached a patch of my changes to the base SConstruct file. It does 3 things: - Adds some link flags and sets the regfi library soname - Adds environment variables to set various installation paths, including a fake root path - Only executes ldconfig if the install runs as uid 0 Hopefully that will address some of the issues you've had in previous attempts to package the newer reglookup versions. I also wanted to mention that pyregfi supports both python 2.7+ and python 3. I don't know what the normal way to package libraries that do this. Clearly the combinations of dependencies and build order can be complex, so it may require two separate packages (or virtual packages?), one for each version, so that downstream applications can depend on the version of the library they want without pulling in a version of Python that they don't. It might be helpful to schedule another IRC chat session for a time when you guys plan on working on the reglookup packaging so I can be immediately available to help out. Thanks! tim
Index: SConstruct =================================================================== --- SConstruct (revision 276) +++ SConstruct (revision 278) @@ -23,7 +23,8 @@ # Libraries libregfi_static = env.Library(lib_src) -libregfi = env.SharedLibrary(lib_src, LIBS=['m','pthread', 'talloc']) +libregfi = env.SharedLibrary(lib_src, LIBS=['m','pthread', 'talloc'], + LINKFLAGS="-shared -fPIC -Wl,-soname,libregfi.so.%s" % REGFI_VERSION) # Executables @@ -45,28 +46,33 @@ man_reglookup_timeline = env.ManPage('doc/reglookup-timeline.1.docbook') # Installation -prefix='/usr/local/' -if 'PREFIX' in os.environ: - prefix = os.environ['PREFIX']+'/' +prefix = os.environ.get('PREFIX','/usr/local')+'/' +destdir = os.environ.get('DESTDIR','') +bindir = os.environ.get('BINDIR', prefix + 'bin') +libdir = os.environ.get('LIBDIR', prefix + 'lib') +includedir = os.environ.get('INCLUDEDIR', prefix + 'include') +mandir = os.environ.get('MANDIR', prefix + 'man') -install_items = [prefix+'bin', - prefix+'lib', - prefix+'include/regfi', - prefix+'man'] +install_items = [destdir + bindir, + destdir + libdir, + destdir + includedir + '/regfi', + destdir + mandir] -env.Install(prefix+'bin', [reglookup, reglookup_recover, 'bin/reglookup-timeline']) -libinstall = env.Install(prefix+'lib', [libregfi, libregfi_static]) -env.Install(prefix+'include/regfi', Glob('include/*.h')) -env.Install(prefix+'man/man1', [man_reglookup, man_reglookup_recover, - man_reglookup_timeline]) -env.AddPostAction(libinstall, 'ldconfig') +env.Install(destdir+bindir, [reglookup, reglookup_recover, 'bin/reglookup-timeline']) +libinstall = env.Install(destdir+libdir, [libregfi, libregfi_static]) +env.Install(destdir+includedir+'/regfi', Glob('include/*.h')) +env.Install(destdir+mandir+'/man1', [man_reglookup, man_reglookup_recover, + man_reglookup_timeline]) +if os.getuid() == 0: + env.AddPostAction(libinstall, 'ldconfig') + if sys.version_info[0] == 2: install_items.append('pyregfi2-install.log') env.Command('pyregfi2-install.log', ['python/pyregfi/__init__.py', 'python/pyregfi/structures.py', 'python/pyregfi/winsec.py'], - "python pyregfi-distutils.py install | tee pyregfi2-install.log") + "python pyregfi-distutils.py install --root=/%s | tee pyregfi2-install.log" % destdir) python_path = os.popen('which python3').read() if python_path != '': @@ -74,7 +80,7 @@ env.Command('pyregfi3-install.log', ['python/pyregfi/__init__.py', 'python/pyregfi/structures.py', 'python/pyregfi/winsec.py'], - "python3 pyregfi-distutils.py install | tee pyregfi3-install.log") + "python3 pyregfi-distutils.py install --root=/%s | tee pyregfi3-install.log" % destdir) # API documentation regfi_doc = env.Command('doc/devel/regfi/index.html',
_______________________________________________ forensics-devel mailing list forensics-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/forensics-devel