Skip to content

Commit

Permalink
Refactor: Renamed libdeng1 to liblegacy (deng_legacy)
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed May 2, 2014
1 parent 5b376f9 commit c871117
Show file tree
Hide file tree
Showing 91 changed files with 115 additions and 119 deletions.
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -8,7 +8,7 @@ For [compilation instructions](http://dengine.net/dew/index.php?title=Compilatio

**libdeng2** is the core of Doomsday 2. It is a C++ class framework containing functionality such as the file system, plugin loading, Doomsday Script, network communications, and generic data structures. Almost everything relies or will rely on this core library.

**libdeng1** is a collection of C language routines extracted from the old Doomsday 1 code base. Its purpose is to (eventually) act as a C wrapper for libdeng2. (Game plugins are mostly in C.)
**liblegacy** is a collection of C language routines extracted from the old Doomsday 1 code base. Its purpose is to (eventually) act as a C wrapper for libdeng2. (Game plugins are mostly in C.)

**libgui** builds on libdeng2 to add low-level GUI capabilities such as OpenGL graphics, fonts, images, and input devices.

Expand Down
3 changes: 2 additions & 1 deletion distrib/win32/setup.iss.template
Expand Up @@ -51,6 +51,7 @@ Name: "{app}\doc"

; Obsolete files which should be removed if present when upgrading.
[InstallDelete]
Type: files; Name: "{app}\bin\deng1.dll"
Type: files; Name: "{app}\bin\libcurl.dll"
Type: files; Name: "{app}\bin\libpng15.dll"
Type: files; Name: "{app}\bin\SDL_net.dll"
Expand Down Expand Up @@ -91,7 +92,7 @@ Source: "bin\wadtool.exe"; DestDir: "{app}\bin"; Flags: ignoreversion; Component

; Libraries
Source: "..\win32\vcredist_x86.exe"; DestDir: "{app}\bin"; Flags: ignoreversion deleteafterinstall; Components: Engine
Source: "bin\deng1.dll"; DestDir: "{app}\bin"; Flags: ignoreversion; Components: Engine
Source: "bin\deng_legacy.dll"; DestDir: "{app}\bin"; Flags: ignoreversion; Components: Engine
Source: "bin\deng2.dll"; DestDir: "{app}\bin"; Flags: ignoreversion; Components: Engine
Source: "bin\deng_shell.dll"; DestDir: "{app}\bin"; Flags: ignoreversion; Components: Engine
Source: "bin\deng_gui.dll"; DestDir: "{app}\bin"; Flags: ignoreversion; Components: Engine
Expand Down
2 changes: 1 addition & 1 deletion doomsday/api/README
Expand Up @@ -9,4 +9,4 @@ and accessing the engine's runtime functionality.
Note that in the future, more and more of this functionality will be moving
into the shared libraries.

See also: libdeng1, libdeng2
See also: libcore, liblegacy
2 changes: 1 addition & 1 deletion doomsday/api/apis.h
Expand Up @@ -21,7 +21,7 @@
#define DOOMSDAY_APIS_H

#ifndef RC_INVOKED
# include <de/libdeng1.h>
# include <de/liblegacy.h>
# include <string.h>
#endif

Expand Down
4 changes: 2 additions & 2 deletions doomsday/build/scripts/codex.py
Expand Up @@ -229,9 +229,9 @@ def fetch_commits():
['Test*', 'GLSandbox'],
['Docs', 'Documentation', 'Codex', 'Readme', 'Doxygen', 'Amethyst'],
['Homepage', 'Add-on Repository', 'Build Repository', 'CSS', 'RSS', 'DEW', 'Forums'],
['libdeng2', 'App', 'Config', 'Log', 'LogBuffer', 'Widgets'],
['libdeng2', 'App', 'Config', 'Log', 'LogBuffer', 'Widgets', 'Garbage', 'Garbages'],
['libgui', 'DisplayMode', 'GL', 'OpenGL', 'GL*', 'Atlas*', 'Image', '*Bank', 'Font'],
['libdeng', 'libdeng1', 'Garbage', 'Garbages', 'Str'],
['libdeng', 'libdeng1', 'liblegacy', 'Str'],
['libshell', 'Shell', 'AbstractLineEditor', 'Link'],
['Client', 'Client UI', 'UI', 'Console', 'Control Panel', 'Default Style', 'GameSelectionWidget',
'Task Bar', 'Updater', 'WindowSystem', 'Client*'],
Expand Down
2 changes: 1 addition & 1 deletion doomsday/build/win32/copy_to_products.py
Expand Up @@ -32,7 +32,7 @@ def copy_if_newer(src, dest):
copy_if_newer(os.path.join(solDir, 'libhexen.pk3'), os.path.join(dest, '..', 'data', 'jhexen', 'libhexen.pk3'))
copy_if_newer(os.path.join(solDir, 'libdoom64.pk3'), os.path.join(dest, '..', 'data', 'jdoom64', 'libdoom64.pk3'))

targets = ['libdeng2', 'libdeng1', 'libshell', 'libgui',
targets = ['libdeng2', 'liblegacy', 'libshell', 'libgui', 'libappfw',
'client', 'server',
'plugins\*', 'tools\*', 'tools\shell\*', 'tests\*']

Expand Down
2 changes: 1 addition & 1 deletion doomsday/build/win32/qmake_msvc.py
Expand Up @@ -59,7 +59,7 @@ def fileRegOff(fn, pattern, startAtPos=0):
r'=&quot;\1&quot;')

copyScript = 'python &quot;%s\\\\build\win32\copy_to_products.py' % rootPath + '&quot; &quot;' + solPath + '&quot;'
rcDirs = '&quot;' + rootPath + '\\\\api&quot;;&quot;' + rootPath + '\\\\libdeng1\include' + '&quot;'
rcDirs = '&quot;' + rootPath + '\\\\api&quot;;&quot;' + rootPath + '\\\\liblegacy\include' + '&quot;'

def find_projs(path):
found = []
Expand Down
6 changes: 3 additions & 3 deletions doomsday/client/api.doxy
@@ -1,12 +1,12 @@
# Public API documentation for Doomsday and libdeng1
# Public API documentation for Doomsday and liblegacy
@INCLUDE = ../doomsday.doxy

PROJECT_NAME = "Doomsday and libdeng1"
PROJECT_NAME = "Doomsday and liblegacy"
PROJECT_NUMBER = 1.15
PROJECT_BRIEF = "Public API"
OUTPUT_DIRECTORY = ../apidoc/api/

INPUT = ../api ../libdeng1/include
INPUT = ../api ../liblegacy/include
PREDEFINED = __DOOMSDAY__ __DENG__ \
"DENG_API_TYPEDEF(Name)=typedef struct de_api_##Name##_s" \
"DENG_API_T(Name)=de_api_##Name##_t" \
Expand Down
4 changes: 2 additions & 2 deletions doomsday/client/client.pro
Expand Up @@ -33,7 +33,7 @@ win32 {
include(../dep_directx.pri)
}
include(../dep_deng2.pri)
include(../dep_deng1.pri)
include(../dep_legacy.pri)
include(../dep_shell.pri)
include(../dep_gui.pri)
include(../dep_appfw.pri)
Expand Down Expand Up @@ -878,7 +878,7 @@ macx {

# Fix the dynamic linker paths so they point to ../Frameworks/ inside the bundle.
fixInstallName(Doomsday.app/Contents/MacOS/Doomsday, libdeng2.2.dylib, ..)
fixInstallName(Doomsday.app/Contents/MacOS/Doomsday, libdeng1.1.dylib, ..)
fixInstallName(Doomsday.app/Contents/MacOS/Doomsday, libdeng_legacy.1.dylib, ..)
linkBinaryToBundledLibdengShell(Doomsday.app/Contents/MacOS/Doomsday)

# Clean up previous deployment.
Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/include/audio/sys_audiod_dummy.h
Expand Up @@ -26,7 +26,7 @@
#ifndef __DOOMSDAY_SYSTEM_AUDIO_DUMMY_H__
#define __DOOMSDAY_SYSTEM_AUDIO_DUMMY_H__

#include <de/libdeng1.h>
#include <de/liblegacy.h>
#include "api_audiod.h"
#include "api_audiod_sfx.h"

Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/include/audio/sys_audiod_sdlmixer.h
Expand Up @@ -27,7 +27,7 @@
#ifndef __DOOMSDAY_SYSTEM_AUDIO_SDLMIXER_H__
#define __DOOMSDAY_SYSTEM_AUDIO_SDLMIXER_H__

#include <de/libdeng1.h>
#include <de/liblegacy.h>
#include "api_audiod.h"
#include "api_audiod_sfx.h"
#include "api_audiod_mus.h"
Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/include/edit_bias.h
Expand Up @@ -22,7 +22,7 @@

#ifdef __CLIENT__

#include <de/libdeng1.h>
#include <de/liblegacy.h>

class HueCircle;

Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/include/render/blockmapvisual.h
Expand Up @@ -21,7 +21,7 @@
#ifndef DENG_CLIENT_RENDER_BLOCKMAPVISUAL_H
#define DENG_CLIENT_RENDER_BLOCKMAPVISUAL_H

#include <de/libdeng1.h>
#include <de/liblegacy.h>

DENG_EXTERN_C byte bmapShowDebug; ///< cvar
DENG_EXTERN_C float bmapDebugSize; ///< cvar
Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/include/render/rendpoly.h
Expand Up @@ -22,7 +22,7 @@
#ifndef DENG_RENDER_RENDPOLY_H
#define DENG_RENDER_RENDPOLY_H

#include <de/libdeng1.h>
#include <de/liblegacy.h>
#include <de/Vector>

DENG_EXTERN_C byte rendInfoRPolys;
Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/include/world/worldsystem.h
Expand Up @@ -31,7 +31,7 @@
#define DENG_WORLDSYSTEM_H

#include "uri.hh"
#include <de/libdeng1.h>
#include <de/liblegacy.h>
#include <de/Error>
#include <de/Observers>
#include <de/System>
Expand Down
2 changes: 1 addition & 1 deletion doomsday/client/src/ui/zonedebug.cpp
Expand Up @@ -34,7 +34,7 @@

/// @todo Find a better way to access the private data of the zone
/// (e.g., move this into the library and use an abstract graphics interface).
#include "../../libdeng1/src/memoryzone_private.h"
#include "../../liblegacy/src/memoryzone_private.h"

using namespace de;

Expand Down
26 changes: 0 additions & 26 deletions doomsday/dep_deng1.pri

This file was deleted.

26 changes: 26 additions & 0 deletions doomsday/dep_legacy.pri
@@ -0,0 +1,26 @@
# Build configuration for using C/legacy support.
LIBDENG_INCLUDE_DIR = $$PWD/liblegacy/include
INCLUDEPATH += $$LIBDENG_INCLUDE_DIR

win32 {
# Tell rc where to get the API headers.
QMAKE_RC = $$QMAKE_RC /I \"$$LIBDENG_INCLUDE_DIR\"
}

# Use the appropriate library path (trying some alternatives).
!useLibDir($$OUT_PWD/../liblegacy) {
!useLibDir($$OUT_PWD/../../liblegacy) {
useLibDir($$OUT_PWD/../../builddir/liblegacy)
}
}

LIBS += -ldeng_legacy

macx {
defineTest(linkBinaryToBundledLiblegacy) {
fixInstallName($${1}, libdeng_legacy.1.dylib, ..)
}
defineTest(linkToBundledLiblegacy) {
fixInstallName($${1}.bundle/$$1, libdeng_legacy.1.dylib, ..)
}
}
2 changes: 1 addition & 1 deletion doomsday/doomsday.pro
Expand Up @@ -10,7 +10,7 @@ CONFIG += ordered
SUBDIRS = \
build \
libdeng2 \
libdeng1 \
liblegacy \
libshell

!deng_noclient|macx {
Expand Down
13 changes: 6 additions & 7 deletions doomsday/libdeng2/include/de/core/version.h
Expand Up @@ -30,14 +30,13 @@
namespace de {

/**
* Version information about libdeng2. The version numbers are defined in
* libdeng2.pro.
* Version information about libdeng2. The version numbers are defined in libdeng2.pro.
*
* @note For the time being, this is separate from the libdeng1/engine version
* number. libdeng2 versioning starts from 2.0.0. When the project as a whole
* switches to major version 2, libdeng2 version will be synced with the rest
* of the project. Also note that unlike libdeng1, there is only ever three
* components in the version (or four, counting the build number).
* @note For the time being, this is separate from the project version number. libdeng2
* versioning starts from 2.0.0. When the project as a whole switches to major version 2,
* libdeng2 version will be synced with the rest of the project. Also note that unlike in
* the past, there is only ever three components in the version (or four, counting the
* build number).
*
* @ingroup core
*/
Expand Down
2 changes: 1 addition & 1 deletion doomsday/libdeng2/src/core/commandline.cpp
Expand Up @@ -288,7 +288,7 @@ void CommandLine::makeAbsolutePath(duint pos)
QFileInfo info(dir.path());
if(info.isDir())
{
// Append a slash so libdeng1 will treat it as a directory.
// Append a slash so FS1 will treat it as a directory.
d->arguments[pos] += '/';
}

Expand Down
File renamed without changes.
Expand Up @@ -26,7 +26,7 @@
#ifndef LIBDENG_ANIMATOR_H
#define LIBDENG_ANIMATOR_H

#include "libdeng1.h"
#include "liblegacy.h"

/// @addtogroup math
///@{
Expand Down
Expand Up @@ -22,7 +22,7 @@
#ifndef LIBDENG_BAMS_MATH_H
#define LIBDENG_BAMS_MATH_H

#include <de/libdeng1.h>
#include <de/liblegacy.h>
#include <de/types.h>

#ifdef __cplusplus
Expand Down
Expand Up @@ -24,7 +24,7 @@
#ifndef LIBDENG_SYSTEM_CONCURRENCY_H
#define LIBDENG_SYSTEM_CONCURRENCY_H

#include <de/libdeng1.h>
#include <de/liblegacy.h>

typedef void *thread_t;
typedef int (*systhreadfunc_t) (void *parm);
Expand Down
File renamed without changes.
File renamed without changes.
Expand Up @@ -24,7 +24,7 @@
#ifndef LIBDENG_FIXED_POINT_MATH_H
#define LIBDENG_FIXED_POINT_MATH_H

#include "libdeng1.h"
#include "liblegacy.h"

#define FRACBITS 16
#define FRACUNIT (1 << FRACBITS)
Expand Down
File renamed without changes.
@@ -1,6 +1,6 @@
/** @file libdeng1.h Common definitions for libdeng1.
/** @file liblegacy.h Common definitions for legacy support.
*
* @authors Copyright © 2012-2013 Jaakko Keränen <jaakko.keranen@iki.fi>
* @authors Copyright © 2012-2014 Jaakko Keränen <jaakko.keranen@iki.fi>
*
* @par License
* GPL: http://www.gnu.org/licenses/gpl.html
Expand All @@ -17,8 +17,8 @@
* 02110-1301 USA</small>
*/

#ifndef LIBDENG1_H
#define LIBDENG1_H
#ifndef LIBLEGACY_H
#define LIBLEGACY_H

#if defined(__cplusplus) && !defined(DENG_NO_QT)
# define DENG_USE_QT
Expand Down Expand Up @@ -135,15 +135,14 @@ extern "C" {
#endif

/**
* Initializes the libdeng1 library. This must be the first function called
* before any other libdeng1 functions.
* Initializes the library. This must be the first function called before any other
* functions in the library.
*/
DENG_PUBLIC void Libdeng_Init(void);

/**
* Shuts down the libdeng1 library. Frees any internal resources allocated by
* the library's subsystems. Must be called when the library is no longer
* needed.
* Shuts down the library. Frees any internal resources allocated by the library's
* subsystems. Must be called when the library is no longer needed.
*/
DENG_PUBLIC void Libdeng_Shutdown(void);

Expand All @@ -157,4 +156,4 @@ DENG_PUBLIC void Libdeng_BadAlloc(void);
} // extern "C"
#endif

#endif // LIBDENG1_H
#endif // LIBLEGACY_H
Expand Up @@ -21,7 +21,7 @@
#ifndef LIBDENG_MATHUTIL_H
#define LIBDENG_MATHUTIL_H

#include "libdeng1.h"
#include "liblegacy.h"

#ifdef __cplusplus
extern "C" {
Expand Down
Expand Up @@ -23,7 +23,7 @@
#ifndef LIBDENG_SYSTEM_MEMORY_H
#define LIBDENG_SYSTEM_MEMORY_H

#include <de/libdeng1.h>
#include <de/liblegacy.h>
#include <string.h> // memcpy

#ifdef __cplusplus
Expand Down
Expand Up @@ -23,7 +23,7 @@
#ifndef LIBDENG_MEMORY_BLOCKSET_H
#define LIBDENG_MEMORY_BLOCKSET_H

#include "libdeng1.h"
#include "liblegacy.h"

#ifdef __cplusplus
extern "C" {
Expand Down
Expand Up @@ -33,7 +33,7 @@
* @ingroup base
*/

#include <de/libdeng1.h>
#include <de/liblegacy.h>

#ifdef __cplusplus
extern "C" {
Expand Down
Expand Up @@ -22,7 +22,7 @@
#ifndef LIBDENG_DATA_POINT_H
#define LIBDENG_DATA_POINT_H

#include "libdeng1.h"
#include "liblegacy.h"

#ifdef __cplusplus
extern "C" {
Expand Down
Expand Up @@ -35,7 +35,7 @@
#ifndef LIBDENG_READER_H
#define LIBDENG_READER_H

#include "libdeng1.h"
#include "liblegacy.h"
#include "types.h"

#ifdef __cplusplus
Expand Down
File renamed without changes.

0 comments on commit c871117

Please sign in to comment.