Theoretically yes, although you'll need to make the effort to construct your power supply so it is as safe and reliable as the battery pack.
You need to build in safeguards as to voltage regulation, isolation from mains AC, etc.
Measure battery voltage, both after it is charged, and while it runs the laptop. Your power supply should always stay within this range. Otherwise the laptop may refuse to operate.
To convert mains AC, a step down via transformer is safest because it provides isolation.
A buck converter does not provide complete isolation. As a result it may provide a path for high voltage, through cables to equipment that you have connected to the laptop. Or a path for high voltage through you if you touch the wrong things.
- - - Updated - - -
You should also try to make sure that all power drawn from the supply, is used only by normal computer operation. It contains a ruined AC power adapter which may admit undesired current, with bad results.
Have you seen any trouble occurring on battery power yet? If not, then it is likely a homebrew power supply will be all right too.