Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

conda and make compatibility fixes #40

Merged
merged 2 commits into from
Mar 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
File renamed without changes.
4 changes: 2 additions & 2 deletions makefile
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,8 @@ findorb.o: findorb.cpp
clipfunc.o: clipfunc.cpp
$(CXX) $(CXXFLAGS) $(CURSES_FLAGS) $<

getstrex.o: getstrex.c
$(CC) $(CXXFLAGS) $(CURSES_FLAGS) $<
getstrex.o: getstrex.cpp
$(CXX) $(CXXFLAGS) $(CURSES_FLAGS) $<

$(FO_EXE): fo.o $(OBJS) $(RES_FILENAME)
$(CXX) -o $(FO_EXE) fo.o $(OBJS) $(LIBS) $(RES_FILENAME) $(LDFLAGS)
Expand Down
5 changes: 4 additions & 1 deletion miscell.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ void ensure_config_directory_exists()
// Going forward it'd be good to reqork Find_Orb to search for data in
// default directories if local copies don't exist
#include "prefix.h"
static char PREFIX_STATIC[500] = PREFIX;
void ensure_config_directory_exists()
{
if (!use_config_directory)
Expand All @@ -127,7 +128,9 @@ void ensure_config_directory_exists()
// The c_str() magic in the next line allows conda-build's prefix
// replacer to work as expected.
// See https://github.com/conda/conda-build/issues/1674 for details.
std::string prefix = std::string(PREFIX).c_str();
// Modified on 2023-03-17 to add PREFIX_STATIC as compilers have
// gotten too clever & the existing workaround stopped working.
std::string prefix = std::string(PREFIX_STATIC).c_str();

if (prefix == "~") {
// backwards compatibility; do nothing.
Expand Down