[petsc-dev] Running dsymutil in GNU make build
Lisandro Dalcin
dalcinl at gmail.com
Mon Nov 4 02:01:32 CST 2013
Do you like moving the execution of dsymutil from
$PETSC_DIR/conf/rules to $PETSC_DIR/gmakefile shared lib targets? The
rationale is to not run dsymutil with the shared libs are up to date.
diff --git a/conf/rules b/conf/rules
index 1ac6fe0..6bf2421 100644
--- a/conf/rules
+++ b/conf/rules
@@ -105,9 +105,6 @@ gnumake: chk_makej
@echo "Building PETSc using GNU Make with ${MAKE_NP} build threads"
@echo "=========================================="
@cd ${PETSC_DIR} && ${OMAKE_PRINTDIR} -f gmakefile -j ${MAKE_NP} V=${V}
- @if [ "${BUILDSHAREDLIB}" = "yes" -a "${DSYMUTIL}" != "true" ]; then \
- echo "Running ${DSYMUTIL} on ${SHLIBS}";\
- for LIBNAME in ${SHLIBS}; do ${DSYMUTIL}
${INSTALL_LIB_DIR}/$$LIBNAME.${SL_LINKER_SUFFIX}; done; fi
@echo "========================================="
# Does nothing; needed for some rules that require actions.
diff --git a/gmakefile b/gmakefile
index afba46c..525c081 100644
--- a/gmakefile
+++ b/gmakefile
@@ -69,6 +69,9 @@ srcs.o := $(foreach pkg, $(pkgs), $(call concatlang,$(pkg)))
# with-single-library=1 (default)
$(libpetsc_shared) : $(srcs.o) | $$(@D)/.DIR
$(call quiet,CLINKER) -shared -o $@ $^ $(PETSC_EXTERNAL_LIB_BASIC)
+ifneq ($(DSYMUTIL),true)
+ $(call quiet,DSYMUTIL) $@
+endif
$(libpetsc_static) : obj := $(srcs.o)
@@ -124,6 +127,9 @@ else
endif
$(libpetscpkgs_shared) : $$(obj) $(libdep_true) | $(libdep_order) $$(@D)/.DIR
$(call quiet,CLINKER) -shared -o $@ $(obj) $(libdep)
$(PETSC_EXTERNAL_LIB_BASIC)
+ifneq ($(DSYMUTIL),true)
+ $(call quiet,DSYMUTIL) $@
+endif
$(OBJDIR)/%.o : %.c | $$(@D)/.DIR
$(PETSC_COMPILE.c) $< -o $@
--
Lisandro Dalcin
---------------
CIMEC (UNL/CONICET)
Predio CONICET-Santa Fe
Colectora RN 168 Km 472, Paraje El Pozo
3000 Santa Fe, Argentina
Tel: +54-342-4511594 (ext 1016)
Tel/Fax: +54-342-4511169
More information about the petsc-dev
mailing list