Age | Commit message (Collapse) | Author | Files | Lines |
|
Make schroot depend on sbuild to avoid breaking parallel builds.
|
|
|
|
Rename from fs_union to union.
Make configuration options more user friendly.
Update documentation to be more clear.
|
|
|
|
By default, do not build documentation unless --enable-doxygen is used.
Do not distribute doxygen documentation.
|
|
|
|
* bin/schroot/schroot.1.in, bin/schroot/schroot.conf.5.in,
bin/schroot/schroot-setup.5.in: Update copyright, hyphenation and
references.
* doc/Makefile.am (PS_DEPS): Add schroot-script-config.5.
* bin/schroot/Makefile.am (man_MANS): Add schroot-script-config.5.
* configure.ac: Add bin/schroot/schroot-script-config.5
* bin/schroot/schroot-script-config.5.in: New manual page to
document file format of script-config option.
|
|
|
|
|
|
* The entire schroot project is now licensed under the GNU General
Public Licence, version 3 or later.
* COPYING: Update to GPLv3.
* Update licence boilerplate on all files to GPLv3.
|
|
* doc/Makefile.am: Generate sbuild documentation. Fix PS_DEPS for
new manual page locations.
* doc/schroot.dox.in: Remove sbuild input files, and use sbuild
tag file.
* doc/sbuild.dox.in: Split libsbuild API reference from
schroot.dox.in.
|
|
* Move bin/schroot/schroot-listmounts* to
bin/schroot-listmounts.
* Move bin/schroot/schroot-releaselock* to
bin/schroot-releaselock.
|
|
* Update copyright headers on files for 2007.
|
|
bin/schroot/Makefile.am.
* configure.ac: Add bin/schroot-base/Makefile.
* Move bin/schroot/schroot-base-* to bin/schroot-base. Update all
dependent files to use the new path.
|
|
subdirectory, bin.
* bin/*/Makefile.am (LOCAL_CXXFLAGS): Add -I$(top_srcdir)/bin.
* bin/Makefile.am: New file.
(SUBDIRS): schroot dchroot dchroot-dsa csbuild
* configure.ac: Use new file locations.
* doc/schroot.dox.in: Use new source locations. Disable call
graph.
|
|
* Makefile.am: Add csbuild to SUBDIRS.
* configure.ac: Add enable check and support for csbuild.
* csbuild/csbuild-session-base.cc, csbuild/csbuild-options.cc,
csbuild/csbuild-main-base.cc, csbuild/csbuild-options.h,
csbuild/csbuild-session-base.h, csbuild/csbuild-main-base.h,
csbuild/csbuild.1.in, csbuild/Makefile.am, csbuild/csbuild.cc,
csbuild/csbuild-main.cc, csbuild/csbuild-main.h: New files.
Initial C++ implementation of sbuild; infrastructure classes
copied from dchroot.
|
|
* sbuild/sbuild-lock.h: Add missing virtual specifier from virtual
methods in derived lock classes.
* sbuild/sbuild-session.cc: Remove use of excess braces when
throwing exceptions.
(get_shell): Use log_exception_warning.
* Remove incorrect and misplaced comments.
* Update translator comments.
* Update API reference to document all missing and incomplete
documentation.
|
|
* Makefile.am: Add ps and pdf phony targets.
* doc/Makefile.am: Add rules to make PS and PDF manuals.
|
|
* scripts/global.mk: New file. Global Makefile options.
|
|
updating the doxygen config file.
|
|
into a dchroot subdirectory and dchroot-dsa sources into a
dchroot-dsa subdirectory.
|
|
|
|
pathnames, use built-in STL support, and sort classes by
namespace.
|
|
* test/sbuild-chroot-lvm-snapshot.cc: New file. Tests for
ChrootLvmSnapshot.
* test/sbuild-chroot-block-device.cc: New file. Tests for
ChrootBlockDevice.
* test/sbuild-chroot-plain.cc: New file. Tests for ChrootPlain.
* test/test-sbuild-chroot.h: New file. Base class for all chroot
tests.
* test/test-helpers.h (test_list): New file of test helper
functions. The initial function is a templated test for testing
string_list getters and setters.
* test/Makefile.am (noinst_LTLIBRARIES): Add libtest.la, a generic
test library that contains the generic test runner and links with
CppUnit.
* schroot/sbuild-keyfile.h: Remove parse_value.
* schroot/sbuild-environment.h (get): Use parse_value to parse
values.
* schroot/sbuild-parse-value.(cc|h): New files. Split value
parsing out from sbuild-keyfile to allow reuse.
|
|
when not in maintainer mode.
* configure.ac: Enable maintainer mode.
|
|
* schroot/Makefile.am: Generate a sbuild.gch precompiled header,
and include sbuild.h in all sources which previously included an
sbuild header. This should improve compilation speed.
* Rename schroot.h to sbuild.h, and include all sbuild-*.h
headers.
* schroot/sbuild-auth.cc (run): Fix casting to "const void **".
|
|
(PROJECT_NUMBER): Use @VERSION@.
(WARN_LOGFILE): Log to schroot.log.
|
|
|
|
distribute the doxygen-generated documentation.
|
|
Implementations of pure virtual functions are not documented (a
doxygen bug, Debian bug #324117).
|
|
move it from the sources into the headers.
|
|
|
|
template helper class to simplify streaming outout of chroot
details. Used by all derived chroot classes.
* All Glib string functions have been replaced with the C++ or C99
equivalent.
* All uses of g_return[_val]_if_fail have been replaced with
conditionals or static assertions.
* All Glib logging and message functions have been replaced with
the new logging functions and standard C++ streams.
* All Glib types have been completely removed, with the exception
of one instance of GError, and two uses of GOption.
* Support for gtk-doc has been disabled and partially removed.
* The dependency upon libsigc++ has been removed. Virtual
functions are used instead, which will provide more safety and
security.
* schroot/sbuild-keyfile.(cc|h): New class sbuild::keyfile, a
replacement for GKeyFile. Unlike GKeyFile, it uses templated
methods to allow its use with any streamable type, in a type-safe
manner. The existing GKeyFile helper functions have been removed.
* schroot/sbuild-log.(cc|h): New file: logging functions to
replace the Glib print and logging utility functions. Unlike the
Glib types, these are based around ostreams.
* schroot/sbuild-nostream.(cc|h): New class sbuild::basic_nostream
with nostream and wnostream typedefs. This is a "null ostream",
which is a bit-bucket stream which discards all input.
* schroot/sbuild-types.h: New file: commonly-used types.
* Continue purge of Glib.
|
|
(main): Delegate the decision about which chroot configuration
files to load to schroot_options_parse. Use
sbuild_config_print_chroot_info to print chroot information.
* schroot/schroot-options.h
(struct _SchrootOptions): Add load_chroots and load_sessions
members.
* schroot/schroot-options.c
(schroot_options_parse): Determine which chroot configuration
files to load more accurately.
* schroot/sbuild-config.c
(sbuild_config_print_chroot_info): New function, split out from
main() in schroot.c.
|
|
* schroot/schroot.c: Update to use the new SchrootOptions option
parsing:
(get_chroot_options): An SchrootOptions struct is passed as an
argument, since the options are no longer global.
(main): Create and free an SchrootOptions struct.
* schroot/schroot-options.[ch]: New files. The command-line
option parsing has been split out of schroot.c, with an new
SchrootOptions struct to contain the parsed options.
|
|
* schroot/setup/*: Add support to setup scripts for
"setup-recover" option. In particular, filesystems are all
remounted, and all "setup-start" tasks are performed, except for
snapshotting.
* schroot/schroot.c
(parse_options): Add "--recover-session" session option.
(parse_session_options): Parse "--recover-session".
(main): Update configuration file loading to account for recovery.
* schroot/sbuild-session.c
(sbuild_session_setup_chroot): Add support for "setup-recover"
argument in scripts.
(sbuild_session_run): Add support for session recovery option.
* schroot/sbuild-session.h
(SbuildSessionOperation): Add SBUILD_SESSION_OPERATION_RECOVER.
* schroot/sbuild-chroot.h
(SbuildChrootSetupType): Add SBUILD_CHROOT_SETUP_RECOVER.
|
|
(sbuild_session_setup_chroot): Propagate GError from
sbuild_chroot_setup_lock.
* schroot/sbuild-chroot-lvm-snapshot.c
(sbuild_chroot_lvm_snapshot_setup_lock): Use GError. Refactor to
propagate GError on failure, and reduce the number of return
points.
(sbuild_chroot_lvm_snapshot_setup_session_info): New function,
split out from sbuild_chroot_lvm_snapshot_setup_lock to increase
readability.
* schroot/sbuild-chroot-block-device.c
(sbuild_chroot_block_device_setup_lock): Use GError. Refactor to
propagate GError on failure, and reduce the number of return
points.
* schroot/sbuild-chroot-plain.c
(sbuild_chroot_plain_setup_lock): Use GError.
* schroot/sbuild-chroot.c
(sbuild_chroot_error_quark): New function.
* schroot/sbuild-chroot.h
(SbuildChrootError): Add error enum.
(SbuildChrootSetupLockFunc): Add a GError.
|
|
* TODO: Update. All locking and session items removed now that
they are implemented.
* schroot/schroot.1.in: Document new "--all-chroots" and
"--all-sessions" options.
* schroot/schroot.c: Add "--all-chroots" and "--all-sessions"
command-line options.
(get_chroot_options): Use new "--all" options.
(get_chroot_options): Print a list of invalid chroots found during
chroot validation.
(main): Create the configuration using sbuild_config_new(), and
add the approprate configuration and session configuration
depending on the command-line options used.
* schroot/sbuild-session.c
(sbuild_session_run): When restoring a session, set the session ID
from the chroot name.
(sbuild_session_run): The session operations are only run if
specified in the session operations.
* schroot/sbuild-config.c
(sbuild_config_new): New function. This does not load any
configuration files.
(sbuild_config_add_config_file): New function, renamed from
sbuild_config_set_config_file. This now exported.
(sbuild_config_add_config_directory): New function, renamed from
sbuild_config_set_config_directory. This now exported.
(sbuild_config_find_generic): Cope with the case that no chroots
exist.
(sbuild_config_get_chroot_list): Cope with the case that no
chroots exist.
(sbuild_config_validate_chroots): Return a list of invalid chroot
names, rather than FALSE.
(sbuild_config_class_init): "config-file" and "config-directory"
are no longer construct-only. Both properties are now completely
virtual, with no corresponding member data (a single filename no
longer makes sense when multiple configuration files may be added
at any time).
* schroot/sbuild-config.h (struct _SbuildConfig): Removed file
member.
* schroot/sbuild-chroot.h: Fix function misordering.
* schroot/sbuild-chroot.c
(sbuild_chroot_print_config): Print "active" property, don't
translate any option names, and format "mount-device" correctly.
(sbuild_chroot_set_property): Add the PROP_ACTIVE property.
(sbuild_chroot_class_init): Make "active" a construction property;
this is not documented, as it is not intended for use by users; it
is for session recovery.
* schroot/sbuild-chroot-lvm-snapshot.c
(sbuild_chroot_lvm_snapshot_print_config): Chain up using the
print_config vfunc.
(sbuild_chroot_lvm_snapshot_setup_lock): Use
sbuild_chroot_print_config rather than
sbuild_chroot_print_details.
|
|
chroot "active" property before and after running a session.
* schroot/sbuild-config.c (sbuild_config_load): Remove active
argument from sbuild_chroot_new_from_keyfile call.
* schroot/sbuild-chroot.c
(sbuild_chroot_class_init): Make "active" property writable, and
add methods to get and set the active property.
(sbuild_chroot_new_from_keyfile): Remove active argument.
|
|
SBUILD_CHROOT_SESSION_CREATE, update the chroot name with the
session name.
* schroot/sbuild-chroot.h (SbuildChrootSessionFlags) Removed
unused session flags, and renamed SBUILD_CHROOT_SESSION_PERSISTENT
to SBUILD_CHROOT_SESSION_CREATE. All chroot types updated to
reflect the change.
|
|
* schroot/sbuild-chroot.c (sbuild_chroot_class_init): Remove the
"current-users" and "max-users" properties, and associated object
members and methods.
|
|
(sbuild_chroot_lvm_snapshot_setup_lock): The device lock is held
on the source device during snapshotting (setup start), and on the
snapshot device from run start to run stop and then during setup
stop while the chroot is destroyed.
* schroot/sbuild-chroot-block-device.c
(sbuild_chroot_block_device_setup_lock): The device lock is held
throughout the entire session. It is acquired at setup start and
released at setup stop. This uses the new sbuild-lock device
locking primitives.
* schroot/sbuild-chroot.h: SbuildChrootSetupLockFunc uses a
mutable chroot object. All implementations of the setup_lock
vfunc have been changed accordingly.
* schroot/sbuild-lock.c
(sbuild_lock_set_device_lock): New function. Lock a device using
liblockdev.
(sbuild_lock_unset_device_lock): New function. Unlock a device
using liblockdev.
|
|
locations.
* schroot/sbuild-chroot.h: Rename SBUILD_CHROOT_SETUP_START and
SBUILD_CHROOT_SETUP_STOP to SBUILD_CHROOT_RUN_START and
SBUILD_CHROOT_RUN_STOP. Users of the enum changed to use the new
names.
* session.d script "session-start" and "session-stop" script
arguments renamed to "run-start" and "run-stop". All scripts
changed to use the new names, and sbuild-session.c runs the
scripts with the new new names.
* Rename schroot/session to schroot/run. Install scripts into
$sysconfdir/schroot/run.d. Update configure.ac, and
schroot/Makefile.am.
|
|
* schroot/setup/10mount: Use new LVM variables, so snapshot names
and mount locations are as set by the session. Remove mount
directory after unmounting, but only if it's under $MOUNT_DIR.
* schroot/setup/05lvm: Use new LVM variables, so snapshot names
and mount locations are as set by the session.
* schroot/setup/00check, schroot/session/00check: Add MOUNT_DIR,
SESSION_ID, CHROOT_LVM_SNAPSHOT_NAME and
CHROOT_LVM_SNAPSHOT_DEVICE.
* schroot/schroot.c
(parse_options): Free the option context after use.
(main): If a session ID was not specified, generate a UUID for the
session.
(main): Free the chroot list to make valgrind happy.
* schroot/schroot.1.in: Document MOUNT_DIR, SESSION_ID,
CHROOT_LVM_SNAPSHOT_NAME and CHROOT_LVM_SNAPSHOT_DEVICE
environment variables.
* schroot/sbuild-session.c
(sbuild_session_get_session_id): session-id is no longer required
to be a UUID.
(sbuild_session_set_session_id): session-id is no longer required
to be a UUID. Allow setting of arbitrary strings.
(sbuild_session_setup_chroot): Export MOUNT_DIR and SESSION_ID in
the environment.
(sbuild_session_run): Set the chroot mount location if the chroot
did not already do so.
(sbuild_session_run): For LVM snapshot chroots, set the snapshot
name to the session ID.
(sbuild_session_run): Cascade error handling properly on failure.
(sbuild_session_class_init): Update session-id documentation now
it is no longer a strict UUID.
* schroot/sbuild-session.h (struct _SbuildSession): Change
session_id type from uuid_t to gchar *.
* schroot/sbuild-config.c (sbuild_config_load): Free GIOChannel,
file data buffer and GKeyFile structure after use.
* schroot/sbuild-chroot-lvm-snapshot.c
(sbuild_chroot_lvm_snapshot_print_config): Don't print NULL
values.
(sbuild_chroot_lvm_snapshot_setup): Don't set NULL values. Set
snapshot device name (path stripped) as CHROOT_LVM_SNAPSHOT_NAME.
(sbuild_chroot_lvm_snapshot_get_setup_name): Implement
get_setup_name vfunc. This is of the form block-major-minor,
obtained by stat()ing the block device. For setup-start, this is
the source LV, but for all other cases is the snapshot LV.
(sbuild_chroot_lvm_snapshot_class_init): Added new
"snapshot-device" property. The "device" property is slaved to
this value, and indirectly, the "device" property is also slaved.
* schroot/sbuild-chroot-lvm-snapshot.h (struct
_SbuildChrootLvmSnapshot): New snapshot_device member.
* schroot/sbuild-chroot-block-device.c
(sbuild_chroot_block_device_print_details): Don't print NULL
values.
(sbuild_chroot_block_device_print_config): Don't print NULL
values.
(sbuild_chroot_block_device_setup): Don't set NULL values.
(sbuild_chroot_block_device_get_setup_name): Implement
get_setup_name vfunc. This is of the form block-major-minor,
obtained by stat()ing the block device.
* schroot/sbuild-chroot-plain.c
(sbuild_chroot_plain_print_details): Don't print NULL values.
(sbuild_chroot_plain_print_config): Don't print NULL values.
(sbuild_chroot_plain_setup): Don't set NULL values.
(sbuild_chroot_plain_get_setup_name): Implement get_setup_name
vfunc. This is of the form directory-major-minor-inode, obtained
by stat()ing the mount location.
* schroot/sbuild-chroot.c
(sbuild_chroot_set_properties_from_keyfile): Don't leak GKeyFile
string and string vector values.
(sbuild_chroot_get_setup_name): New function. Get the name for
e.g. locking during setup.
(sbuild_chroot_print_details): Don't print NULL values.
(sbuild_chroot_print_config): Don't print NULL values.
(setup_env_string): New helper function to build environment list.
(setup_env_unsigned): New helper function to build environment list.
* schroot/sbuild-chroot.h (struct _SbuildChrootClass): Add
get_setup_name vfunc.
* schroot/sbuild-auth.c (sbuild_auth_setupenv): Don't leak new
environment.
* schroot/Makefile.am (install-data-hook): Create mount directory.
* configure.ac (SCHROOT_MOUNT_DIR): Add mount directory.
|
|
messages propagated by locking failure.
* schroot/sbuild-lock.c
(sbuild_lock_set_lock): Return errors as a GError, rather than
aborting. Don't run fcntl in a while loop now that timeouts are
implemented with an itimer.
(sbuild_lock_unset_lock): Return errors as a GError.
(sbuild_lock_error_quark): New function.
* schroot/sbuild-lock.h (SBUILD_LOCK_ERROR): Add error domain.
Add locking errors as SbuildLockError enum.
|
|
* schroot/sbuild-config.c (sbuild_config_load): Acquire a read
lock while reading schroot.conf.
* schroot/schroot.h: Add sbuild-lock.h.
* schroot/Makefile.am: Add sbuild-lock.[ch].
* schroot/sbuild-lock.[ch]: New file, implementing simple
whole-file advisory locking primitives.
|
|
* schroot/schroot.conf.5.in: Document run-setup-scripts and
run-session-scripts options.
* schroot/sbuild-chroot.c (sbuild_chroot_class_init): Replace
run-setup property and associated accessors with two new
properties, run-setup-scripts and run-session-scripts and
associated accessors. Setup script are not run by default,
whereas session scripts are.
* schroot/sbuild-chroot.h (struct _SbuildChroot): Replace
run_setup with two members, run_setup_scripts and
run_session_scripts.
* schroot/Makefile.am (SUBDIRS): Add session.
* schroot/session/00check: New session script.
* schroot/session/Makefile.am: New file for installing session
scripts.
* configure.ac (SCHROOT_CONF_SETUP_D): New define and substitution
variable.
|
|
* schroot/schroot.1.in: Document new command-line options.
* schroot/schroot.c: Add new session_opt struct, with operation,
id and force members.
(parse_options): Add new command line options: -b/--begin-session,
-r/--run-session, -e/--end-session and --force in a new "session"
option group. These options do not currently have any effect.
(parse_session_options): New helper function to parse session
options.
(main): Set session operation when creating a new session. Set
additional session properties (session-id, force) after
construction.
* schroot/sbuild-session.c (sbuild_session_class_init): Added new
"operation" and "force" properties, and associated accessors.
(sbuild_session_new): Add operation argument, and set the
operation contruction property.
* schroot/sbuild-session.h: Added SbuildSessionOperation enum to
specify session operations.
(struct _SbuildSession): Added new operation and force members.
* schroot/sbuild-chroot-lvm-snapshot.c
(sbuild_chroot_lvm_snapshot_get_session_flags): New virtual
function to get session flags.
* schroot/sbuild-chroot-block-device.c
(sbuild_chroot_block_device_get_session_flags): New virtual
function to get session flags.
* schroot/sbuild-chroot-plain.c
(sbuild_chroot_plain_get_session_flags): New virtual function to
get session flags.
* schroot/sbuild-chroot.c
(sbuild_chroot_get_session_flags): New function. Calls
get_session_flags vfunc.
(sbuild_chroot_class_init): get_session_flags is pure virtual, so
must be implemented in derived classes.
* schroot/sbuild-chroot.h: Add SbuildChrootSessionFlags enum to
specify chroot session behaviour.
(struct _SbuildChrootClass): Added get_session_flags vfunc.
|
|
changes for Debian Bug #329403.
* schroot/schroot.conf.5.in: Document "run-setup" configuration
option.
* schroot/sbuild-session.c (sbuild_session_run): Only run setup
scripts if enabled in the chroot configuration.
* schroot/sbuild-chroot.c
(sbuild_chroot_class_init): Add "run-setup" property, and
associated accessors.
(sbuild_chroot_new_from_keyfile): Add support for G_TYPE_BOOLEAN
properties as configuration options.
* schroot/sbuild-chroot.h (struct _SbuildChroot): Add run_setup
member.
|
|
session-id property and associated accessors, which handle
conversions between a string and uuid_t.
* schroot/sbuild-session.h (struct _SbuildSession): Add a new
session_id member containing the session UUID.
* schroot/sbuild-config.c
(sbuild_config_new_from_file): New function to replace
sbuild_config_new.
(sbuild_config_new_from_directory): New function to load a set of
configuration files from a directory.
(sbuild_config_class_init): config-file property is no longer
readable. Added new contruct only and write-only config-directory
property.
(sbuild_config_set_config_directory): New function to read a
directory and load config files.
(sbuild_config_load): Pass back the chroot list as an OUT
parameter rather than a return value, to allow reusing the same
list.
(sbuild_config_set_config_file): Remove the restriction on loading
a single config file.
* schroot/sbuild-chroot-lvm-snapshot.c
(sbuild_chroot_lvm_snapshot_print_config): New virtual function to
print additional configuration details.
* schroot/sbuild-chroot-block-device.c
(sbuild_chroot_block_device_print_config): New virtual function to
print additional configuration details.
* schroot/sbuild-chroot-plain.c
(sbuild_chroot_plain_print_config): New virtual function to print
additional configuration details.
* schroot/sbuild-chroot.c
(sbuild_chroot_class_init): Added current-users, max-users and
active properties, and associated accessors.
(sbuild_chroot_new_from_keyfile): Add additional active parameter
which is TRUE if reloading an existing session configuration.
This relaxes permissions checks to allow setting of writable but
not construction parameters.
(sbuild_chroot_print_details): Print new properties.
(sbuild_chroot_print_config): New function to write out current
session state to a a configuration file for later restoration.
(sbuild_chroot_setup): Set new properties as environment
variables, except for active, since this is implicit in running a
session).
* schroot/sbuild-chroot.h
(struct _SbuildChroot): Add current_users, max_users and active
members.
(struct _SbuildChrootClass): Add print_config vfunc.
* debian/control (Build-Depends): Build-depend upon uuid-dev
* schroot/Makefile.am
(schroot_LDADD): Link with libuuid.
(install-data-hook): Make SCHROOT_LOCK_DIR and
SCHROOT_SESSION_DIR.
* configure.ac:
Check for libuuid and add UUID_CFLAGS to SCHROOT_CFLAGS.
Add substitutions and defines for SCHROOT_LOCK_DIR and
SCHROOT_SESSION_DIR.
|