After getting blindsided with the release of flavors, I spent a few hours upgrading Synth to support them. You can upgrade to the latest version of Synth immediately as follows:
There is one major change to how Synth works now. In order to handle the change from 1-to-1 to many-to-1 relationship between packages and ports, a new index is required. Since ports doesn't supply this index, Synth has to generate it whenever the ports tree changes. To do this, Synth has to scan every single port in the tree. On DragonFly, this takes about 60 seconds. On FreeBSD, it takes several minutes. (The technical explanation is out of scope, but basically dports fixes several bottlenecks that never made it back to freebsd ports).
So when new new Synth starts up, it will immediately begin the scan. Subsequent launches of Synth will work as before until the ports tree is updated.
For ports developers:
This new behavior can cause problems if you're modifying a port. Synth will detect if a single file is newer than the current index. For you, I've added the following logic: As long as the ports tree directories match the new index (no port directories added or deleted), modifying a file will result in this message:
Normally you'd select "N" which would "touch" the index and continue without performing a lengthy scan. If your modifications define or remove flavors, you may want answer "yes" here.
Regular users will not see this message though, and will only have to deal with the new index generation when the port tree changes.
Hopefully tobik@ will find this post and update ports soon. The synth port maintainer already requested the update (as you could imagine).
I've done some testing and everything seems to work fine, but this version represents a LOT of new code so please report any strange behavior if you find any.
-- John
- cd /usr/ports/ports-mgmt/synth
- edit Makefile, change DISTVERSION from "1.71" to "2.00"
make makesum
make clean deinstall
make install
There is one major change to how Synth works now. In order to handle the change from 1-to-1 to many-to-1 relationship between packages and ports, a new index is required. Since ports doesn't supply this index, Synth has to generate it whenever the ports tree changes. To do this, Synth has to scan every single port in the tree. On DragonFly, this takes about 60 seconds. On FreeBSD, it takes several minutes. (The technical explanation is out of scope, but basically dports fixes several bottlenecks that never made it back to freebsd ports).
So when new new Synth starts up, it will immediately begin the scan. Subsequent launches of Synth will work as before until the ports tree is updated.
For ports developers:
This new behavior can cause problems if you're modifying a port. Synth will detect if a single file is newer than the current index. For you, I've added the following logic: As long as the ports tree directories match the new index (no port directories added or deleted), modifying a file will result in this message:
Code:
*******************************************************************
The ports tree has at least one file newer than the flavor index.
However, port directories perfectly match. Should the index be
regenerated? (Y/N)
Normally you'd select "N" which would "touch" the index and continue without performing a lengthy scan. If your modifications define or remove flavors, you may want answer "yes" here.
Regular users will not see this message though, and will only have to deal with the new index generation when the port tree changes.
Hopefully tobik@ will find this post and update ports soon. The synth port maintainer already requested the update (as you could imagine).
I've done some testing and everything seems to work fine, but this version represents a LOT of new code so please report any strange behavior if you find any.
-- John