Yes, you should think of it just like you think of any other metric space. Every norm $\|\cdot\|$ induces a metric $d(x,y) := \|x-y\|$.
In your example,
$$ B(x_0, 1) = \{ f: X \to \mathbb R \Big \vert \|f - x_0\|_\infty < 1 \}$$
In the $\sup$-norm, these $f$ are all functions that are never further away from $x_0$ at any given $x$ in $\mathbb R$. This is what it looks like:
Claim: A topological space $\,X\,$ is compact iff it has the Finite Intersection Property (=FIP):
Proof: (1) Suppose $\,X\,$ is compact and let $\,\{V_i\}\,$ be a family of closed subsets s.t. $\,\displaystyle{\bigcap_{i}V_i=\emptyset}\,$. Putting now $\,A_i:=X-V_i\,$ , we get that $\,\{A_i\}\,$ is a family of open subsets , and
$$\bigcap_{i}V_i=\emptyset\Longrightarrow \;X=X-\emptyset=X-\left(\bigcap_iV_i\right)=\bigcup_i\left(X-V_i\right)=\bigcup_iA_i\Longrightarrow\;\{A_i\}$$
is an open cover of $\,X\,$ and thus there exists a finite subcover of it:
$$X=\bigcup_{i\in I\,,\,|I|<\aleph_0}A_i=\bigcup_{i\in I\,,\,|I|<\aleph_0}(X-V_i)=X-\left(\bigcap_{i\in I\,,\,|I|<\aleph_0}V_i\right)\Longrightarrow \bigcap_{i\in I\,,\,|I|<\aleph_0}V_i=\emptyset\Longrightarrow$$
The family $\,\{V_i\}\,$ has the FIP.
(2) Suppose now that every family of closed subsets of $\,X\,$ hast the FIP, and let $\,\{A_i\}\,$ be an open cover of it. Put $\,U_i:=X-A_i\,$ , so $\,U_i\, $ is closed for every $\,i\,$:
$$\bigcap_iU_i=\bigcap_i(X-A_i)=X-\bigcup_i A_i=X-X=\emptyset$$
By assumption, there exists a finite set $\,J\,$ s.t. $\,\displaystyle{\bigcap_{i\in J}U_i=\emptyset}\,$ , but then
$$X=X-\emptyset=X-\bigcap_{i\in J}U_i=\bigcup_{i\in J}X-U_i)=\bigcup_{i\in J}A_i\Longrightarrow$$
$\,\{A_i\}_{i\in J}$ is a finite subcover for $\,X\,$ and thus it is compact....QED.
Please be sure you can follow the above and justify all steps. Check where we used Morgan Rules, for example, and note that we used the contrapositive of the FIP's definition...
Best Answer
Sorry for all the edits. In my previous attempt, I forced my proof to use the fact that $A$ is closed, but this made the proof more complicated without apparent necessity.
So I'm scrapping the hypothesis that $A$ is closed. I don't think it's necessary. But if I'm wrong, I'm sure someone will be quick to point it out. :-)
As you said, let $x \in \mathcal{O}$ and $l = d(x,A)$. Then $l < r$. Let $0 < R < (r - l)$. We wish to show that $B(x,R) \subseteq \mathcal{O}$.
Let $y \in B(x,R)$. We need to show that $y \in \mathcal{O}$. Let $\delta > 0$. Since $d(x,A) = l$, there is some $a \in A$ such that $d(x,a) < l + \delta$. Then $$d(y,a) \leq d(y,x) + d(x,a) < R + l + \delta$$ We can find such an $a \in A$ for any $\delta > 0$, so $$d(y,A) \leq R + l$$ But $R + l < r$, so we're done.