| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
This helps refactoring morph to get rid of treeishes.
|
|
|
|
|
|
|
|
| |
When making a copy of the repository to build from, builder copies the
.git directory then checks out the ref it wants.
However sometimes this doesn't add the files to the working directory,
possibly because the files it is missing weren't changed in the difference
between what the .git thought HEAD was and what is now checked out.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
I found the write_cache_metadata and prepare_binary_metadata methods
be confusingly similar, when skimming code. Since write_cache_metadata
was very short and only used from one place, inlined it, which removes
the confusion without, I think, adding complexity.
|
|
|
|
|
|
|
|
| |
The --target-cflags option is really just a temporary solution. At some
point we will want to have a proper target architecture/device
description that morph uses to define compiler flags etc.
For now, I hope this will do.
|
| |
|
| |
|
|
|
|
|
| |
The system images will later need to be read, so useful commands
want to be shared
|
|
|
|
| |
It only needs a morph, not a blob
|
|
|
|
|
| |
This is achieved by copying vmlinuz, System.map and extlinux.conf
to the default subvolume.
|
| |
|
| |
|
|\ |
|
| |
| |
| |
| |
| |
| | |
This should stop tar from replacing symbolic links with directories
and instead follow the symbolic links, extracting the files into
the linked directories
|
| |
| |
| |
| | |
f.write does not add them
|
|\ \
| |/ |
|
| |
| |
| |
| |
| |
| |
| | |
Previously, we could get a situation where chunks named the same way
in two morphologies could interfere with each other: they could generate
the same cache key, resulting in their chunks overwriting each other.
Now this won't happen anymore.
|
| |
| |
| |
| | |
The mkimage.sh script should now be unnecessary again.
|
| | |
|
| |
| |
| |
| |
| | |
Add PREFIX to the whitelist of environment variables that
can affect the cache keys.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previous change would share the same environment between all Builders
this may not have broken anything yet, but this change in behaviour
was unintentional.
The relevant cache keys are not altered by Builders and they are set
at the time the Builder is created, so the build string can be cached
rather than generated every time a cache key is needed
|
|/
|
|
|
|
| |
env is created in Builder's constructor from app.clean_env
cache keys now contain parts of the environment that may cause
chunks to be built differently
|
|
|
|
|
|
|
|
|
| |
Use dd and sfdisk instead of qemu-img, parted and install-mbr
Write files without using tee, that was only required when we were
not expecting morph to be run as root
partx has not been touched, I don't know enough about how to process
the output in python and I don't speak awk
|
| |
|
| |
|
|
|
|
| |
We can use self.app.settings instead.
|
|
|
|
|
| |
This is better done in morph, I think, since it is clear policy,
and should not be buried deep in the call stack.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
The "cache prefix" concept is not immediately clear, and it's
generally speaking best to centralize the construction of filenames
in the cache to the CacheDir class anyway.
Also, use SaveFile for writing the log file, instead of writing it
to a temporary file and then copying, which is unnecessary I/O.
|
|
|
|
|
|
|
| |
It needs to be different for each subclass, yet SystemBuilder was
sharing the implementation with ChunkBuilder, which worked, but only
by happenstance. Now each class has their own implementation and the
base class has a NotImplemented implementation.
|
|
|
|
|
|
| |
It's not really the blob builder's job to unpack chunks, or determine
whether something needs building or not. Moved those things to better
places.
|
| |
|
|
|
|
|
|
|
|
| |
The helper class, Factory, has unit tests, which is why it's currently
separate. It may later get integrated with BlobBuilder, or the other
way around.
Classes that don't have unit tests are marked out of coverage.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Also, change builder.py to always obey the --max-jobs setting, unless
a morphology has a max-jobs field.
The defaults have been chosen so that they work for everyone equally
well. It may be useful to have a local mirror and then set the options
to point there, but it's not reasonable to try to guess such things,
so the defaults can be adapated to that.
Collect the defaults into one place so they're easier to overview.
The cliapp interface for adding settings is verbose enough that the
defaults were getting buried.
|
| |
|
|
|
|
|
| |
This avoids problems with files with the right names but partial
content, if morph is killed in the middle of writing the file.
|
|
|
|
|
|
|
|
|
|
|
|
| |
This makes it easier to check the output with vgrep for errors or
problems. Voluminous git output made that hard.
The key is that "git bundle create" has no --quiet optio (meh),
so we have to redirect stderr to /dev/null. However, that would
hide real errors, which we want to catch. Luckily, we can just
replace the call to subprocess.call with a call to
subprocess.check_call, and then we'll at least abort if there's
an error, instead of silently ignoring it.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Either all .gits need to be left alone, including submodules, or
all of them get changed.
Doing all gets surprisingly complicated, as bottom-up traversal is
needed for directories to have their mtimes set, which means that
either we check the path for a .git component, or we do our own
traversal function, to top-down exclude .git and bottom-up set
mtimes.
This is more effort than it is worth when git probably doesn't care
so let's just drop it entirely.
|