switch to cmake for build system
This commit is contained in:
		@@ -1,12 +0,0 @@
 | 
			
		||||
bin_PROGRAMS = cellar
 | 
			
		||||
cellar_CPPFLAGS = $(BOOST_CPPFLAGS)
 | 
			
		||||
cellar_LDFLAGS = $(BOOST_LDFLAGS) $(BOOST_SYSTEM_LIB) $(BOOST_FILESYSTEM_LIB)
 | 
			
		||||
cellar_SOURCES = commands.cpp cellar.cpp fs.cpp bottles.cpp
 | 
			
		||||
 | 
			
		||||
# Generated files
 | 
			
		||||
nodist_cellar_SOURCES = version.cpp
 | 
			
		||||
 | 
			
		||||
CLEANFILES = version.cpp
 | 
			
		||||
 | 
			
		||||
version.cpp: 
 | 
			
		||||
	$(COG) -d -o version.cpp version.cpp.cog
 | 
			
		||||
@@ -1,34 +0,0 @@
 | 
			
		||||
#ifndef __BOTTLES_HPP
 | 
			
		||||
#define __BOTTLES_HPP
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
#include <map>
 | 
			
		||||
#include <string>
 | 
			
		||||
 | 
			
		||||
#include "json.hpp"
 | 
			
		||||
 | 
			
		||||
using namespace std;
 | 
			
		||||
 | 
			
		||||
using json = nlohmann::json;
 | 
			
		||||
 | 
			
		||||
namespace cellar {
 | 
			
		||||
	namespace bottles {
 | 
			
		||||
        enum bottle_type {
 | 
			
		||||
            bottle_error,
 | 
			
		||||
            bottle_anonymous,
 | 
			
		||||
            bottle_labelled,
 | 
			
		||||
            bottle_symlink
 | 
			
		||||
        };
 | 
			
		||||
        class Bottle {
 | 
			
		||||
            public:
 | 
			
		||||
                bottle_type type;
 | 
			
		||||
                json config;
 | 
			
		||||
                string path;
 | 
			
		||||
                string canonical_path;
 | 
			
		||||
                Bottle();
 | 
			
		||||
        };
 | 
			
		||||
		map<string, Bottle> get_bottles();
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#endif // __BOTTLES_HPP
 | 
			
		||||
@@ -1,9 +0,0 @@
 | 
			
		||||
#ifndef __CELLAR_HPP
 | 
			
		||||
#define __CELLAR_HPP
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
namespace cellar {
 | 
			
		||||
    void print_header();
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#endif // __CELLAR_HPP
 | 
			
		||||
@@ -1,20 +0,0 @@
 | 
			
		||||
#ifndef __COMMANDS_HPP
 | 
			
		||||
#define __COMMANDS_HPP
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
#include <map>
 | 
			
		||||
#include <string>
 | 
			
		||||
#include <vector>
 | 
			
		||||
 | 
			
		||||
using namespace std;
 | 
			
		||||
namespace cellar {
 | 
			
		||||
    namespace commands {
 | 
			
		||||
        typedef void (*CommandFunction)(int, char*[]);
 | 
			
		||||
        extern map<string, CommandFunction> command_map;
 | 
			
		||||
 | 
			
		||||
        void add_command(string, CommandFunction);
 | 
			
		||||
        vector<string> list_commands();
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#endif // __COMMANDS_HPP
 | 
			
		||||
							
								
								
									
										16
									
								
								src/fs.hpp
									
									
									
									
									
								
							
							
						
						
									
										16
									
								
								src/fs.hpp
									
									
									
									
									
								
							@@ -1,16 +0,0 @@
 | 
			
		||||
#ifndef __FS_HPP
 | 
			
		||||
#define __FS_HPP
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
#include <string>
 | 
			
		||||
#include <vector>
 | 
			
		||||
 | 
			
		||||
using namespace std;
 | 
			
		||||
 | 
			
		||||
namespace cellar {
 | 
			
		||||
	namespace fs {
 | 
			
		||||
		extern vector<string> listdir(string path);
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#endif // __FS_HPP
 | 
			
		||||
							
								
								
									
										13003
									
								
								src/json.hpp
									
									
									
									
									
								
							
							
						
						
									
										13003
									
								
								src/json.hpp
									
									
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							@@ -1,15 +0,0 @@
 | 
			
		||||
#ifndef __VERSION_HPP
 | 
			
		||||
#define __VERSION_HPP
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
#include <string>
 | 
			
		||||
 | 
			
		||||
using namespace std;
 | 
			
		||||
 | 
			
		||||
namespace cellar {
 | 
			
		||||
    namespace version {
 | 
			
		||||
        string short_version();
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
#endif // __VERSION_HPP
 | 
			
		||||
		Reference in New Issue
	
	Block a user