alpine-2.00-r4 failed to merge because of some issues with the OpenSSL support picking up the OS copy of OpenSSL header (Centos 5.5) instead of the Prefix copy. Reproducible: Always Steps to Reproduce: 1. emerge alpine 2. 3. Actual Results: Failed merge with broken syntax SSL headers Expected Results: Successful merge Stopping the emerge after the 'Source unpacked' with Ctrl-Z Edit $PREFIX/var/tmp/portage/mail-client/alpine-2.00-r4/work/alpine-2.00/imap/src/osdep/unix/Makefile and changing SSLCFLAGS= -I$(SSLINCLUDE) -I$(SSLINCLUDE)/openssl\ -DSSL_CERT_DIRECTORY=\"$(SSLCERTS)\" -DSSL_KEY_DIRECTORY=\"$(SSLKEYS)\" to SSLCFLAGS= -I<your prefix>$(SSLINCLUDE) -I<your prefix>$(SSLINCLUDE)/openssl\ -DSSL_CERT_DIRECTORY=\"$(SSLCERTS)\" -DSSL_KEY_DIRECTORY=\"$(SSLKEYS)\" seemed to fix the problem. This is not a good solution, but perhaps a stopgap.
alpine needs an extensive amount of patching to work nicely in Prefix. The build system hardcodes zillion of paths to host-provided libraries based on platform used. If you have interest in this package, I encourage you to create a patch.