2014-04-03 01:45:22 +02:00
|
|
|
#!/bin/bash
|
|
|
|
#
|
|
|
|
# This script is automatically invoked by Makefiles and should not be invoked
|
|
|
|
# by users.
|
|
|
|
# Creates the Makefile.depend file. This file contains all the external source
|
|
|
|
# files included by including other modules.
|
|
|
|
# Thu Apr 3 01:44:09 CEST 2014
|
|
|
|
|
|
|
|
SRC=""
|
|
|
|
OBJ=""
|
2014-09-02 16:22:00 +02:00
|
|
|
DEPS="$(cat NEEDED_MODULES)"
|
2014-04-03 01:45:22 +02:00
|
|
|
|
|
|
|
for M in ${DEPS}
|
|
|
|
do
|
|
|
|
# X is the list of external source files
|
2014-09-02 16:22:00 +02:00
|
|
|
X=$(grep 'SRC=' "${QPACKAGE_ROOT}/src/${M}/Makefile" 2>/dev/null |cut -d '=' -f 2)
|
2014-04-03 01:45:22 +02:00
|
|
|
for f in ${X}
|
|
|
|
do
|
|
|
|
SRC+=" ${M}/${f}"
|
|
|
|
done
|
2014-09-02 16:22:00 +02:00
|
|
|
X=$(grep 'OBJ=' "${QPACKAGE_ROOT}/src/${M}/Makefile" 2>/dev/null |cut -d '=' -f 2)
|
2014-04-03 01:45:22 +02:00
|
|
|
for f in ${X}
|
|
|
|
do
|
|
|
|
OBJ+=" IRPF90_temp/${M}/${f/IRPF90_temp//}"
|
|
|
|
done
|
|
|
|
done
|
|
|
|
|
|
|
|
# Create the Makefile.depend
|
|
|
|
cat << EOF > Makefile.depend
|
|
|
|
# This file was created by the $0 script. Do not modify it by hand.
|
|
|
|
|
|
|
|
SRC+=${SRC}
|
|
|
|
OBJ+=${OBJ}
|
|
|
|
EOF
|
|
|
|
|
|
|
|
|