This comes from Chapter 8 of Björk's "Arbitrage Theory in Continuous Time" entitled "Completeness and Hedging". The martingale approach and multidimensional models are only introduced in later chapters (resp. 10 and 13). So I'll write up an answer which does not rely on either of these concepts but rather on the notion of dynamic hedging in complete marks, as the title of the chapter suggests.
Complete derivation
The exercise says we're working in "the standard Black-Scholes" framework, that is, with a risky-asset whose spot price $S_t$ follows a GBM with volatility $\sigma$ and a risk-free money market account. The value at time $t$ of 1 unit of currency invested in the latter account will be denoted $B_t$ and the risk-free rate $r$. We assume that $S$ pays no dividends so that investing in $S$ is a self-financing strategy.
We let $ (S_i(t))_{i=1}^N$ denote the $t$-values of $N$ claims contingent on asset $S$ and delivering a payout $(\phi_i(.))_{i=1}^N$ at maturity $T$. We then also let
$$ V_t = \sum_{i=1}^N h_i(t) S_i(t) \tag{0}$$
denote the $t$-value of a portfolio composed of a weighted sum of the $N$ contingent claims defined earlier.
$(V_t)_{t \geq 0}$ is assumed to be a Markovian process so that we can write $V_t = \color{red}{V}(t,S_t)$. It then follows, by Ito's lemma, that:
$$ dV_t = \frac{\partial \color{red}{V}}{\partial t} + \frac{\partial \color{red}{V}}{\partial S} dS_t + \frac{\partial^2 \color{red}{V}}{\partial S^2} d \langle S \rangle_t \tag{A} $$
We will not use this assumption for the moment. We just keep it in mind for later.
$(V_t)_{t \geq 0}$ is also assumed to represent the value of a self-financing wealth process. By definition of the self-financing property and by applying Itô's lemma on the individual contingent claims' prices, this leaves us with
\begin{align}
dV_t &= \sum_{i=1}^N h_i(t) dS_i(t) \\
&= \sum_{i=1}^N h_i(t) \left( \frac{\partial S_i}{\partial t} dt + \frac{\partial S_i}{\partial S} dS_t + \frac{1}{2} \frac{\partial^2 S_i}{\partial S} d\langle S \rangle_t \right) \tag{B}
\end{align}
Consider the self-financing hedging portfolio $\Pi$ with $t$-value
$$ \Pi_t = V_t - \alpha(t) S_t $$
Again, by definition of the self-financing property and using previous identities we have
\begin{align}
d\Pi_t &= dV_t - \alpha(t) dS_t \tag{1} \\
&= \sum_{i=1}^N h_i(t) \left( \frac{\partial S_i}{\partial t} dt + \frac{\partial S_i}{\partial S} dS_t + \frac{1}{2} \frac{\partial^2 S_i}{\partial S} d\langle S \rangle_t \right) - \alpha(t) dS_t \tag{2}
\end{align}
From the above we wee that constructing our dynamic hedge by picking
$$ \alpha^*(t) = \sum_{i=1}^N h_i(t) \frac{\partial S_i}{\partial S} \tag{3}$$
makes the P&L of the the hedging portfolio deterministic, or delta-neutral, such that in the limit as $dt \to 0$, the P&L is zero almost surely (perfect hedging).
For this particular choice of $\alpha^*(t)$, the hedging portfolio should therefore earn the risk-free rate in the absence of arbitrage opportunities:
$$ d(\Pi_t(\alpha^*)) = r \Pi_t(\alpha^*) dt $$
Building on $(1)$ and $(2)$ and $(3)$ (and our GBM working assumption for $S$ for the quadratic variation term)
$$ \sum_{i=1}^N h_i(t) \left( \frac{\partial S_i}{\partial t} + \frac{1}{2} \frac{\partial^2 S_i}{\partial S} \sigma^2 S^2 \right) dt = r \left(V_t - \sum_{i=1}^N h_i(t) \frac{\partial{S_i}}{\partial{S}} S_t \right) dt $$
hence finally we see that the option price $V_t$ should verify the pricing PDE
$$ \sum_{i=1}^N h_i(t) \left( \frac{\partial S_i}{\partial t} + r S \frac{\partial S_i}{\partial S} + \sigma^2 S^2 \frac{\partial^2 S_i}{\partial S^2}\right) - rV_t = 0 \tag{4} $$
$$ V_T = \sum_{i=1}^N h_i(T) \phi_i(S) $$
Remembering that we can write $V_t = \color{red}{V}(t,S)$ from the Markovian property and identifying the coefficients of the 2 Itô differentials $(A)$ and $(B)$, we can rewrite the above PDE as
$$ \frac{\partial \color{red}{V}}{\partial t}(t,S) + r S \frac{\partial \color{red}{V}}{\partial S}(t,S) + \sigma^2 S^2 \frac{\partial^2 \color{red}{V}}{\partial S^2}(t,S) - r\color{red}{V}(t,S) = 0 \tag{5} $$
$$ \color{red}{V}(T,S) = \sum_{i=1}^N h_i(T) \phi_i(S) $$
which is indeed Black-Scholes PDE for $\color{red}{V}(t,S)$.
Alternative derivation
Let's take the problem the other way around as you propose to do in your original post:
$$ \frac{\partial V}{\partial t}(t,S) + r S \frac{V}{\partial S}(t,S) + \sigma^2 S^2 \frac{\partial^2 V}{\partial S^2}(t,S) - rV(t,S) \stackrel{?}{=} 0 \tag{5} $$
We know that $(V_t)$ is Markovian, so that we can write $$V_t = V(t,S) = \sum_{i=1}^N h_i(t) S_i(t,S) $$
where $S_i(t,S)$ are the fair prices of the $N$ contingent claims, i.e. functions verifying the individual Black-Scholes PDE with terminal conditions involving the payout functions $\phi_i(.)$.
The derivatives then follow from standard calculus:
$$ \frac{\partial V}{\partial t}(t,S) = \sum_{i=1}^N \frac{\partial h_i}{\partial t}(t) S_i(t,S) + \sum_{i=1}^N h_i(t) \frac{\partial{S_i}}{\partial t}(t,S) $$
$$ \frac{\partial V}{\partial S}(t,S) = \sum_{i=1}^N h_i(t) \frac{\partial{S_i}}{\partial S}(t,S) $$
$$ \frac{\partial^2 V}{\partial S^2}(t,S) = \sum_{i=1}^N h_i(t) \frac{\partial^2{S_i}}{\partial S^2}(t,S) $$
Now the key here is to note that the time derivative can be simplified. Thanks to the self-financing property, the $h_i'(t)$ term disappears (see the two identities $(A)$ and $(B)$ above, or this question in the general case where $h_i$ also depends on $S$ in addition to $t$)
Plugging these derivatives back in the pricing PDE for $V$, along with the definition of $V$ as the sum of $N$ contingent claims we get that indeed
$$ \sum_{i=1}^N h_i(t) \left( \frac{\partial S_i}{\partial t}(t,S) + r S \frac{S_i}{\partial S}(t,S) + \sigma^2 S^2 \frac{\partial^2 S_i}{\partial S^2}(t,S) - rS_i(t,S) \right) = 0 $$
since the functions $S_i(t,S)$ verify the $N$ individual Black-Scholes pricing PDEs.