Port Package - how to change before compile?

Hi there!

I have a problem with the default port installation. I want to compile CoreDNS with the MySQL package, but - I don't know how to change the settings.
When the port is downloaded, I want to change the default “plugin.cfg” with “mysql:github.com/snail2sky/coredns_mysql_extend”.

But this only works after I have compiled the first time. Only then do I have the plugin.cfg, and if I change it and then do it again, of course “make” again doesn't work.
make clean deletes everything and the game starts all over again.

Does anyone know how I can get the “default” port to change to edit the plugin.cfg before compiling?
 
If I got you right;
First, clean the port with # make clean. You can extract the port to work directory with # make extract and then you can copy the file to be modified with .orig extension and then you can modify the file that doesn't have .orig.
Code:
# cd work/portname
# cp file-to-be-modified file-to-be-modified.orig
# edit file-to-be-modified
After editing the file, Go back to port's directory where Makefile and other port files like distinfo are located, and run # make makepatch. Now you can clean the port with # make clean and start building the port with the patch. This (# make makepatch) will generate patch in files/ directory and while building the port, that will be applied to the port. This way you are creating a local patch that will be applied to specific file in build time.
 
If I got you right;
First, clean the port with # make clean. You can extract the port to work directory with # make extract and then you can copy the file to be modified with .orig extension and then you can modify the file that doesn't have .orig.
Code:
# cd work/portname
# cp file-to-be-modified file-to-be-modified.orig
# edit file-to-be-modified
After editing the file, Go back to port's directory where Makefile and other port files like distinfo are located, and run # make makepatch. Now you can clean the port with # make clean and start building the port with the patch. This (# make makepatch) will generate patch in files/ directory and while building the port, that will be applied to the port. This way you are creating a local patch that will be applied to specific file in build time.
Ahhh!!
Thanks a lot!! This make extract and make patch seems to become awesone.

Million times thanks!!!
 
Back
Top