If I understand what you mean, then your oscillator will have to be defined in order for the delay routine to know how many cycles makes up your required delay.
For example, out of the C30 help file:
Default Behavior: This function relies on a user-supplied definition of FCY to represent the instruction clock frequency. FCY must be defined before header file libpic30.h is included. The specified delay is converted to the equivalent number of instruction cycles and passed to __delay32(). If FCY is not defined, then __delay_ms() is declared external, causing the link to fail unless the user provides a function with that name.
Thanx Gobbledok for helping ....... but what i mean that if i increase or even decrease the frequency of the oscillator , do that affect the delay routine ???
How many different oscillator speeds will you be using?? If it will only be a couple (full-speed and power-saving, for example) then maybe just have a different delay routine for each speed.
Or maybe have a register that represents your oscillator speed which you update when you change your oscillator speed. Then your delay routine checks that register and chooses the correct delay based on that.