So it depends.
The thing to keep in mind is that the .cfx file in a package only needs to contain the lines that are being changed. So you could have a package with a cfx file that contained something like:
<profile> overwrite
<workspace memory> edit
active = no
</workspace memory>
<profile>
if you deployed this, then only if the active key existed in the section <workspace memory> would it be changed.
The rest of the file would be left unchanged.
between the operators "overwrite", "edit", "clear", and nothing you can usually make things work.
You can also repeat sections.
Something like
<profile> overwrite
<workspace memory> edit
active = no
</workspace memory>
<workspace memory>
username = setifnotthere
</workspace memory>
<workspace memory> overwrite
password = alwaysoverwritten
</workspace memory>
<profile>
So active is set to no if it exists, username is set to setifnotthere if it does not exist, and password is always set to alwaysoverwritten.
The other approach is to use the package pre and post install commands to run pu against the configuration. Or a script you supplied in the package.
Garin