# If no preference was set, check for an installed base version
# but give an installed port preference over it.
-. if defined(WITH_OPENSSL_PORT)
-. if defined(OPENSSL_PORT)
-SSL_DEFAULT:=${OPENSSL_PORT:T}
-WARNING+= "Using WITH_OPENSSL_PORT and OPENSSL_PORT in make.conf is deprecated, replace them with DEFAULT_VERSIONS+=ssl=${SSL_DEFAULT} in your make.conf"
-. else
-SSL_DEFAULT=openssl
-WARNING+= "Using WITH_OPENSSL_PORT in make.conf is deprecated, replace it with DEFAULT_VERSIONS+=ssl=openssl in your make.conf"
-. endif
-. elif defined(WITH_OPENSSL_BASE)
-SSL_DEFAULT=base
-WARNING+= "Using WITH_OPENSSL_BASE in make.conf is deprecated, replace it with DEFAULT_VERSIONS+=ssl=base in your make.conf"
-WARNING+= "WITHOUT_NLS is deprecated use OPTIONS_UNSET=NLS instead"
+ERROR+= "WITHOUT_NLS is unsupported use OPTIONS_UNSET=NLS instead"
.endif
+.if defined(NOPORTDOCS)
+ERROR+= "NOPORTDOCS is unsupported use OPTIONS_UNSET=DOCS instead"
+.endif
+
+.if defined(NOPORTEXAMPLES)
+ERROR+= "NOPORTEXAMPLES is unsupported use OPTIONS_UNSET=EXAMPLES instead"
+.endif
+
+.if defined(WITH_BDB_VER)
+ERROR+= "WITH_BDB_VER is unsupporteed, use DEFAULT_VERSIONS+=bdb=${WITH_BDB_VER}"
+.endif
+
+.if defined(OVERRIDE_LINUX_BASE_PORT)
+ERROR+= "OVERRIDE_LINUX_BASE_PORT is unsupporteed, use DEFAULT_VERSIONS+=linux=${OVERRIDE_LINUX_BASE_PORT}"
+.endif
+
+.if defined(WITH_OPENSSL_PORT)
+ERROR+= "WITH_OPENSSL_PORT is unsupporteed, use DEFAULT_VERSIONS+=ssl=${SSL_DEFAULT:Uopenssl} in your make.conf"
+.endif
+
+.if defined(WITH_OPENSSL_BASE)
+ERROR+= "WITH_OPENSSL_BASE is unsupporteed, use DEFAULT_VERSIONS+=ssl=base in your make.conf"
+.endif
+
+.for opt in ${ALL_OPTIONS:NDEBUG}
+.if defined(WITH_${opt})
+WARNING+= "WITH_${opt} is unsupported, use WITH=${opt} on the command line, or one of these in /etc/make.conf, OPTIONS_SET+=${opt} to set it globally, or ${OPTIONS_NAME}_SET+=${opt} for only this port."
+.endif
+.if defined(WITHOUT_${opt})
+WARNING+= "WITHOUT_${opt} is unsupported, use WITHOUT=${opt} on the command line, or one of these in /etc/make.conf, OPTIONS_UNSET+=${opt} to set it globally, or ${OPTIONS_NAME}_UNSET+=${opt} for only this port."