On 1/1/2022 12:12 PM, Bhavin Gandhi wrote: > When all three variants are built, the make install is run from > build-gtk directory at the end. And during this install command, it is > creating a emacs.pdmp again, where build says Loading foo only. > > Can be reproduced with following commands: > > mkdir build-gtk > cd build-gtk/ > ln -s ../configure . > ./configure > make bootstrap > make > cd .. > > mkdir build-nox > cd build-nox/ > ln -s ../configure . > ./configure > make bootstrap > make > > cd ../build-gtk > sudo make install > ^^^ This runs configure, make all lib etc again, I can see a new > emacs.pdmp file being created which loads foo.el from source. > > Is this type of build and install flow supported? > > AFAIK, the RPM build requires the all build commands to be together in > one section, and then all install related commands in a separate > section. That's why this kind of flow is being used it seems. > > Two workarounds I can think of are, > 1. Build GTK at the end and then do make install from build-gtk > 2. Extract the source tar in different directories to keep these builds > completely separate from each other. In case it's of any use to you, I can show you how I handle this on Cygwin. We use a tool called cygport, which processes a file emacs.cygport (attached). You can think of this as the analogue of an rpm .spec file. I realize that you're not familiar with cygport, but emacs.cygport is a bash script, and I suspect you can decipher most of it. The crucial things to look at are the src_compile and src_install functions. Ken