1. 23 Sep, 2019 1 commit
    • Ivan A. Melnikov's avatar
      Ensure non-zero exit code on make failure · caee317e
      Ivan A. Melnikov authored
      Before this change, we could have 0 exit code from the main
      make process even when some targets failed to build on some
      architectures:
      
      $ make ARCH=mipsel [...] vm/tavolga-regular-mate-ex.recovery.tar
      ** ARCH: mipsel
      10:15:06 cleaning up
      10:15:06 initializing BUILDDIR: build/
      10:15:06 preparing distro config: build/distcfg.mk
      make[1]: *** No rule to make target 'use/systemd-coredump', needed by 'profile/.extra'.  Stop.
      [nightly-mipsel@loongson5 mkimage-profiles]$ echo $?
      0
      
      Use `make -k' to get the old behaviour.
      caee317e
  2. 19 Aug, 2019 1 commit
  3. 02 Apr, 2015 1 commit
    • Michael Shigorin's avatar
      introduce QUIET variable · 3cb4d9ae
      Michael Shigorin authored
      This one reduces the amount of output that's only
      interesting when one is actually watching the console
      during builds (at least the early stage) -- these tend
      to look boilerplate and be useless when inspecting the
      output of a large batch build like [[regular]] one.
      3cb4d9ae
  4. 24 Jun, 2014 1 commit
    • Michael Shigorin's avatar
      added docs-publish toplevel goal · e0004a26
      Michael Shigorin authored
      This one is long overdue as I keep forgetting to update
      the published copy of generated documentation all the time.
      
      Note that you must pass DOCS_PUBLISH (as a local directory
      or host:dir suitable for rsync/ssh) via make arguments,
      environment or ~/.mkimage/profiles.mk file.
      e0004a26
  5. 05 Aug, 2013 1 commit
    • Michael Shigorin's avatar
      Makefile: fixed an interbug · 84ad4092
      Michael Shigorin authored
      This inobvious buglet has been spotted shortly after
      1.1.0 refactoring was roughly over; the problem is
      that armh-specific targets would get ignored without
      explicit ARCH=armh.
      
      It's commit 768df7e9
      which streamlined introspection within main.mk
      and a bug in Makefile which left ARCH empty
      even upon having autodetected it for ARCHES.
      
      The current version is more straightforward as a bonus.
      84ad4092
  6. 17 Jun, 2013 1 commit
  7. 19 Nov, 2012 1 commit
  8. 05 Nov, 2012 1 commit
  9. 28 Jul, 2012 1 commit
  10. 17 Jul, 2012 1 commit
  11. 16 Jul, 2012 1 commit
    • Michael Shigorin's avatar
      initial PowerPC support · 1ee997e8
      Michael Shigorin authored
      As it happens, adding another architecture required almost no changes;
      native 32-bit ppc build took only ARCH and a repo, qemu-ppc one still
      has problems (/.host/entry hangs while unpacking setup for fakedata).
      
      Proof of concept on a QS22:
      
        $ make ve/bare.tar.gz
        ** ARCH: ppc
        /bin/sh: rpmvercmp: command not found
        21:41:01 cleaning up
        21:41:03 initializing BUILDDIR: build/
        21:41:03 preparing distro config
        21:41:05 starting image build (coffee time)
        21:42:48 done (1:42)
        ** image: $TMP/out/bare-20120716-ppc.tar.gz [21M]
      1ee997e8
  12. 09 Jul, 2012 2 commits
    • Michael Shigorin's avatar
      initial native ARM support · 3c26cc86
      Michael Shigorin authored
      The only thing to be fixed was setarch(8) symlinks assumption
      that is correct for x86 but not for ARM.
      
      There's also some hasher(7) setup to be done:
      
        mkdir -p ~/.hasher
        echo >> ~/.hasher/config <<-EOF
        def_target=arm
        #cache_dir=$HOME/tmp	# depends on RAM/storage configuration
        EOF
      
      ...and of course apt(8) should be properly set up too.
      
      An example PoC build on a CM-A510 board (tmpfs):
      
        $ make BRANDING=altlinux-centaurus ve/bare.tar.gz
        ** ARCH: arm
        18:10:45 initializing BUILDDIR: build/
        18:10:45 preparing distro config: build/distcfg.mk
        18:10:46 starting image build: tail -f build/build.log
        18:14:49 done (4:02)
        ** image: $TMP/out/bare-20120706-arm.tar.gz [23M]
      3c26cc86
    • Michael Shigorin's avatar
      Makefile: drop noise when no config is found · 698c5e31
      Michael Shigorin authored
      ~/.mkimage/profiles.mk is useful but not requisite by any margin;
      no need to make noise trying to make it either.
      698c5e31
  13. 25 Jun, 2012 1 commit
    • Michael Shigorin's avatar
      initial specific VM formats support · 8a04d9b6
      Michael Shigorin authored
      Raw disk images are convenient and universal
      but there are custom formats like Qemu's qcow2
      providing additional features, e.g. copy-on-write
      or space savings.  All of this ultimately belongs
      to mkimage but in the mean time has been implemented
      here as well.
      8a04d9b6
  14. 21 May, 2012 1 commit
  15. 14 May, 2012 1 commit
  16. 06 May, 2012 1 commit
    • Michael Shigorin's avatar
      no build means *no* build (and less reports), really · 454e7162
      Michael Shigorin authored
      It's hard to tell a successful build from a failed one
      if downstream hides the exit code; it's useless to continue
      a `for' loop if a pipe shoves that to a subshell; well it seems
      that a bashism is worth a thousand quirks with extra fds here.
      Minor regexp enhancements are also due.
      
      reports.mk made a bit more resilient/prudent either.
      454e7162
  17. 24 Apr, 2012 1 commit
  18. 23 Apr, 2012 1 commit
  19. 07 Apr, 2012 1 commit
  20. 19 Mar, 2012 1 commit
  21. 16 Jan, 2012 1 commit
    • Michael Shigorin's avatar
      fix toplevel arch/distro loops · 9304c12c
      Michael Shigorin authored
      There was a somewhat subtle Makefile->main.mk rename leftover
      lurking in "everything" target: the default Makefile got used,
      not the supposed main.mk -- which resulted in an attempt to
      get way too much job done (the number of builds per target
      became $ARCH squared, not just $ARCH).
      
      Huge thanks to led@ for being an inspiring pedantic!
      9304c12c
  22. 11 Jan, 2012 1 commit
  23. 02 Jan, 2012 1 commit
    • Michael Shigorin's avatar
      main.mk introduced, lib/*.mk partially rewritten · 2f307fff
      Michael Shigorin authored
      The former toplevel Makefile is now toplevel main.mk;
      this change allows for multi-target, multi-arch processing
      in the current toplevel Makefile.
      
      As the "build" symlink semantics change quite considerably
      when one is doing bulk builds (several pruned builddirs might
      be useful for comparison), BUILDDIR is now much more likely
      to be recreated: the cases when it will persist are when it's
      either a single-image build or when the prefix hasn't changed.
      
      There are some more or less subtle bugfixes and enhancements
      all over the map as well.
      
      Done within 20111230..20120102 timeframe, actually...
      2f307fff
  24. 02 Dec, 2011 1 commit
    • Michael Shigorin's avatar
      conf/live.mk: minor refactoring · 3d982dab
      Michael Shigorin authored
      distro/live-builder target used to employ a few duplicated
      packages that might make it to a list but as the list would
      have only a single user so far these were moved to a target-
      specific variable (hm, weird but "private" modifier broke).
      3d982dab
  25. 24 Nov, 2011 2 commits
    • Michael Shigorin's avatar
      added support for cpio and xz · 7e78670e
      Michael Shigorin authored
      Actually this is the proper rewrite that was looming ever since
      tgz support was introduced: there are multiple archive formats
      supported by mkimage, and there are multiple compression methods
      available as well.
      
      So the bullet got bitten yet again along with the "goal parser"
      which should be more straightforward by now.
      
      Thanks dkr@ and mithraen@ for the inspiration of this evening.
      7e78670e
    • Michael Shigorin's avatar
      Makefile: get help back up · 041d5754
      Michael Shigorin authored
      Partially reverts "Makefile: presume a distro by default" commit:
      plain `make' should better help the user to decide the target
      rather than rush to build them all upon her.
      041d5754
  26. 21 Nov, 2011 1 commit
    • Michael Shigorin's avatar
      Makefile: presume a distro by default · 10b9e293
      Michael Shigorin authored
      When ve/ support was introduced, a simple "make icewm.iso"
      had to turn into the more elaborate "make distro/icewm.iso".
      This latter one involves several keystrokes more, which is
      not even (environ)mentally friendly.
      
      This was supposed to get fixed somewhere down the road with
      a fallback but the elegance of IMAGE_* setup waterfall barred
      me from tweaking IMAGE_TARGET at once (and the downstream fixup
      would imply re-tweaking the consequent variables as well which
      is blatantly anti-mkimage-profilic being a brute fork).
      
      OTOH testing for a "directory" part of the goal is going to
      either deadlock on IMAGE_CLASS or duplicate its assignment.
      
      So now when I've had enough typing an extra "distro/",
      I'm going to just bite the bullet and tweak IMAGE_TARGET
      with a test duplicating IMAGE_CLASS assignment indeed
      (testing for e.g. "/" results in a different test,
      which would be worse yet).
      
      Please suggest a more elegant solution if you invent one!
      10b9e293
  27. 06 Nov, 2011 2 commits
    • Michael Shigorin's avatar
      tweaked variable logging · cc8982dd
      Michael Shigorin authored
      Preferences might be somewhat interesting too: while the official
      ones shouldn't influence the build result at all, there's no whitelist
      so all kinds of weirdness can be stuffed into local config in principle.
      That should be diagnosable at least.
      cc8982dd
    • Michael Shigorin's avatar
      toplevel build report now timestamped · 30b1aa9b
      Michael Shigorin authored
      Thanks torabora@ for yet again seemingly obvious feature request
      which strangely managed to evade implementation before.
      
      On an afterthought, mass builds would suggest too much coffee
      instead of a progress indicator -- so implemented the latter.
      
      NB: the actual downstream-make-calling rule would expand the "naive"
      $(shell date) too early: the rule is evaluated before starting its
      execution, and as it's the time consuming one the shell evaluation
      was in need, not make's.  The result is less generally available
      (needs to be double quoted and won't work inside e.g. awk programs)
      but way more precise.
      30b1aa9b
  28. 04 Nov, 2011 10 commits
    • Michael Shigorin's avatar
      introduced conf.d/ for distro, ve config snippets · e8306860
      Michael Shigorin authored
      This was asked for by Leo-sp50 and torabora, and seems quite reasonable:
      let's provide means to keep at least some distribution configurations
      a bit apart, so that these can be considered more standalone in terms
      of hard warranted functionality but at the same time enjoying the common
      infrastructure.
      
      Considering lib/distro.mk: it's now experimentally pulled apart so that
      parallel development of different distro families can go on without
      major merge hassles.  *Please* don't abuse with massive copy-paste.
      
      And before you ask: this might get extended to allow for "private"
      out-of-tree configurations being included since apparently there
      are goals with no meaning outside of some very particular context...
      but otherwise I'd like to encourage getting reusable bits in-tree.
      e8306860
    • Michael Shigorin's avatar
      official {distro,ve}/* support · d5a5941f
      Michael Shigorin authored
      This is quite a large-scale change since mkimage-profiles got used to
      baking distributions over the last year, and virtual environments are
      quite different, so e.g. image.in/Makefile had to be split in two with
      the main part of it moved into features.in/iso/lib/.
      
      Short overview:
      
      - features.in/Makefile: lib/ support
        (supporting VE images requires dynamic modifications
        to image.in/Makefile before starting the build;
        the most natural way to achieve that seems to use
        features mechanism along with makefile include dir)
      
      - packaging format related part moved into features.in/pack
        (should be better prepared for diversity either)
      - features.in/iso renamed to features.in/build-distro
      - features.in/ve  renamed to features.in/build-ve
        + NB: these could not be merged as e.g. features.in/build
          due to completely different script hooks
      
      - lib/image.mk renamed to lib/build.mk
      - image, config, log postprocessing moved downstream
      - added a sort of a topping in the form of lib/sugar.mk
      - assorted style fixups (like ifeq usage)
      
      - clean.mk: reliability fix (the problem was observed by Oleg Ivanov
        and me too but finally it did get the attention quantum)
      
      - reviewed, updated and extended docs
        + QUICKSTART: should be[come] a step-by-step guide
          (thanks Leo-sp50 for prodiving feedback)
      d5a5941f
    • Michael Shigorin's avatar
      Makefile: make everything · 3373a7bc
      Michael Shigorin authored
      $(IMAGES) in prerequisites definitely won't work,
      so let's do it straightforward.
      3373a7bc
    • Michael Shigorin's avatar
      ensure that image output directory does exist · 7f555ed7
      Michael Shigorin authored
      It turned out that ~/out masked the broken execution path
      when it's absent (which was handled incompletely).  Sigh.
      7f555ed7
    • Michael Shigorin's avatar
      .base rehashed, DISK_LISTS renamed, etc · 5f881522
      Michael Shigorin authored
      In particular:
      - .base is now generated from pieces (see image.in/Makefile)
      - s/DISTROS/IMAGES/g; s/CONFIGS/DISTROS/g (for clarity)
      - s/DISK_LISTS/MAIN_LISTS/g ("disk" was early m-p-d legacy)
      - introduced BASE_PACKAGES to complement BASE_LISTS
      - minor tweaks to Makefile (ARCH and DATE moved elsewhere)
      - libdistro.mk: dropped overlooked IMAGE_INIT_LIST copy
      - clean.mk: silly cleanup
      5f881522
    • Michael Shigorin's avatar
      README update · b69a8a63
      Michael Shigorin authored
      reword 'em, structurize 'em, facelift 'em too
      b69a8a63
    • Michael Shigorin's avatar
      kernel and BUILDDIR fixes · c2f70e5c
      Michael Shigorin authored
      - image.in/functions.mk: rework kpackage()
        + it takes two arguments explicitly now: this adds some noise
          for "generic" invocations but is rather less messy with recently
          introduced STAGE1_KFLAVOUR (which in its turn is rather cleaner
          than messing with KFLAVOURS, especially since soemthing changed
          in presumably apt and we can't rely on kernel packages being
          installed in the order formed).
      - BUILDDIR/DEBUG related fixes
        + Makefile: BUILDDIR initialization moved to distro.mk
      - build.log += git info
      c2f70e5c
    • Michael Shigorin's avatar
      server-ovz; KDEFAULT; syslinux features reworked · 3f012958
      Michael Shigorin authored
      Renamed server-light.iso into server-ovz.iso to avoid brand dilution
      and confusion (rider@'s server-light rather favours kvm, anyways).
      
      Introduced KDEFAULT: a reliable default kernel chooser knob
      since apt's regex ordering proved pretty unreliable.
      Spelling things explicitly is better anyways.
      
      SYSLINUX related features undergone pretty major rewrite
      (that includes syslinux, hdt and memtest).
      
      The problem to tackle was features.in/syslinux/generate.mk
      assuming syslinux and pciids available in build *host* system;
      this well might not be the case (or worse yet, those can be
      just different).  So now we're a bit less elegant and a bit
      more enterprise, stuffing things into chroot and working there.
      
      Bunch of other fixes along the road, including ; to name a few:
      - fixed memtest entry (overlooked while renaming SYSLINUX_ITEMS)
      - new and shiny doc/CodingStyle
      - gfxboot, stage1 target chain, hdt tweaks
      - distro.mk rehashed
      - README++
      - TODO: dropped (integer overflow anyways)
        + actually moved off-tree to reduce commit spam
      - s,\.config\.mk,distcfg.mk,g
      - doc/profiles.mk.sample: sample ~/.mkimage/profiles.mk
      - ...and assorted fixups/additions
      
      Sorry for convoluted commit, this would have been pretty hard to
      rework into some really readable shape (and you might be interested
      in the original repo's history horrors then, anyways).
      3f012958
    • Michael Shigorin's avatar
      initial logging subsystem · d93989a3
      Michael Shigorin authored
      Now we don't dump all the gory details onto thee
      but rather log them handsomely and present only
      the most important details by default; use DEBUG=1
      and/or BUILDLOG=/path/to/file to tweak.
      
      Also introduced IMAGEDIR and IMAGENAME.
      
      The rest:
      - ovz-smp is no more
      - base-l10n pkglist (suggested by Alexander Kuprin)
      - clean.mk:
        + fixed an oversight: the test result erroneously applied
          only to the first command of several ones that should be
          run iff build/ is a symlink
        + drop implicit rules (it's no C code)
      - Makefile: more reasonable iso names
      - image.in/Makefile: .disk/date too
      d93989a3
    • Michael Shigorin's avatar
      assorted fixups · ace5cb0f
      Michael Shigorin authored
      - more thorough build stages inline doc
      - quieter BUILDDIR instantiation
      - branding-altlinux-sisyphus by default
      - prettify installer selection somewhat
      - mkimage #24669 fixed upstream
      - sub.in/stage1/modules: +drm (as in m-p-d, for KMS)
      - tags2lists: generalize a bit
      ace5cb0f