[Bug 39623] New: "make install" re-runs "make" process unnecessarily
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Bug ID: 39623 Summary: "make install" re-runs "make" process unnecessarily Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: dcook@prosentient.com.au QA Contact: testopia@bugs.koha-community.org Have you ever noticed that "make install" seems to do all the same things as "make" plus install? This became even more obvious after bug 32609. And it got me thinking... surely there has to be a better way and it looks like there is. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=32609 -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=37911 -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@gmail.com, | |paul.derscheid@lmscloud.de -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #1 from David Cook <dcook@prosentient.com.au> --- Created attachment 180896 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=180896&action=edit Bug 39623: Remove "install" target's dependency on "all" target This change removes the install target's dependency on "all". There is no clear reason why "install" would need to depend on all other build targets. After you remove this dependency, running "make" and "make install" work the way you'd expect them to work. "make" does the build and "make install" does the install. Test plan: 0. DO NOT APPLY THE PATCH YET! 1. Setup intall target sudo mkdir /opt/koha sudo chown kohadev-koha /opt/koha 2. Clean build env rm -rf blib Makefile /opt/koha/* 3. perl Makefile.PL Installation mode (dev, single, standard) [standard] single Please specify the directory in which to install Koha [/var/lib/koha/kohadev/koha] /opt/koha NOTE: Otherwise accept all defaults 4. make NOTE: build-resources.PL is run and the blib directory is populated 5. make install NOTE: build-resources.PL is run and the blib directory is populated and the built files are installed to /opt/koha 6. Apply the patch now 7. mv /opt/koha /opt/koha.bak 8. Re-setup install target sudo mkdir /opt/koha sudo chown kohadev-koha /opt/koha 9. Clean build env rm -rf blib Makefile /opt/koha/* 10. perl Makefile.PL Installation mode (dev, single, standard) [standard] single Please specify the directory in which to install Koha [/var/lib/koha/kohadev/koha] /opt/koha NOTE: Otherwise accept all defaults 11. make NOTE: build-resources.PL is run and the blib directory is populated 12. make install NOTE: Only the install step is run 13. diff -r /opt/koha /opt/koha.bak 14. Note that there are no differences between the two directories -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |In Discussion --- Comment #2 from David Cook <dcook@prosentient.com.au> --- Temporarily marking as "In Discussion", as I think we will want to test the git "dev" install, the "standard" install, "make test" and "make upgrade". -- Of course, as I say that, I've run "make upgrade" and it looks good. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Paul Derscheid <paul.derscheid@lmscloud.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #180896|0 |1 is obsolete| | --- Comment #3 from Paul Derscheid <paul.derscheid@lmscloud.de> --- Created attachment 180897 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=180897&action=edit Bug 39623: Remove "install" target's dependency on "all" target This change removes the install target's dependency on "all". There is no clear reason why "install" would need to depend on all other build targets. After you remove this dependency, running "make" and "make install" work the way you'd expect them to work. "make" does the build and "make install" does the install. Test plan: 0. DO NOT APPLY THE PATCH YET! 1. Setup intall target sudo mkdir /opt/koha sudo chown kohadev-koha /opt/koha 2. Clean build env rm -rf blib Makefile /opt/koha/* 3. perl Makefile.PL Installation mode (dev, single, standard) [standard] single Please specify the directory in which to install Koha [/var/lib/koha/kohadev/koha] /opt/koha NOTE: Otherwise accept all defaults 4. make NOTE: build-resources.PL is run and the blib directory is populated 5. make install NOTE: build-resources.PL is run and the blib directory is populated and the built files are installed to /opt/koha 6. Apply the patch now 7. mv /opt/koha /opt/koha.bak 8. Re-setup install target sudo mkdir /opt/koha sudo chown kohadev-koha /opt/koha 9. Clean build env rm -rf blib Makefile /opt/koha/* 10. perl Makefile.PL Installation mode (dev, single, standard) [standard] single Please specify the directory in which to install Koha [/var/lib/koha/kohadev/koha] /opt/koha NOTE: Otherwise accept all defaults 11. make NOTE: build-resources.PL is run and the blib directory is populated 12. make install NOTE: Only the install step is run 13. diff -r /opt/koha /opt/koha.bak 14. Note that there are no differences between the two directories Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #4 from Paul Derscheid <paul.derscheid@lmscloud.de> --- We can keep this 'In Discussion', but I signed off anyway. This would be better if there's no specific reason it was setup as previously. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gmc@esilibrary.com, | |gmcharlt@gmail.com --- Comment #5 from David Cook <dcook@prosentient.com.au> --- (In reply to Paul Derscheid from comment #4)
We can keep this 'In Discussion', but I signed off anyway. This would be better if there's no specific reason it was setup as previously.
I ran out of time yesterday, but looking today.... it looks like commit 5befdd2cd37 added the "install" target with the dependency on "all". It looks like Galen wrote the commit but it was in 2007 so I would doubt he'd remember now why he added the "all" dependency, and it was pre-Bugzilla, so there's no bug report for it. I do think the old bug register was imported into Bugzilla, but I can't find a bug report to link to that commit. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #6 from David Cook <dcook@prosentient.com.au> --- I've actually adopted this into my production workflow, and it certainly looks like it works for the "standard" install used by the Debian package build process (or at least the Debian package build process I use which isn't identical to what the community uses). -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #7 from David Cook <dcook@prosentient.com.au> --- Test plan for dev install: 0. Apply the patch 1. Setup install target sudo mkdir /opt/koha-dev sudo chown kohadev-koha /opt/koha-dev 2. Clean build env rm -rf koha-tmpl/intranet-tmpl/prog/js/vue/dist/* blib Makefile 3. perl Makefile.PL Installation mode (dev, single, standard) [standard] dev Configuration directory: [/var/lib/koha/kohadev/koha-dev] /opt/koha-dev NOTE: Otherwise accept all defaults 4. make 5. make install It all looks good to me. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Signed Off --- Comment #8 from David Cook <dcook@prosentient.com.au> --- The output of "make test" is a bit scary but it seems to be the same for "main" and this patch. (Not that I'm letting the whole thing run.) I think that we can move this to "Signed Off". -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |dcook@prosentient.com.au |ity.org | CC| |martin.renvoize@openfifth.c | |o.uk -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit | |y.org | --- Comment #9 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- This seems very sensible to me.. minor concern is making sure our packaging pipeline is unaffected by the changes. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mtj@kohaaloha.com, | |tomascohen@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #10 from David Cook <dcook@prosentient.com.au> --- (In reply to Martin Renvoize (ashimema) from comment #9)
This seems very sensible to me.. minor concern is making sure our packaging pipeline is unaffected by the changes.
In theory, it should just automagically work, but I suppose that depends on if the packaging pipeline does anything unexpected/abnormal along the way. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #11 from David Cook <dcook@prosentient.com.au> --- Something that needs double-checking: the population of blib/API_CGI_DIR/v1/swagger/swagger_bundle.json from api/v1/swagger/swagger_bundle.json Philippe has raised an issue about "main" that I'm looking into right now... -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=39849 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #12 from David Cook <dcook@prosentient.com.au> --- Going to just move this to In Discussion while we work on bug 39849 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |In Discussion -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #13 from David Cook <dcook@prosentient.com.au> --- This should still work over top of bug 39849. I'm just going to test that... -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Signed Off --- Comment #14 from David Cook <dcook@prosentient.com.au> --- Moving this back to signed off, as I tested it over top of bug 39849 and it works perfectly. I am going to copy over the test plan from 39849 though, since it's better than the one here. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #15 from David Cook <dcook@prosentient.com.au> --- To test: 1a. Run 'git archive --format=tar HEAD > "koha.orig.tar"' 1b. sudo mkdir /opt/koha /opt/build_koha 1c. sudo chown kohadev-koha /opt/koha /opt/build_koha 1d. mv koha.orig.tar /opt/build_koha/. 1e. cd /opt/build_koha 1f. tar xvf koha.orig.tar 2. Run "perl Makefile.PL" Choose "single" Choose "/opt/koha" for target directory Choose the defaults for the rest 3. Run "make" 4. Note the first step is the CSS/JS build 5. Note the second step is the copying of files to "blib" 6. Run "find -name 'erm.js.map'" and note it appears in the regular build location as well as in "blib" 7. Run "find -name 'swagger_bundle.json'" and note it appears in the regular build location as well as in "blib" 8a. Run "make install" 8b. Note that the output only shows Installation. It doesn't rebuild Koha like it does before applying the patch. 9. Run the above "find" commands using "/opt/koha" and note that the files appear in the installed directory -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #180897|0 |1 is obsolete| | --- Comment #16 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Created attachment 182072 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=182072&action=edit Bug 39623: Remove "install" target's dependency on "all" target This change removes the install target's dependency on "all". There is no clear reason why "install" would need to depend on all other build targets. After you remove this dependency, running "make" and "make install" work the way you'd expect them to work. "make" does the build and "make install" does the install. Test plan: 0. DO NOT APPLY THE PATCH YET! 1. Setup intall target sudo mkdir /opt/koha sudo chown kohadev-koha /opt/koha 2. Clean build env rm -rf blib Makefile /opt/koha/* 3. perl Makefile.PL Installation mode (dev, single, standard) [standard] single Please specify the directory in which to install Koha [/var/lib/koha/kohadev/koha] /opt/koha NOTE: Otherwise accept all defaults 4. make NOTE: build-resources.PL is run and the blib directory is populated 5. make install NOTE: build-resources.PL is run and the blib directory is populated and the built files are installed to /opt/koha 6. Apply the patch now 7. mv /opt/koha /opt/koha.bak 8. Re-setup install target sudo mkdir /opt/koha sudo chown kohadev-koha /opt/koha 9. Clean build env rm -rf blib Makefile /opt/koha/* 10. perl Makefile.PL Installation mode (dev, single, standard) [standard] single Please specify the directory in which to install Koha [/var/lib/koha/kohadev/koha] /opt/koha NOTE: Otherwise accept all defaults 11. make NOTE: build-resources.PL is run and the blib directory is populated 12. make install NOTE: Only the install step is run 13. diff -r /opt/koha /opt/koha.bak 14. Note that there are no differences between the two directories Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact| |martin.renvoize@openfifth.c | |o.uk Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |25.05.00 released in| | Status|Passed QA |Pushed to main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 --- Comment #17 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Pushed for 25.05! Well done everyone, thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|25.05.00 |25.05.00,24.11.10 released in| | Status|Pushed to main |Pushed to stable CC| |fridolin.somers@biblibre.co | |m --- Comment #18 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 24.11.x for 24.11.10 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39623 Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Needs documenting --- Comment #19 from Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> --- Not backporting to 22.11.x as it wasn't backported to 24.05.x -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org