During the violent relaxation of a self-gravitating system, a significant fraction of its mass may be ejected. If the time-varying gravitational field also breaks spherical symmetry, this mass can potentially carry angular momentum. Thus, starting initial configurations with zero angular momentum can, in principle, lead to a bound virialised system with non-zero angular momentum. Using numerical simulations we explore here how much angular momentum can be generated in a virialised structure in this way, starting from configurations of cold particles that are very close to spherically symmetric. For the initial configurations in which spherical symmetry is broken only by the Poissonian fluctuations associated with the finite particle number N, with N in range 10 3 to 10 5 , we find that the relaxed structures have standard "spin" parameters λ ∼ 10 −3 , and decreasing slowly with N. For slightly ellipsoidal initial conditions, in which the finite-N fluctuations break the residual reflection symmetries, we observe values λ ∼ 10 −2 , i.e. of the same order of magnitude as those reported for elliptical galaxies. The net angular momentum vector is typically aligned close to normal to the major semi-axis of the triaxial relaxed structure and of the ejected mass. This simple mechanism may provide an alternative, or complement, to the so-called tidal torque theory for understanding the origin of angular momentum in astrophysical structures.