Robot skill learning is one of the international advanced directions in the field of robot-based intelligent manufacturing, which makes it possible for robots to learn and operate autonomously in complex real-world environments. In this paper, we propose a multitasking-oriented robot skill learning framework named MT-RSL to improve the efficiency and robustness of multi-task robot skill learning in complex real-world environments, and present the detailed design steps of three key sub-modules included in MT-RSL, namely, sub-task segmentation module, robot skill learning module, and robot configuration optimization module. Firstly, we design a novel sub-task segmentation module based on a coarse-to-fine sub-task segmentation (CF-STS) strategy, in which the Finite State Machine (FSM) is used to analyze complex robot behaviors to obtain a coarse robot sub-task sequence, and the Beta Process Autoregressive Hidden Markov Model (BP-AR-HMM) is used to establish the connection and dependence between multiple demonstration trajectories and encode these trajectories, so as to obtain a finer robot action sequence. Secondly, we extend the basic DMPs system to a continuous dynamic movement primitives (CDMPs) system to construct a novel robot skill learning module, which improves the efficiency of the robot to learn skills and perform actions by orderly coordinating sub-parts such as the activation signals, motion actuator, DMPs-based learning module, and robot configuration optimization module. Then, we design a novel robot configuration optimization module, which introduces the velocity directional manipulability measure (VDM) as the evaluation index of robot kinematic performance to establish the robot configuration optimization model, and proposes an improved probabilistic adaptive particle swarm optimization (Pro-APSO) algorithm to solve this optimization model, so as to obtain the optimal robot configuration. Finally, we develop an experimental testing platform based on the Robot Operating System (ROS) and conduct a series of prototype experiments in complex real-world scenarios. The experimental results demonstrate that our proposed MT-RSL can significantly improve the effectiveness and robustness of multi-task robot skill learning, and can outperform existing robot skill learning methods in terms of both learning efficiency, VDM, and success rate.