Move directory structure and preserve symlinks [duplicate]
Clash Royale CLAN TAG#URR8PPP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;
up vote
1
down vote
favorite
This question already has an answer here:
Merging folders with mv?
9 answers
I'm trying to work around a makefile issue where libraries are installed in the wrong place. Someone else wrote the makefile and it is not easy to fix. I'm trying to move the libraries after they have been installed. The installation includes permissions, symlinks on the BSDs, Linux and Solaris.
Given a prefix
of /usr/local
and libdir
of /usr/local/lib/64/
, the makefile is placing artifacts with libdir
under prefix
instead of treating libdir
as an absolute path. Here's part of the copying that goes on:
cp libcrypto.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libcrypto.pc
cp libssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libssl.pc
cp openssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/openssl.pc
I thought it would be relatively easy to take /usr/local//usr/local/*
and move the entire artifact tree to /usr/local
but it is turning out to be trickier than I thought.
I've tried several suggestions to move the directory, including How to move all files and folders via mv command and Move files and folders recursively on Linux. Each has suffered small problems, like relocating to /usr/local/lib/64/64/pkgconfig/openssl.pc
and not preserving symlinks.
Looking at the Linux mv(1)
man page I'm not even sure there are any guarantees on preserving permission and symlinks present in a directory. The Posix mv
command talks a little about permissions but it is in the context of writing to the destination directory.
I also tried stripping path components with $filename:$prefix
but it caused problems with symlinks. $filename:$prefix
is probably not Posix but I do have Bash.
My question is, is it even possible to do it portably on the BSDs, Linux, OS X and Solaris? If so, then how should I be doing it?
Here's the code I have cobbled together but it feels like it is wrong:
# Fix OpenSSL's broken directory structure
path="$PREFIX/$LIBDIR"
while [ $(echo "$path" | cut -c1-3) != "lib" ]
do
echo "PATH: $path"
path=$path#*/
done
echo "PATH: $path"
Here is the output:
PATH: /usr/local//usr/local/lib/64
PATH: usr/local//usr/local/lib/64
PATH: local//usr/local/lib/64
PATH: /usr/local/lib/64
PATH: usr/local/lib/64
PATH: local/lib/64
PATH: lib/64
Followed by:
cd "$PREFIX/$PREFIX"
mv "$path" "$PREFIX"
rm -rf "$PREFIX/$PREFIX"
command-line directory symlink move
marked as duplicate by jww, Community⦠Jul 22 at 4:11
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
 |Â
show 4 more comments
up vote
1
down vote
favorite
This question already has an answer here:
Merging folders with mv?
9 answers
I'm trying to work around a makefile issue where libraries are installed in the wrong place. Someone else wrote the makefile and it is not easy to fix. I'm trying to move the libraries after they have been installed. The installation includes permissions, symlinks on the BSDs, Linux and Solaris.
Given a prefix
of /usr/local
and libdir
of /usr/local/lib/64/
, the makefile is placing artifacts with libdir
under prefix
instead of treating libdir
as an absolute path. Here's part of the copying that goes on:
cp libcrypto.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libcrypto.pc
cp libssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libssl.pc
cp openssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/openssl.pc
I thought it would be relatively easy to take /usr/local//usr/local/*
and move the entire artifact tree to /usr/local
but it is turning out to be trickier than I thought.
I've tried several suggestions to move the directory, including How to move all files and folders via mv command and Move files and folders recursively on Linux. Each has suffered small problems, like relocating to /usr/local/lib/64/64/pkgconfig/openssl.pc
and not preserving symlinks.
Looking at the Linux mv(1)
man page I'm not even sure there are any guarantees on preserving permission and symlinks present in a directory. The Posix mv
command talks a little about permissions but it is in the context of writing to the destination directory.
I also tried stripping path components with $filename:$prefix
but it caused problems with symlinks. $filename:$prefix
is probably not Posix but I do have Bash.
My question is, is it even possible to do it portably on the BSDs, Linux, OS X and Solaris? If so, then how should I be doing it?
Here's the code I have cobbled together but it feels like it is wrong:
# Fix OpenSSL's broken directory structure
path="$PREFIX/$LIBDIR"
while [ $(echo "$path" | cut -c1-3) != "lib" ]
do
echo "PATH: $path"
path=$path#*/
done
echo "PATH: $path"
Here is the output:
PATH: /usr/local//usr/local/lib/64
PATH: usr/local//usr/local/lib/64
PATH: local//usr/local/lib/64
PATH: /usr/local/lib/64
PATH: usr/local/lib/64
PATH: local/lib/64
PATH: lib/64
Followed by:
cd "$PREFIX/$PREFIX"
mv "$path" "$PREFIX"
rm -rf "$PREFIX/$PREFIX"
command-line directory symlink move
marked as duplicate by jww, Community⦠Jul 22 at 4:11
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
It may be easier to fix the broken Makefile. What sets$libdir
to an absolute path instead of a relative one?
â roaima
Jul 19 at 23:16
@roaima - OpenSSL uses a template file calledMakefile.orig
. The problem is, they take the two variablesprefix
andlibdir
and turn them into 4 or 5 different variables. I tried tosed
them out a couple of years ago but I managed to break one thing or another doing so.
â jww
Jul 19 at 23:23
What./config
line did you use to generate theMakefile
?
â roaima
Jul 20 at 6:23
Thanks @roaima - I took your suggestion and revistied patching the makefile. It was easier to patch this time so I took that route. Also see Fix OpenSSL library paths. OpenSSL is the only project I know that forces folks to put the libraries under$prefix
.
â jww
Jul 22 at 4:08
@roaima - To answer your question theconfig
options are here. They areno-ssl2 no-ssl3 no-comp shared -DNDEBUG enable-ec_nistp_64_gcc_128 --prefix="/usr/local" --libdir="/usr/local/lib/64" -Wl,-L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags
.
â jww
Jul 22 at 4:23
 |Â
show 4 more comments
up vote
1
down vote
favorite
up vote
1
down vote
favorite
This question already has an answer here:
Merging folders with mv?
9 answers
I'm trying to work around a makefile issue where libraries are installed in the wrong place. Someone else wrote the makefile and it is not easy to fix. I'm trying to move the libraries after they have been installed. The installation includes permissions, symlinks on the BSDs, Linux and Solaris.
Given a prefix
of /usr/local
and libdir
of /usr/local/lib/64/
, the makefile is placing artifacts with libdir
under prefix
instead of treating libdir
as an absolute path. Here's part of the copying that goes on:
cp libcrypto.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libcrypto.pc
cp libssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libssl.pc
cp openssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/openssl.pc
I thought it would be relatively easy to take /usr/local//usr/local/*
and move the entire artifact tree to /usr/local
but it is turning out to be trickier than I thought.
I've tried several suggestions to move the directory, including How to move all files and folders via mv command and Move files and folders recursively on Linux. Each has suffered small problems, like relocating to /usr/local/lib/64/64/pkgconfig/openssl.pc
and not preserving symlinks.
Looking at the Linux mv(1)
man page I'm not even sure there are any guarantees on preserving permission and symlinks present in a directory. The Posix mv
command talks a little about permissions but it is in the context of writing to the destination directory.
I also tried stripping path components with $filename:$prefix
but it caused problems with symlinks. $filename:$prefix
is probably not Posix but I do have Bash.
My question is, is it even possible to do it portably on the BSDs, Linux, OS X and Solaris? If so, then how should I be doing it?
Here's the code I have cobbled together but it feels like it is wrong:
# Fix OpenSSL's broken directory structure
path="$PREFIX/$LIBDIR"
while [ $(echo "$path" | cut -c1-3) != "lib" ]
do
echo "PATH: $path"
path=$path#*/
done
echo "PATH: $path"
Here is the output:
PATH: /usr/local//usr/local/lib/64
PATH: usr/local//usr/local/lib/64
PATH: local//usr/local/lib/64
PATH: /usr/local/lib/64
PATH: usr/local/lib/64
PATH: local/lib/64
PATH: lib/64
Followed by:
cd "$PREFIX/$PREFIX"
mv "$path" "$PREFIX"
rm -rf "$PREFIX/$PREFIX"
command-line directory symlink move
This question already has an answer here:
Merging folders with mv?
9 answers
I'm trying to work around a makefile issue where libraries are installed in the wrong place. Someone else wrote the makefile and it is not easy to fix. I'm trying to move the libraries after they have been installed. The installation includes permissions, symlinks on the BSDs, Linux and Solaris.
Given a prefix
of /usr/local
and libdir
of /usr/local/lib/64/
, the makefile is placing artifacts with libdir
under prefix
instead of treating libdir
as an absolute path. Here's part of the copying that goes on:
cp libcrypto.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libcrypto.pc
cp libssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/libssl.pc
cp openssl.pc /usr/local//usr/local/lib/64/pkgconfig
chmod 644 /usr/local//usr/local/lib/64/pkgconfig/openssl.pc
I thought it would be relatively easy to take /usr/local//usr/local/*
and move the entire artifact tree to /usr/local
but it is turning out to be trickier than I thought.
I've tried several suggestions to move the directory, including How to move all files and folders via mv command and Move files and folders recursively on Linux. Each has suffered small problems, like relocating to /usr/local/lib/64/64/pkgconfig/openssl.pc
and not preserving symlinks.
Looking at the Linux mv(1)
man page I'm not even sure there are any guarantees on preserving permission and symlinks present in a directory. The Posix mv
command talks a little about permissions but it is in the context of writing to the destination directory.
I also tried stripping path components with $filename:$prefix
but it caused problems with symlinks. $filename:$prefix
is probably not Posix but I do have Bash.
My question is, is it even possible to do it portably on the BSDs, Linux, OS X and Solaris? If so, then how should I be doing it?
Here's the code I have cobbled together but it feels like it is wrong:
# Fix OpenSSL's broken directory structure
path="$PREFIX/$LIBDIR"
while [ $(echo "$path" | cut -c1-3) != "lib" ]
do
echo "PATH: $path"
path=$path#*/
done
echo "PATH: $path"
Here is the output:
PATH: /usr/local//usr/local/lib/64
PATH: usr/local//usr/local/lib/64
PATH: local//usr/local/lib/64
PATH: /usr/local/lib/64
PATH: usr/local/lib/64
PATH: local/lib/64
PATH: lib/64
Followed by:
cd "$PREFIX/$PREFIX"
mv "$path" "$PREFIX"
rm -rf "$PREFIX/$PREFIX"
This question already has an answer here:
Merging folders with mv?
9 answers
command-line directory symlink move
edited Jul 19 at 22:05
asked Jul 19 at 21:20
jww
1,38722053
1,38722053
marked as duplicate by jww, Community⦠Jul 22 at 4:11
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
marked as duplicate by jww, Community⦠Jul 22 at 4:11
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
It may be easier to fix the broken Makefile. What sets$libdir
to an absolute path instead of a relative one?
â roaima
Jul 19 at 23:16
@roaima - OpenSSL uses a template file calledMakefile.orig
. The problem is, they take the two variablesprefix
andlibdir
and turn them into 4 or 5 different variables. I tried tosed
them out a couple of years ago but I managed to break one thing or another doing so.
â jww
Jul 19 at 23:23
What./config
line did you use to generate theMakefile
?
â roaima
Jul 20 at 6:23
Thanks @roaima - I took your suggestion and revistied patching the makefile. It was easier to patch this time so I took that route. Also see Fix OpenSSL library paths. OpenSSL is the only project I know that forces folks to put the libraries under$prefix
.
â jww
Jul 22 at 4:08
@roaima - To answer your question theconfig
options are here. They areno-ssl2 no-ssl3 no-comp shared -DNDEBUG enable-ec_nistp_64_gcc_128 --prefix="/usr/local" --libdir="/usr/local/lib/64" -Wl,-L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags
.
â jww
Jul 22 at 4:23
 |Â
show 4 more comments
It may be easier to fix the broken Makefile. What sets$libdir
to an absolute path instead of a relative one?
â roaima
Jul 19 at 23:16
@roaima - OpenSSL uses a template file calledMakefile.orig
. The problem is, they take the two variablesprefix
andlibdir
and turn them into 4 or 5 different variables. I tried tosed
them out a couple of years ago but I managed to break one thing or another doing so.
â jww
Jul 19 at 23:23
What./config
line did you use to generate theMakefile
?
â roaima
Jul 20 at 6:23
Thanks @roaima - I took your suggestion and revistied patching the makefile. It was easier to patch this time so I took that route. Also see Fix OpenSSL library paths. OpenSSL is the only project I know that forces folks to put the libraries under$prefix
.
â jww
Jul 22 at 4:08
@roaima - To answer your question theconfig
options are here. They areno-ssl2 no-ssl3 no-comp shared -DNDEBUG enable-ec_nistp_64_gcc_128 --prefix="/usr/local" --libdir="/usr/local/lib/64" -Wl,-L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags
.
â jww
Jul 22 at 4:23
It may be easier to fix the broken Makefile. What sets
$libdir
to an absolute path instead of a relative one?â roaima
Jul 19 at 23:16
It may be easier to fix the broken Makefile. What sets
$libdir
to an absolute path instead of a relative one?â roaima
Jul 19 at 23:16
@roaima - OpenSSL uses a template file called
Makefile.orig
. The problem is, they take the two variables prefix
and libdir
and turn them into 4 or 5 different variables. I tried to sed
them out a couple of years ago but I managed to break one thing or another doing so.â jww
Jul 19 at 23:23
@roaima - OpenSSL uses a template file called
Makefile.orig
. The problem is, they take the two variables prefix
and libdir
and turn them into 4 or 5 different variables. I tried to sed
them out a couple of years ago but I managed to break one thing or another doing so.â jww
Jul 19 at 23:23
What
./config
line did you use to generate the Makefile
?â roaima
Jul 20 at 6:23
What
./config
line did you use to generate the Makefile
?â roaima
Jul 20 at 6:23
Thanks @roaima - I took your suggestion and revistied patching the makefile. It was easier to patch this time so I took that route. Also see Fix OpenSSL library paths. OpenSSL is the only project I know that forces folks to put the libraries under
$prefix
.â jww
Jul 22 at 4:08
Thanks @roaima - I took your suggestion and revistied patching the makefile. It was easier to patch this time so I took that route. Also see Fix OpenSSL library paths. OpenSSL is the only project I know that forces folks to put the libraries under
$prefix
.â jww
Jul 22 at 4:08
@roaima - To answer your question the
config
options are here. They are no-ssl2 no-ssl3 no-comp shared -DNDEBUG enable-ec_nistp_64_gcc_128 --prefix="/usr/local" --libdir="/usr/local/lib/64" -Wl,-L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags
.â jww
Jul 22 at 4:23
@roaima - To answer your question the
config
options are here. They are no-ssl2 no-ssl3 no-comp shared -DNDEBUG enable-ec_nistp_64_gcc_128 --prefix="/usr/local" --libdir="/usr/local/lib/64" -Wl,-L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags
.â jww
Jul 22 at 4:23
 |Â
show 4 more comments
1 Answer
1
active
oldest
votes
up vote
2
down vote
I think my suggestion would be to leave it in place and just create a link in /usr/local/lib/
that links to this directory /usr/local/lib/64/
.
For example:
$ tree usr/
usr/
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂààâÂÂâÂÂâ 64 -> ../usr/local/lib/64
âÂÂâÂÂâ usr
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂâÂÂâ 64
âÂÂâÂÂâ pkgconfig
I made it like this:
$ cd /usr/local/lib/
$ ln -s ../usr/local/lib/64 64
This somewhat normalizes the tree so this works:
$ ls usr/local/lib/64/
pkgconfig
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
1
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get thetar
trick to work withsudo
. Thanks again for your help.
â jww
Jul 22 at 4:12
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
I think my suggestion would be to leave it in place and just create a link in /usr/local/lib/
that links to this directory /usr/local/lib/64/
.
For example:
$ tree usr/
usr/
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂààâÂÂâÂÂâ 64 -> ../usr/local/lib/64
âÂÂâÂÂâ usr
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂâÂÂâ 64
âÂÂâÂÂâ pkgconfig
I made it like this:
$ cd /usr/local/lib/
$ ln -s ../usr/local/lib/64 64
This somewhat normalizes the tree so this works:
$ ls usr/local/lib/64/
pkgconfig
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
1
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get thetar
trick to work withsudo
. Thanks again for your help.
â jww
Jul 22 at 4:12
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
add a comment |Â
up vote
2
down vote
I think my suggestion would be to leave it in place and just create a link in /usr/local/lib/
that links to this directory /usr/local/lib/64/
.
For example:
$ tree usr/
usr/
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂààâÂÂâÂÂâ 64 -> ../usr/local/lib/64
âÂÂâÂÂâ usr
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂâÂÂâ 64
âÂÂâÂÂâ pkgconfig
I made it like this:
$ cd /usr/local/lib/
$ ln -s ../usr/local/lib/64 64
This somewhat normalizes the tree so this works:
$ ls usr/local/lib/64/
pkgconfig
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
1
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get thetar
trick to work withsudo
. Thanks again for your help.
â jww
Jul 22 at 4:12
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
add a comment |Â
up vote
2
down vote
up vote
2
down vote
I think my suggestion would be to leave it in place and just create a link in /usr/local/lib/
that links to this directory /usr/local/lib/64/
.
For example:
$ tree usr/
usr/
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂààâÂÂâÂÂâ 64 -> ../usr/local/lib/64
âÂÂâÂÂâ usr
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂâÂÂâ 64
âÂÂâÂÂâ pkgconfig
I made it like this:
$ cd /usr/local/lib/
$ ln -s ../usr/local/lib/64 64
This somewhat normalizes the tree so this works:
$ ls usr/local/lib/64/
pkgconfig
I think my suggestion would be to leave it in place and just create a link in /usr/local/lib/
that links to this directory /usr/local/lib/64/
.
For example:
$ tree usr/
usr/
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂààâÂÂâÂÂâ 64 -> ../usr/local/lib/64
âÂÂâÂÂâ usr
âÂÂâÂÂâ local
âÂÂâÂÂâ lib
âÂÂâÂÂâ 64
âÂÂâÂÂâ pkgconfig
I made it like this:
$ cd /usr/local/lib/
$ ln -s ../usr/local/lib/64 64
This somewhat normalizes the tree so this works:
$ ls usr/local/lib/64/
pkgconfig
answered Jul 19 at 22:12
slmâ¦
232k65479649
232k65479649
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
1
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get thetar
trick to work withsudo
. Thanks again for your help.
â jww
Jul 22 at 4:12
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
add a comment |Â
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
1
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get thetar
trick to work withsudo
. Thanks again for your help.
â jww
Jul 22 at 4:12
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
This is the problem I am hitting now: Merging folders with mv? It looks like @gjs has an insightful solution. I wish OpenSSL would do this stuff correctly from the start. It would save so many man-hours later.
â jww
Jul 19 at 22:46
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
@jww I had that favorited and upvoted ðÂÂÂ
â slmâ¦
Jul 19 at 22:57
1
1
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get the
tar
trick to work with sudo
. Thanks again for your help.â jww
Jul 22 at 4:12
I closed this question as a dup of the answer in Merging folders with mv? I ended up going back to Makefile patching because I could not get the
tar
trick to work with sudo
. Thanks again for your help.â jww
Jul 22 at 4:12
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
@jww - sure thing, thanks for letting me know.
â slmâ¦
Jul 22 at 4:14
add a comment |Â
It may be easier to fix the broken Makefile. What sets
$libdir
to an absolute path instead of a relative one?â roaima
Jul 19 at 23:16
@roaima - OpenSSL uses a template file called
Makefile.orig
. The problem is, they take the two variablesprefix
andlibdir
and turn them into 4 or 5 different variables. I tried tosed
them out a couple of years ago but I managed to break one thing or another doing so.â jww
Jul 19 at 23:23
What
./config
line did you use to generate theMakefile
?â roaima
Jul 20 at 6:23
Thanks @roaima - I took your suggestion and revistied patching the makefile. It was easier to patch this time so I took that route. Also see Fix OpenSSL library paths. OpenSSL is the only project I know that forces folks to put the libraries under
$prefix
.â jww
Jul 22 at 4:08
@roaima - To answer your question the
config
options are here. They areno-ssl2 no-ssl3 no-comp shared -DNDEBUG enable-ec_nistp_64_gcc_128 --prefix="/usr/local" --libdir="/usr/local/lib/64" -Wl,-L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags
.â jww
Jul 22 at 4:23