--- rpl/src/Makefile.am 2010/08/06 15:26:42 1.29 +++ rpl/src/Makefile.am 2010/08/12 14:13:57 1.33 @@ -233,8 +233,8 @@ INIT_EXE=init.c INIT_LIB=librpl.c -# @MALLOC@ doit être la première bibliothèque pour éviter que la libgfortran -# utilise un allocateur différent. +# @MALLOC@ doit être la première bibliothèque pour éviter que la libgfortran +# utilise un allocateur différent. LIB=-lz @MALLOC@ bin_PROGRAMS = rpl @@ -392,7 +392,7 @@ nodist_rpl_SOURCES = \ $(SRCCc) $(SRCHc) $(SRCFc) $(SRCF90c) $(INIT_EXEc) \ $(SRCXPM) $(SRCINCc) rpl_LDFLAGS = -g @PROFILAGE@ $(LIB) @EXPORT_DYNAMIC@ -rpl_CFLAGS = $(AM_CFLAGS) -std=gnu99 -Wall -Wextra -Wno-unused-function \ +rpl_CFLAGS = $(AM_CFLAGS) @C_STANDARD@ -Wall -Wextra -Wno-unused-function \ -Wno-pointer-sign -Wno-unused-parameter @NESTED_FUNCTIONS@ rpl_FFLAGS = $(AM_FFLAGS) -fno-f2c rpl_FCFLAGS = $(AM_FCFLAGS) -fno-second-underscore -fno-f2c @@ -400,7 +400,7 @@ rpl_FCFLAGS = $(AM_FCFLAGS) -fno-second- nodist_librpl_a_SOURCES = \ $(SRCCc) $(SRCHc) $(SRCFc) $(SRCF90c) $(INIT_LIBc) \ $(SRCXPM) $(SRCINCc) -librpl_a_CFLAGS = $(AM_CFLAGS) -std=gnu99 -Wall -Wextra -Wno-unused-function \ +librpl_a_CFLAGS = $(AM_CFLAGS) @C_STANDARD@ -Wall -Wextra -Wno-unused-function \ -Wno-pointer-sign -Wno-unused-parameter @NESTED_FUNCTIONS@ librpl_a_FFLAGS = $(AM_FFLAGS) -ff2c librpl_a_FCFLAGS = $(AM_FCLAGS) -fno-second-underscore @@ -416,7 +416,7 @@ DEFS = -DHAVE_CONFIG_H -Dd_version_rpl=\ -Dd_exec_path=\"@RUNPATH@\" @FORCE_GNUPLOT_PATH@ @DEBUG@ \ @MOTIF_SUPPORT@ @POSTSCRIPT_SUPPORT@ @GNUPLOT_SUPPORT@ \ @VIM_SUPPORT@ @MYSQL_SUPPORT@ @POSTGRESQL_SUPPORT@ \ - @SEMAPHORES_NOMMES@ \ + @SEMAPHORES_NOMMES@ @SEMAPHORES_SYSV@ @SEMUN@ @IPV6@ \ @EXPERIMENTAL_CODE@ $(date) $(hash) -g @PROFILAGE@ \ -Dd_locale=\"@FINAL_ENCODING@\" \ -D@OS@ @@ -442,8 +442,10 @@ all-local: always install-exec-local: librpl librpl: install-libLIBRARIES - if [ ! -d $(top_builddir)/librpl ]; then mkdir -p $(top_builddir)/librpl; fi - \rm -rf $(top_builddir)/librpl/* + if [ -d $(top_builddir)/librpl ]; then \ + rm -rf $(top_builddir)/librpl; \ + fi + mkdir -p $(top_builddir)/librpl; \ for i in $(top_builddir)/src/librpl.a \ @MALLOC@ \ $(ldadd_libhistory) $(ldadd_libreadline) \ @@ -452,11 +454,17 @@ librpl: install-libLIBRARIES $(ldadd_libncurses) $(ldadd_libgsl) $(ldadd_libiconv) \ $(ldadd_libcrypto) $(ldadd_libssl) $(ldadd_libsqlite); \ do \ - \cp -f $$i $(top_builddir)/librpl; \ + cp -f $$i $(top_builddir)/librpl; \ done - (cd $(top_builddir)/librpl && \ - for i in *.a; do ar x $$i && \rm -f $$i; done; \ - ar cr librpl.a *) - \mv -f $(top_builddir)/librpl/librpl.a $(top_builddir)/src/librpl.a - \rm -rf $(top_builddir)/librpl - $(RANLIB) $(top_builddir)/src/librpl.a + if [ @OS@ = OS2 ]; then \ + (cd $(top_builddir)/librpl && \ + for i in *.a; do ar x $$i && rm -f $$i; done && \ + for i in *.$(OBJEXT); do ar cru librpl.a $$i; done && \ + ar s librpl.a;); \ + else \ + (cd $(top_builddir)/librpl && \ + for i in *.a; do ar x $$i && rm -f $$i; done; \ + ar crs librpl.a *.$(OBJEXT);); \ + fi + mv -f $(top_builddir)/librpl/librpl.a $(top_builddir)/src/librpl.a +