Just exactly what do you mean by "...and the content had to be the same module n times inside."?
Interpretation 1 - A library containing three copies of the same load module, but with 3 different names
Interpretation 2 - A single load module with several copies of one module with different names, since you cannot have 2 modules with one name.
The following JCL can achieve both interpretations.
//A EXEC PGM=IEFBR14
//XLOAD DD DISP=(MOD,DELETE),UNIT=SYSALLDA,SPACE=(TRK,0),
// DSN=&SYSUID..PVX.XLOAD
//SYSTSPRT DD DISP=(MOD,DELETE),UNIT=SYSALLDA,SPACE=(TRK,0),
// DSN=&SYSUID..PVX.SYSTSPRT
//B EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=*
//I DD DISP=(SHR,PASS),DSN=&SYSUID..PVX.LOAD
//O DD DISP=(,CATLG),UNIT=SYSDA,SPACE=(TRK,(2,2,1),RLSE),
// DSN=*.A.XLOAD
//SYSIN DD *
C I=I,O=O
S M=PVX
C I=I,O=O
S M=((PVX,PVXCOPY1))
C I=I,O=O
S M=((PVX,PVXCOPY2))
//C EXEC PGM=IEWL,PARM='MAP,LIST'
//SYSPRINT DD SYSOUT=*
//I DD DISP=(SHR,PASS),DSN=&SYSUID..PVX.LOAD
//SYSLMOD DD DISP=(OLD,PASS),DSN=*.A.XLOAD
//SYSLIN DD *
INCLUDE I(PVX)
CHANGE PVX(PVXCOPY1)
INCLUDE I(PVX)
CHANGE PVX(PVXCOPY2)
INCLUDE I(PVX)
ENTRY PVX
NAME PVXCOPY3
//D EXEC PGM=IKJEFT01
//STEPLIB DD DISP=SHR,DSN=&SYSUID..LOAD
//SYSTSPRT DD DISP=(,CATLG),UNIT=SYSDA,SPACE=(TRK,(1,1)),
// DCB=(RECFM=VB,LRECL=120,DSORG=PS),DSN=*.A.SYSTSPRT
//SYSTSIN DD *
LISTPDS (PVX.LOAD PVX.XLOAD)
LMATTR (PVX.XLOAD(PVX) PVX.XLOAD(PVXCOPY1) PVX.XLOAD(PVXCOPY2) +
PVX.XLOAD(PVXCOPY3))
//E EXEC PGM=PRINTDS
//STEPLIB DD DISP=SHR,DSN=&SYSUID..LOAD
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DISP=OLD,DSN=*.A.SYSTSPRT
Step A deletes any previous examples of two data sets.
Step B copies module PVX, with 3 load module names.
Step C builds load module PVXCOPY3, with several copies of module PVX.
Step D runs several TSO commands in batch to list the data set constructed in steps B and C. The LMATTR and LISTPDS commands are private TSO commands as is the PRINTDS program in step E.
Step E prints the output of step D. This is the output.
READY
LISTPDS (PVX.LOAD PVX.XLOAD)
XXXXXX.PVX.LOAD ON VVVV34
-MEMBER- --TTRC-- ALIAS OF -SIZE- -----ATTRIBUTES----- AM RM AC SSI
PVX 0000042C 000F78 24 24 00
2 ALLOCATED DIRECTORY BLOCKS, 1 USED DIRECTORY BLOCKS
XXXXXX.PVX.XLOAD ON VVVV30
-MEMBER- --TTRC-- ALIAS OF -SIZE- -----ATTRIBUTES----- AM RM AC SSI
PVX 0000032C 000F78 24 24 00
PVXCOPY1 00000B2C 000F78 24 24 00
PVXCOPY2 0000132C 000F78 24 24 00
PVXCOPY3 00001B2C 002E68 24 24 00
1 ALLOCATED DIRECTORY BLOCKS, 1 USED DIRECTORY BLOCKS
READY
LMATTR (PVX.XLOAD(PVX) PVX.XLOAD(PVXCOPY1) PVX.XLOAD(PVXCOPY2) PVX.XLOAD(PVXCOPY3))
XXXXXX.PVX.XLOAD(PVX) EXECUTABLE,F-LEVEL,SIZE=F78,EP=0,AC=0,RMODE=24,AMODE=24
MODULE LINKED BY 5695PMB01 ON 12/13/19
NAME TYPE MODE ADDR LENGTH NAME MODE ADDR OFFSET
PVX SD 22 0 F78
XXXXXX.PVX.XLOAD(PVXCOPY1) EXECUTABLE,F-LEVEL,SIZE=F78,EP=0,AC=0,RMODE=24,AMODE=24
MODULE LINKED BY 5695PMB01 ON 12/13/19
NAME TYPE MODE ADDR LENGTH NAME MODE ADDR OFFSET
PVX SD 22 0 F78
XXXXXX.PVX.XLOAD(PVXCOPY2) EXECUTABLE,F-LEVEL,SIZE=F78,EP=0,AC=0,RMODE=24,AMODE=24
MODULE LINKED BY 5695PMB01 ON 12/13/19
NAME TYPE MODE ADDR LENGTH NAME MODE ADDR OFFSET
PVX SD 22 0 F78
XXXXXX.PVX.XLOAD(PVXCOPY3) EXECUTABLE,F-LEVEL,SIZE=2E68,EP=0,AC=0,RMODE=24,AMODE=24
MODULE LINKED BY 5695PMB01 ON 12/13/19
NAME TYPE MODE ADDR LENGTH NAME MODE ADDR OFFSET
PVX SD 22 0 F78
PVXCOPY1 SD 22 F78 F78
PVXCOPY2 SD 22 1EF0 F78
READY
END