The Buddha was not opposed to working towards goals, he was opposed to things that lead away from arahantship.
Arahantship or enlightenment comes from the destruction of the Âsavas, usually translated as cankers, pains, taints, or fermentations, not from merely giving up desires or wishes.
In many Suttas The Buddha refers to arahants having "wants" or "wishes", though obviously not the same as ordinary humans having wants.
There is the Akankheyya Sutta (MN 6) where The Buddha encouraged monks to fulfill their desires (through proper means):
'If a Bhikkhu (monk) should desire, Brethren, to become beloved, popular, respected among his fellow-disciples, let him then fulfil all righteousness, let him be devoted to that quietude of heart which springs from within, let him not drive back the ecstasy of contemplation, let him look through things, let him be much alone!'
....continued on with different desires until...
'If a Bhikkhu should desire, Brethren, by the destruction of the great evils (Âsavas), by himself, and even in this very world, to know and realise and attain to Arahatship, to emancipation of heart, and emancipation of mind, let him then fulfil all righteousness, let him be devoted to that quietude of heart which springs from within, let him not drive back the ecstasy of contemplation, let him look through things, let him be much alone!' - Akankheyya Sutta (MN 6)
The point is not to focus on whether or not you should have desires but to focus on what leads towards the final goal.
Also in many Suttas The Buddha refers to monks doing things "if he wants".
There is also the case where The Buddha was questioned on who has more pleasure the King or The Buddha:
"'But, friend Gotama, it's not the case that pleasure is to be attained through pleasure. Pleasure is to be attained through pain. For if pleasure were to be attained through pleasure, then King Seniya Bimbisara of Magadha would attain pleasure, for he lives in greater pleasure than you, friend Gotama.'
"'Surely the venerable Niganthas said that rashly and without reflecting... for instead, I should be asked, "Who lives in greater pleasure: King Seniya Bimbisara of Magadha or venerable Gotama?"'
"'Yes, friend Gotama, we said that rashly and without reflecting... but let that be. We now ask you, venerable Gotama: Who lives in greater pleasure: King Seniya Bimbisara of Magadha or venerable Gotama?'
"'In that case, Niganthas, I will question you in return. Answer as you like. What do you think: Can King Seniya Bimbisara of Magadha — without moving his body, without uttering a word — dwell sensitive to unalloyed pleasure for seven days & nights?'
"'No, friend."
"'... for six days & nights... for five days & nights... for a day & a night?'
"'No, friend."
"'Now, I — without moving my body, without uttering a word — can dwell sensitive to unalloyed pleasure for a day and a night... for two days & nights... for three... four... five... six... seven days & nights. So what do you think: That being the case, who dwells in greater pleasure: King Seniya Bimbisara of Magadha or me?'
"'That being the case, venerable Gotama dwells in greater pleasure than King Seniya Bimbisara of Magadha.'"
That is what the Blessed One said. Gratified, Mahanama the Sakyan delighted in the Blessed One's words. - Cula-dukkhakkhandha Sutta, MN 14
Thus we see that The Buddha claims that he experiences more pleasure than the King Seniya Bimbisara of Magadha.
There is also the case where The Buddha explained the fruits (or benefits) or a contemplative life in the Samaññaphala Sutta (DN 2).
Arahants and The Buddha himself had "wishes" or "wants", they live freely and do whatever they desire, though not in the same way as ordinary people.
It is possible to have wishes or desires but no attachment to them.
My suggestion to you would be to keep your desires in accordance to the goal and not to be attached to the end result.
There are certain cases where forcing someone to give up a desire would create mental agony in an individual and throw them away from achieving arahantship, and also other cases where individuals give up wishes or desires but do not achieve arahantship.
So in my opinion it is better for you to keep certain desires while striving towards the final goal (enlightenment, arahantship).
You should think:
- It would be easier for me to achieve my goal if I was not attached to the end result
- It would be easier for me to achieve my goal if I had a better concentrated mind
- It would be easier for me to achieve my goal if I had achieved higher states
Being attached to the end result makes it much harder to achieve your goal. If you really want to achieve your goal you should focus on achieving it without attachment, and in ways in accordance to the goal.
Just imagine how extraordinarily easy achieving a goal like this would be for someone who really was an arahant.
Thus you should train yourself towards achieving the final goal.