Opened 9 years ago

Last modified 18 months ago

#49104 assigned defect

star @1.5.2: mkdir: /etc/default: Operation not permitted

Reported by: rlhamil Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 2.3.4
Keywords: elcapitan Cc: kurthindenburg (Kurt Hindenburg), RobK88
Port: star

Description (last modified by ryandesign (Ryan Carsten Schmidt))

:info:destroot  ==> MAKING DIRECTORY "/etc/default"
:info:destroot mkdir: /etc/default: Operation not permitted

Even if /etc/default is created and made mode 777, failures creating files under it still occur. This might be a side-effect of SIP controls or settings, but happens even with it turned off, although one can create the directory and files as root.

Log attached.

Attachments (1)

main.log.txt (130.3 KB) - added by rlhamil 9 years ago.
build log file

Download all attachments as: .zip

Change History (12)

Changed 9 years ago by rlhamil

Attachment: main.log.txt added

build log file

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

Cc: rlhamil@… removed
Description: modified (diff)
Keywords: elcapitan added
Owner: changed from macports-tickets@… to mww@…
Port: star added
Summary: star install fails on El Capitanstar @1.5.2: mkdir: /etc/default: Operation not permitted

comment:2 Changed 8 years ago by kurthindenburg (Kurt Hindenburg)

Cc: khindenburg@… added

Cc Me!

comment:3 Changed 8 years ago by kurthindenburg (Kurt Hindenburg)

It looks like the new home is https://sourceforge.net/projects/star/ but it hasn't been updated in a long time - I wonder if this port should just be removed

comment:4 Changed 8 years ago by kurthindenburg (Kurt Hindenburg)

Owner: changed from mww@… to macports-tickets@…
Status: newassigned

comment:5 Changed 18 months ago by RobK88

Why don't we just tell the port to create /opt/local/etc/default instead on /etc/default?

comment:6 Changed 18 months ago by RobK88

Cc: RobK88 added

comment:7 Changed 18 months ago by RobK88

The fix is found in the compile.README file found in the source tarball.

"The location for the root specific configuration files is controlled via the INS_RBASE= make macro. 
The default value for this macro is "/".
If you like to install global default configuration files into 
/usr/local/etc instead of /etc, you need to specify INS_RBASE=/usr/local"

(Typos in original fixed)

So it looks like we will need to change destroot.destdir in the portfile for the star port to:

destroot.destdir    INS_BASE=${destroot}${prefix} \
                    INS_RBASE=${destroot}${prefix} \
                    MANDIR=man

The portfile for the star port also needs to be updated in other places as well. master-sites needs to be updated. And there is a newer version of the star archiver.

And finally, the post-destroot script in thestar port should delete even more files (like has been done in the ports of other package managers).

When I get home in a few weeks, I will update the portfile and submit a Pull Request (PR).

Last edited 18 months ago by RobK88 (previous) (diff)

comment:8 Changed 18 months ago by RobK88

I have been able to get star v1.5.3 and v1.6 to compile and build just fine on my Mac running High Sierra.

With star v1.5.3, smake works as expected. But one cannot use smake when building the latest version ofstar - v1.6. One sees strange errors:

creating xconfig.h
	==> MAKING "all" ON SUBDIRECTORY "SRCROOT/conf"
	==> MAKING "all" ON SUBDIRECTORY "SRCROOT/inc"
	==> MAKING "all" ON SUBCOMPONENT "SRCROOT/inc/align_test.mk"
	==> MAKING DIRECTORY "OBJ/i386-darwin-clang"
	==> MAKING DIRECTORY "OBJ/i386-darwin-clang/man"
	==> MAKING DEPENDENCIES "OBJ/i386-darwin-clang/align_test.d"
smake: No such file or directory. Can not open 'OBJ/i386-darwin-clang/OBJ/i386-darwin-clang/align_test.d'.
smake: No such file or directory. *** Code 2 from command line for target 'all'.
smake: The following command caused the error:
for MK in align_test.mk avoffset.mk ;					\
	do								\
		(							\
		if [ -r ./$MK ] ; then					\
			echo "	==> MAKING \"all\" ON SUBCOMPONENT \"SRCROOT/inc/$MK\""; "smake" -f $MK  XARCH=x86_64-darwin-clang all;\
		else							\
			echo "NOTICE: Partial source (SRCROOT/inc/$MK) missing";\
		fi							\
		);							\
	done
smake: Couldn't make 'all'.
smake: Leaving  'smake'[1] from directory '/Users/rob/Downloads/star-1.6/inc'
smake: Default commandline target: 'all'
smake: Doing                       exit(1)
smake: Operation not permitted. *** Code 1 from command line for target 'all'.
smake: The following command caused the error:
list="";							\
	if [ -d TARGETS -a -f TARGETS/__slot ]; then				\
		list=`echo TARGETS/[0123456789][0123456789]* |			\
			sed -e 's;TARGETS/[0123456789][0123456789];;g' | sed -e 's;!@!;/;g'`;\
	fi;									\
	for DIR in ${list} ;							\
	do									\
		(								\
		echo "	==> MAKING \"all\" ON SUBDIRECTORY \"SRCROOT/$DIR\"";\
		if [ -d ./$DIR -a -r ./$DIR/Makefile ] ; then			\
			cd ./$DIR && "smake"  XARCH=x86_64-darwin-clang DIRNAME=SRCROOT/$DIR all;		\
		else								\
			echo "NOTICE: Partial source (SRCROOT/$DIR) missing";\
		fi								\
		);								\
	done
smake: Couldn't make 'all'

If one really wants to use smake, one can either fix the various makefiles or just create symlinks linking the bogus phantom directories to the real ones.

However, star v1.6 will build just fine using regular make. This is the easiest approach!

When I am back home in a few weeks, I will update the starportfile accordingly and will submit a Pull Request (PR).

comment:9 Changed 18 months ago by RobK88

I fixed the port. At least it runs well on High Sierra.

I have submitted a Pull Request (PR). See https://github.com/macports/macports-ports/pull/18616

comment:10 Changed 18 months ago by RobK88

P.S. Newer versions of star will build using smake but you must use a newer version of smake than provided by Macports. I have updated the smake port to the latest version (version 1.6) and have submitted a Pull Request (PR). See https://github.com/macports/macports-ports/pull/18655

Last edited 18 months ago by RobK88 (previous) (diff)

comment:11 Changed 18 months ago by RobK88

FYI -- I have successfully updated the port to v1.6. But v1.6.1 is the latest version. I am trying to get a working port for star v 1.6.1. See the Pull Request (PR). See ​https://github.com/macports/macports-ports/pull/18655

Note: See TracTickets for help on using tickets.