Opened 4 years ago

Closed 4 years ago

#60603 closed defect (fixed)

nss @3.53 does not build on PPC Tiger, Mac OS X 10.4.11, because *** missing `endif'

Reported by: ballapete (Peter "Pete" Dyballa) Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.6.2
Keywords: tiger Cc:
Port: nss

Description

--->  Building nss
DEBUG: Executing org.macports.build (nss)
DEBUG: port disallows a parallel build
DEBUG: Environment: 
CC_PRINT_OPTIONS='YES'
CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/.CC_PRINT_OPTIONS'
CPATH='/opt/local/include'
DEVELOPER_DIR='/Developer'
LIBRARY_PATH='/opt/local/lib'
MACOSX_DEPLOYMENT_TARGET='10.4'
Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss" && /usr/bin/make -w all NSS_DISABLE_GTESTS=1 NSS_ENABLE_WERROR=0 CC="/opt/local/bin/gcc-apple-4.2 -Os -std=c99 -arch ppc" CCC="/opt/local/bin/g++-apple-4.2 -Os -arch ppc" NSPR_INCLUDE_DIR=/opt/local/include/nspr NSPR_LIB_DIR=/opt/local/lib/nspr NSS_USE_SYSTEM_SQLITE=1 USE_SYSTEM_ZLIB=1 BUILD_OPT=1 OPTIMIZER="-Os" OBJDIR_NAME="Output.OBJD" 
DEBUG: system:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss" && /usr/bin/make -w all NSS_DISABLE_GTESTS=1 NSS_ENABLE_WERROR=0 CC="/opt/local/bin/gcc-apple-4.2 -Os -std=c99 -arch ppc" CCC="/opt/local/bin/g++-apple-4.2 -Os -arch ppc" NSPR_INCLUDE_DIR=/opt/local/include/nspr NSPR_LIB_DIR=/opt/local/lib/nspr NSS_USE_SYSTEM_SQLITE=1 USE_SYSTEM_ZLIB=1 BUILD_OPT=1 OPTIMIZER="-Os" OBJDIR_NAME="Output.OBJD" 
make: Entering directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss'
coreconf/arch.mk:150: CPU_ARCH is not x86_64, disabling -mavx2
# no real way to encode these in any sensible way
/usr/bin/make -C coreconf/nsinstall program
make[1]: Entering directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/coreconf/nsinstall'
../../coreconf/rules.mk:163: *** missing `endif'.  Stop.
make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/coreconf/nsinstall'
make: *** [prepare_build] Error 2

Reason, in work/nss-3.53/nss/coreconf/rules.mk:

  150	ifeq (,$$(filter-out _WIN%,$$(NS_USE_GCC)_$$(OS_TARGET)))
  151		$$(MKPROG) $$($(1)_OBJS) -Fe$$@ -link $$(LDFLAGS) $$(XLDFLAGS) $$(EXTRA_LIBS) $$(EXTRA_SHARED_LIBS) $$(OS_LIBS)
  152	ifdef MT
  153		if test -f $$@.manifest; then \
  154			$$(MT) -NOLOGO -MANIFEST $$@.manifest -OUTPUTRESOURCE:$$@\;1; \
  155			rm -f $$@.manifest; \
  156		fi
  157	endif	# MSVC with manifest tool
  158	else
  159		$$(MKPROG) -o $$@ $$(CFLAGS) $$($(1)_OBJS) $$(LDFLAGS) $$(EXTRA_LIBS) $$(EXTRA_SHARED_LIBS) $$(OS_LIBS)
  160	endif
  161	endef # PROGRAM_template

Attachments (2)

main.log (12.1 KB) - added by ballapete (Peter "Pete" Dyballa) 4 years ago.
Main.log from PPC Tiger, Mac OS X 10.4.11
patch-endef.diff (1.9 KB) - added by ballapete (Peter "Pete" Dyballa) 4 years ago.
Patch file to convert endef into endif

Download all attachments as: .zip

Change History (13)

Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.log added

Main.log from PPC Tiger, Mac OS X 10.4.11

comment:1 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

Tiger's version of make is old. Try using the newer one from the gmake port instead.

comment:2 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

This patch file corrects all occurrences of endef but the build still fails:

DEBUG: system:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53" && /usr/bin/patch -p0 < '/opt/local/var/macports/sources/nue.de.rsync.macports.org/macports/release/tarballs/ports/net/nss/files/patch-endef.diff'
patching file nss/coreconf/rules.mk
patching file nss/coreconf/ruleset.mk
patching file nss/coreconf/UNIX.mk
patching file nss/coreconf/OS2.mk
patching file nss/coreconf/WIN32.mk
DEBUG: Executing proc-post-org.macports.patch-patch-0
--->  Patching Darwin.mk: s|@executable_path|/opt/local/lib/nss|g
DEBUG: Executing reinplace: /usr/bin/sed s|@executable_path|/opt/local/lib/nss|g </opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/coreconf/Darwin.mk >@file10
DEBUG: euid/egid changed to: 0/0
DEBUG: chowned /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/coreconf/Darwin.mk to macports
DEBUG: euid/egid changed to: 506/502
DEBUG: euid/egid changed to: 0/0
DEBUG: setting attributes on /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/coreconf/Darwin.mk
DEBUG: euid/egid changed to: 506/502
--->  Patching config.mk: s|@executable_path|/opt/local/lib/nss|g
DEBUG: Executing reinplace: /usr/bin/sed s|@executable_path|/opt/local/lib/nss|g </opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/lib/freebl/config.mk >@file10
DEBUG: euid/egid changed to: 0/0
DEBUG: chowned /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/lib/freebl/config.mk to macports
DEBUG: euid/egid changed to: 506/502
DEBUG: euid/egid changed to: 0/0
DEBUG: setting attributes on /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss/lib/freebl/config.mk
DEBUG: euid/egid changed to: 506/502
DEBUG: Privilege de-escalation not attempted as not running as root.
DEBUG: configure phase started at Sat Jun  6 01:53:29 CEST 2020
--->  Configuring nss
DEBUG: Preferred compilers: apple-gcc-4.2 gcc-4.0 macports-gcc-7 macports-gcc-6 macports-gcc-5 macports-clang-3.4 macports-clang-3.3
DEBUG: Using compiler 'MacPorts Apple GCC 4.2'
DEBUG: Executing org.macports.configure (nss)
DEBUG: Privilege de-escalation not attempted as not running as root.
DEBUG: build phase started at Sat Jun  6 01:53:30 CEST 2020
--->  Building nss
DEBUG: Executing org.macports.build (nss)
DEBUG: port disallows a parallel build
DEBUG: Environment: 
CC_PRINT_OPTIONS='YES'
CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/.CC_PRINT_OPTIONS'
CPATH='/opt/local/include'
DEVELOPER_DIR='/Developer'
LIBRARY_PATH='/opt/local/lib'
MACOSX_DEPLOYMENT_TARGET='10.4'
Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss" && /usr/bin/make -w all NSS_DISABLE_GTESTS=1 NSS_ENABLE_WERROR=0 CC="/opt/local/bin/gcc-apple-4.2 -Os -std=c99 -arch ppc" CCC="/opt/local/bin/g++-apple-4.2 -Os -arch ppc" NSPR_INCLUDE_DIR=/opt/local/include/nspr NSPR_LIB_DIR=/opt/local/lib/nspr NSS_USE_SYSTEM_SQLITE=1 USE_SYSTEM_ZLIB=1 BUILD_OPT=1 OPTIMIZER="-Os" OBJDIR_NAME="Output.OBJD" 
DEBUG: system:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss" && /usr/bin/make -w all NSS_DISABLE_GTESTS=1 NSS_ENABLE_WERROR=0 CC="/opt/local/bin/gcc-apple-4.2 -Os -std=c99 -arch ppc" CCC="/opt/local/bin/g++-apple-4.2 -Os -arch ppc" NSPR_INCLUDE_DIR=/opt/local/include/nspr NSPR_LIB_DIR=/opt/local/lib/nspr NSS_USE_SYSTEM_SQLITE=1 USE_SYSTEM_ZLIB=1 BUILD_OPT=1 OPTIMIZER="-Os" OBJDIR_NAME="Output.OBJD" 
make: Entering directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss'
coreconf/arch.mk:150: CPU_ARCH is not x86_64, disabling -mavx2
coreconf/UNIX.mk:56: *** missing `endef', unterminated `define'.  Stop.
make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss'
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_nss/nss/work/nss-3.53/nss" && /usr/bin/make -w all NSS_DISABLE_GTESTS=1 NSS_ENABLE_WERROR=0 CC="/opt/local/bin/gcc-apple-4.2 -Os -std=c99 -arch ppc" CCC="/opt/local/bin/g++-apple-4.2 -Os -arch ppc" NSPR_INCLUDE_DIR=/opt/local/include/nspr NSPR_LIB_DIR=/opt/local/lib/nspr NSS_USE_SYSTEM_SQLITE=1 USE_SYSTEM_ZLIB=1 BUILD_OPT=1 OPTIMIZER="-Os" OBJDIR_NAME="Output.OBJD" 
Exit code: 2
Error: Failed to build nss: command execution failed

Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: patch-endef.diff added

Patch file to convert endef into endif

comment:3 in reply to:  1 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to ryandesign:

Tiger's version of make is old. Try using the newer one from the gmake port instead.

How can this be achieved?

comment:4 Changed 4 years ago by kencu (Ken)

put this in the Portfile:

build.cmd gmake

comment:5 in reply to:  4 ; Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to kencu:

put this in the Portfile:

build.cmd gmake

By inserting this into Portfile allowed nss to build on PPC Tiger.

comment:6 Changed 4 years ago by kencu (Ken)

I had to do the same with perl5.28 on Tiger, BTW -- when you get to that one...

comment:7 in reply to:  6 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to kencu:

I had to do the same with perl5.28 on Tiger, BTW -- when you get to that one...

Could be I already passed this stage:

  perl5.28 @5.28.3_0 (active) platform='darwin 8' archs='ppc' date='2020-06-05T13:41:03+0200'
  perl5.30 @5.30.3_0 (active) platform='darwin 8' archs='ppc' date='2020-06-05T14:45:54+0200'

No problems encountered…

comment:8 in reply to:  5 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to ballapete:

This also worked to upgrade to nss @3.54.

comment:9 in reply to:  2 ; Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to ballapete:

This patch file corrects all occurrences of endef

Replacing endef with endif is not correct. endef and endif are different statements. endif ends an if statement while endef ends a define statement.

comment:10 in reply to:  9 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to ryandesign:

Replacing endef with endif is not correct. endef and endif are different statements. endif ends an if statement while endef ends a define statement.

Ah, alright! Thank you, I did not know of these two ends…

comment:11 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

Owner: set to ryandesign
Resolution: fixed
Status: newclosed

In 8bc578f675495f5c597185e218a6f67b69a4b363/macports-ports (master):

nss: Use newer gmake port on Tiger

Closes: #60603

Note: See TracTickets for help on using tickets.