With a sharp knife peel the squash, then remove the seeds with a spoon and chop the flesh into small cubes. Transfer the cubes into a large pot and add the sugar.
Mix well and cover the pot with the lid, then let it rest for at least 6 hours or overnight.
After the resting time, the pumpkin will have released all its liquids; add the pumpkin spices and the lemon juice then turn on the heat to low and cook for at least 1 hour.
When the pumpkin is soft, mash it with a fork or with an immersion hand blender. You can decide the actual consistency of the jam, if you prefer it more chunky or not.
With a spoon, or with the help of a funnel, pour the jam into the sterilized jars leaving 1/2 cm on top and close them well. Turn the jars upside down until completely cooled.